module Stratosphere.ApiGatewayV2.Integration.TlsConfigProperty (
TlsConfigProperty(..), mkTlsConfigProperty
) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data TlsConfigProperty
=
TlsConfigProperty {TlsConfigProperty -> ()
haddock_workaround_ :: (),
TlsConfigProperty -> Maybe (Value Text)
serverNameToVerify :: (Prelude.Maybe (Value Prelude.Text))}
deriving stock (TlsConfigProperty -> TlsConfigProperty -> Bool
(TlsConfigProperty -> TlsConfigProperty -> Bool)
-> (TlsConfigProperty -> TlsConfigProperty -> Bool)
-> Eq TlsConfigProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: TlsConfigProperty -> TlsConfigProperty -> Bool
== :: TlsConfigProperty -> TlsConfigProperty -> Bool
$c/= :: TlsConfigProperty -> TlsConfigProperty -> Bool
/= :: TlsConfigProperty -> TlsConfigProperty -> Bool
Prelude.Eq, Int -> TlsConfigProperty -> ShowS
[TlsConfigProperty] -> ShowS
TlsConfigProperty -> String
(Int -> TlsConfigProperty -> ShowS)
-> (TlsConfigProperty -> String)
-> ([TlsConfigProperty] -> ShowS)
-> Show TlsConfigProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> TlsConfigProperty -> ShowS
showsPrec :: Int -> TlsConfigProperty -> ShowS
$cshow :: TlsConfigProperty -> String
show :: TlsConfigProperty -> String
$cshowList :: [TlsConfigProperty] -> ShowS
showList :: [TlsConfigProperty] -> ShowS
Prelude.Show)
mkTlsConfigProperty :: TlsConfigProperty
mkTlsConfigProperty :: TlsConfigProperty
mkTlsConfigProperty
= TlsConfigProperty
{haddock_workaround_ :: ()
haddock_workaround_ = (), serverNameToVerify :: Maybe (Value Text)
serverNameToVerify = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties TlsConfigProperty where
toResourceProperties :: TlsConfigProperty -> ResourceProperties
toResourceProperties TlsConfigProperty {Maybe (Value Text)
()
haddock_workaround_ :: TlsConfigProperty -> ()
serverNameToVerify :: TlsConfigProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
serverNameToVerify :: Maybe (Value Text)
..}
= ResourceProperties
{awsType :: Text
awsType = Text
"AWS::ApiGatewayV2::Integration.TlsConfig",
supportsTags :: Bool
supportsTags = Bool
Prelude.False,
properties :: Object
properties = [Item Object] -> Object
forall l. IsList l => [Item l] -> l
Prelude.fromList
([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[Key -> Value Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"ServerNameToVerify" (Value Text -> (Key, Value))
-> Maybe (Value Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Text)
serverNameToVerify])}
instance JSON.ToJSON TlsConfigProperty where
toJSON :: TlsConfigProperty -> Value
toJSON TlsConfigProperty {Maybe (Value Text)
()
haddock_workaround_ :: TlsConfigProperty -> ()
serverNameToVerify :: TlsConfigProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
serverNameToVerify :: Maybe (Value Text)
..}
= [(Key, Value)] -> Value
JSON.object
([Item [(Key, Value)]] -> [(Key, Value)]
forall l. IsList l => [Item l] -> l
Prelude.fromList
([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[Key -> Value Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"ServerNameToVerify" (Value Text -> (Key, Value))
-> Maybe (Value Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Text)
serverNameToVerify]))
instance Property "ServerNameToVerify" TlsConfigProperty where
type PropertyType "ServerNameToVerify" TlsConfigProperty = Value Prelude.Text
set :: PropertyType "ServerNameToVerify" TlsConfigProperty
-> TlsConfigProperty -> TlsConfigProperty
set PropertyType "ServerNameToVerify" TlsConfigProperty
newValue TlsConfigProperty {Maybe (Value Text)
()
haddock_workaround_ :: TlsConfigProperty -> ()
serverNameToVerify :: TlsConfigProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
serverNameToVerify :: Maybe (Value Text)
..}
= TlsConfigProperty
{serverNameToVerify :: Maybe (Value Text)
serverNameToVerify = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "ServerNameToVerify" TlsConfigProperty
Value Text
newValue, ()
haddock_workaround_ :: ()
haddock_workaround_ :: ()
..}