module Stratosphere.EC2.TransitGatewayAttachment (
module Exports, TransitGatewayAttachment(..),
mkTransitGatewayAttachment
) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import {-# SOURCE #-} Stratosphere.EC2.TransitGatewayAttachment.OptionsProperty as Exports
import Stratosphere.ResourceProperties
import Stratosphere.Tag
import Stratosphere.Value
data TransitGatewayAttachment
=
TransitGatewayAttachment {TransitGatewayAttachment -> ()
haddock_workaround_ :: (),
TransitGatewayAttachment -> Maybe OptionsProperty
options :: (Prelude.Maybe OptionsProperty),
TransitGatewayAttachment -> ValueList Text
subnetIds :: (ValueList Prelude.Text),
TransitGatewayAttachment -> Maybe [Tag]
tags :: (Prelude.Maybe [Tag]),
TransitGatewayAttachment -> Value Text
transitGatewayId :: (Value Prelude.Text),
TransitGatewayAttachment -> Value Text
vpcId :: (Value Prelude.Text)}
deriving stock (TransitGatewayAttachment -> TransitGatewayAttachment -> Bool
(TransitGatewayAttachment -> TransitGatewayAttachment -> Bool)
-> (TransitGatewayAttachment -> TransitGatewayAttachment -> Bool)
-> Eq TransitGatewayAttachment
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: TransitGatewayAttachment -> TransitGatewayAttachment -> Bool
== :: TransitGatewayAttachment -> TransitGatewayAttachment -> Bool
$c/= :: TransitGatewayAttachment -> TransitGatewayAttachment -> Bool
/= :: TransitGatewayAttachment -> TransitGatewayAttachment -> Bool
Prelude.Eq, Int -> TransitGatewayAttachment -> ShowS
[TransitGatewayAttachment] -> ShowS
TransitGatewayAttachment -> String
(Int -> TransitGatewayAttachment -> ShowS)
-> (TransitGatewayAttachment -> String)
-> ([TransitGatewayAttachment] -> ShowS)
-> Show TransitGatewayAttachment
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> TransitGatewayAttachment -> ShowS
showsPrec :: Int -> TransitGatewayAttachment -> ShowS
$cshow :: TransitGatewayAttachment -> String
show :: TransitGatewayAttachment -> String
$cshowList :: [TransitGatewayAttachment] -> ShowS
showList :: [TransitGatewayAttachment] -> ShowS
Prelude.Show)
mkTransitGatewayAttachment ::
ValueList Prelude.Text
-> Value Prelude.Text
-> Value Prelude.Text -> TransitGatewayAttachment
mkTransitGatewayAttachment :: ValueList Text
-> Value Text -> Value Text -> TransitGatewayAttachment
mkTransitGatewayAttachment ValueList Text
subnetIds Value Text
transitGatewayId Value Text
vpcId
= TransitGatewayAttachment
{haddock_workaround_ :: ()
haddock_workaround_ = (), subnetIds :: ValueList Text
subnetIds = ValueList Text
subnetIds,
transitGatewayId :: Value Text
transitGatewayId = Value Text
transitGatewayId, vpcId :: Value Text
vpcId = Value Text
vpcId,
options :: Maybe OptionsProperty
options = Maybe OptionsProperty
forall a. Maybe a
Prelude.Nothing, tags :: Maybe [Tag]
tags = Maybe [Tag]
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties TransitGatewayAttachment where
toResourceProperties :: TransitGatewayAttachment -> ResourceProperties
toResourceProperties TransitGatewayAttachment {Maybe [Tag]
Maybe OptionsProperty
()
ValueList Text
Value Text
haddock_workaround_ :: TransitGatewayAttachment -> ()
options :: TransitGatewayAttachment -> Maybe OptionsProperty
subnetIds :: TransitGatewayAttachment -> ValueList Text
tags :: TransitGatewayAttachment -> Maybe [Tag]
transitGatewayId :: TransitGatewayAttachment -> Value Text
vpcId :: TransitGatewayAttachment -> Value Text
haddock_workaround_ :: ()
options :: Maybe OptionsProperty
subnetIds :: ValueList Text
tags :: Maybe [Tag]
transitGatewayId :: Value Text
vpcId :: Value Text
..}
= ResourceProperties
{awsType :: Text
awsType = Text
"AWS::EC2::TransitGatewayAttachment",
supportsTags :: Bool
supportsTags = Bool
Prelude.True,
properties :: Object
properties = [Item Object] -> Object
forall l. IsList l => [Item l] -> l
Prelude.fromList
([(Key, Value)] -> [(Key, Value)] -> [(Key, Value)]
forall a. Semigroup a => a -> a -> a
(Prelude.<>)
[Key
"SubnetIds" Key -> ValueList Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= ValueList Text
subnetIds,
Key
"TransitGatewayId" 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..= Value Text
transitGatewayId, Key
"VpcId" 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..= Value Text
vpcId]
([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[Key -> OptionsProperty -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"Options" (OptionsProperty -> (Key, Value))
-> Maybe OptionsProperty -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe OptionsProperty
options,
Key -> [Tag] -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"Tags" ([Tag] -> (Key, Value)) -> Maybe [Tag] -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [Tag]
tags]))}
instance JSON.ToJSON TransitGatewayAttachment where
toJSON :: TransitGatewayAttachment -> Value
toJSON TransitGatewayAttachment {Maybe [Tag]
Maybe OptionsProperty
()
ValueList Text
Value Text
haddock_workaround_ :: TransitGatewayAttachment -> ()
options :: TransitGatewayAttachment -> Maybe OptionsProperty
subnetIds :: TransitGatewayAttachment -> ValueList Text
tags :: TransitGatewayAttachment -> Maybe [Tag]
transitGatewayId :: TransitGatewayAttachment -> Value Text
vpcId :: TransitGatewayAttachment -> Value Text
haddock_workaround_ :: ()
options :: Maybe OptionsProperty
subnetIds :: ValueList Text
tags :: Maybe [Tag]
transitGatewayId :: Value Text
vpcId :: Value Text
..}
= [(Key, Value)] -> Value
JSON.object
([Item [(Key, Value)]] -> [(Key, Value)]
forall l. IsList l => [Item l] -> l
Prelude.fromList
([(Key, Value)] -> [(Key, Value)] -> [(Key, Value)]
forall a. Semigroup a => a -> a -> a
(Prelude.<>)
[Key
"SubnetIds" Key -> ValueList Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= ValueList Text
subnetIds,
Key
"TransitGatewayId" 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..= Value Text
transitGatewayId, Key
"VpcId" 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..= Value Text
vpcId]
([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[Key -> OptionsProperty -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"Options" (OptionsProperty -> (Key, Value))
-> Maybe OptionsProperty -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe OptionsProperty
options,
Key -> [Tag] -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"Tags" ([Tag] -> (Key, Value)) -> Maybe [Tag] -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [Tag]
tags])))
instance Property "Options" TransitGatewayAttachment where
type PropertyType "Options" TransitGatewayAttachment = OptionsProperty
set :: PropertyType "Options" TransitGatewayAttachment
-> TransitGatewayAttachment -> TransitGatewayAttachment
set PropertyType "Options" TransitGatewayAttachment
newValue TransitGatewayAttachment {Maybe [Tag]
Maybe OptionsProperty
()
ValueList Text
Value Text
haddock_workaround_ :: TransitGatewayAttachment -> ()
options :: TransitGatewayAttachment -> Maybe OptionsProperty
subnetIds :: TransitGatewayAttachment -> ValueList Text
tags :: TransitGatewayAttachment -> Maybe [Tag]
transitGatewayId :: TransitGatewayAttachment -> Value Text
vpcId :: TransitGatewayAttachment -> Value Text
haddock_workaround_ :: ()
options :: Maybe OptionsProperty
subnetIds :: ValueList Text
tags :: Maybe [Tag]
transitGatewayId :: Value Text
vpcId :: Value Text
..}
= TransitGatewayAttachment {options :: Maybe OptionsProperty
options = OptionsProperty -> Maybe OptionsProperty
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "Options" TransitGatewayAttachment
OptionsProperty
newValue, Maybe [Tag]
()
ValueList Text
Value Text
haddock_workaround_ :: ()
subnetIds :: ValueList Text
tags :: Maybe [Tag]
transitGatewayId :: Value Text
vpcId :: Value Text
haddock_workaround_ :: ()
subnetIds :: ValueList Text
tags :: Maybe [Tag]
transitGatewayId :: Value Text
vpcId :: Value Text
..}
instance Property "SubnetIds" TransitGatewayAttachment where
type PropertyType "SubnetIds" TransitGatewayAttachment = ValueList Prelude.Text
set :: PropertyType "SubnetIds" TransitGatewayAttachment
-> TransitGatewayAttachment -> TransitGatewayAttachment
set PropertyType "SubnetIds" TransitGatewayAttachment
newValue TransitGatewayAttachment {Maybe [Tag]
Maybe OptionsProperty
()
ValueList Text
Value Text
haddock_workaround_ :: TransitGatewayAttachment -> ()
options :: TransitGatewayAttachment -> Maybe OptionsProperty
subnetIds :: TransitGatewayAttachment -> ValueList Text
tags :: TransitGatewayAttachment -> Maybe [Tag]
transitGatewayId :: TransitGatewayAttachment -> Value Text
vpcId :: TransitGatewayAttachment -> Value Text
haddock_workaround_ :: ()
options :: Maybe OptionsProperty
subnetIds :: ValueList Text
tags :: Maybe [Tag]
transitGatewayId :: Value Text
vpcId :: Value Text
..}
= TransitGatewayAttachment {subnetIds :: ValueList Text
subnetIds = PropertyType "SubnetIds" TransitGatewayAttachment
ValueList Text
newValue, Maybe [Tag]
Maybe OptionsProperty
()
Value Text
haddock_workaround_ :: ()
options :: Maybe OptionsProperty
tags :: Maybe [Tag]
transitGatewayId :: Value Text
vpcId :: Value Text
haddock_workaround_ :: ()
options :: Maybe OptionsProperty
tags :: Maybe [Tag]
transitGatewayId :: Value Text
vpcId :: Value Text
..}
instance Property "Tags" TransitGatewayAttachment where
type PropertyType "Tags" TransitGatewayAttachment = [Tag]
set :: PropertyType "Tags" TransitGatewayAttachment
-> TransitGatewayAttachment -> TransitGatewayAttachment
set PropertyType "Tags" TransitGatewayAttachment
newValue TransitGatewayAttachment {Maybe [Tag]
Maybe OptionsProperty
()
ValueList Text
Value Text
haddock_workaround_ :: TransitGatewayAttachment -> ()
options :: TransitGatewayAttachment -> Maybe OptionsProperty
subnetIds :: TransitGatewayAttachment -> ValueList Text
tags :: TransitGatewayAttachment -> Maybe [Tag]
transitGatewayId :: TransitGatewayAttachment -> Value Text
vpcId :: TransitGatewayAttachment -> Value Text
haddock_workaround_ :: ()
options :: Maybe OptionsProperty
subnetIds :: ValueList Text
tags :: Maybe [Tag]
transitGatewayId :: Value Text
vpcId :: Value Text
..}
= TransitGatewayAttachment {tags :: Maybe [Tag]
tags = [Tag] -> Maybe [Tag]
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure [Tag]
PropertyType "Tags" TransitGatewayAttachment
newValue, Maybe OptionsProperty
()
ValueList Text
Value Text
haddock_workaround_ :: ()
options :: Maybe OptionsProperty
subnetIds :: ValueList Text
transitGatewayId :: Value Text
vpcId :: Value Text
haddock_workaround_ :: ()
options :: Maybe OptionsProperty
subnetIds :: ValueList Text
transitGatewayId :: Value Text
vpcId :: Value Text
..}
instance Property "TransitGatewayId" TransitGatewayAttachment where
type PropertyType "TransitGatewayId" TransitGatewayAttachment = Value Prelude.Text
set :: PropertyType "TransitGatewayId" TransitGatewayAttachment
-> TransitGatewayAttachment -> TransitGatewayAttachment
set PropertyType "TransitGatewayId" TransitGatewayAttachment
newValue TransitGatewayAttachment {Maybe [Tag]
Maybe OptionsProperty
()
ValueList Text
Value Text
haddock_workaround_ :: TransitGatewayAttachment -> ()
options :: TransitGatewayAttachment -> Maybe OptionsProperty
subnetIds :: TransitGatewayAttachment -> ValueList Text
tags :: TransitGatewayAttachment -> Maybe [Tag]
transitGatewayId :: TransitGatewayAttachment -> Value Text
vpcId :: TransitGatewayAttachment -> Value Text
haddock_workaround_ :: ()
options :: Maybe OptionsProperty
subnetIds :: ValueList Text
tags :: Maybe [Tag]
transitGatewayId :: Value Text
vpcId :: Value Text
..}
= TransitGatewayAttachment {transitGatewayId :: Value Text
transitGatewayId = PropertyType "TransitGatewayId" TransitGatewayAttachment
Value Text
newValue, Maybe [Tag]
Maybe OptionsProperty
()
ValueList Text
Value Text
haddock_workaround_ :: ()
options :: Maybe OptionsProperty
subnetIds :: ValueList Text
tags :: Maybe [Tag]
vpcId :: Value Text
haddock_workaround_ :: ()
options :: Maybe OptionsProperty
subnetIds :: ValueList Text
tags :: Maybe [Tag]
vpcId :: Value Text
..}
instance Property "VpcId" TransitGatewayAttachment where
type PropertyType "VpcId" TransitGatewayAttachment = Value Prelude.Text
set :: PropertyType "VpcId" TransitGatewayAttachment
-> TransitGatewayAttachment -> TransitGatewayAttachment
set PropertyType "VpcId" TransitGatewayAttachment
newValue TransitGatewayAttachment {Maybe [Tag]
Maybe OptionsProperty
()
ValueList Text
Value Text
haddock_workaround_ :: TransitGatewayAttachment -> ()
options :: TransitGatewayAttachment -> Maybe OptionsProperty
subnetIds :: TransitGatewayAttachment -> ValueList Text
tags :: TransitGatewayAttachment -> Maybe [Tag]
transitGatewayId :: TransitGatewayAttachment -> Value Text
vpcId :: TransitGatewayAttachment -> Value Text
haddock_workaround_ :: ()
options :: Maybe OptionsProperty
subnetIds :: ValueList Text
tags :: Maybe [Tag]
transitGatewayId :: Value Text
vpcId :: Value Text
..}
= TransitGatewayAttachment {vpcId :: Value Text
vpcId = PropertyType "VpcId" TransitGatewayAttachment
Value Text
newValue, Maybe [Tag]
Maybe OptionsProperty
()
ValueList Text
Value Text
haddock_workaround_ :: ()
options :: Maybe OptionsProperty
subnetIds :: ValueList Text
tags :: Maybe [Tag]
transitGatewayId :: Value Text
haddock_workaround_ :: ()
options :: Maybe OptionsProperty
subnetIds :: ValueList Text
tags :: Maybe [Tag]
transitGatewayId :: Value Text
..}