module Stratosphere.ApiGateway.VpcLink (
VpcLink(..), mkVpcLink
) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Tag
import Stratosphere.Value
data VpcLink
=
VpcLink {VpcLink -> ()
haddock_workaround_ :: (),
VpcLink -> Maybe (Value Text)
description :: (Prelude.Maybe (Value Prelude.Text)),
VpcLink -> Value Text
name :: (Value Prelude.Text),
VpcLink -> Maybe [Tag]
tags :: (Prelude.Maybe [Tag]),
VpcLink -> ValueList Text
targetArns :: (ValueList Prelude.Text)}
deriving stock (VpcLink -> VpcLink -> Bool
(VpcLink -> VpcLink -> Bool)
-> (VpcLink -> VpcLink -> Bool) -> Eq VpcLink
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: VpcLink -> VpcLink -> Bool
== :: VpcLink -> VpcLink -> Bool
$c/= :: VpcLink -> VpcLink -> Bool
/= :: VpcLink -> VpcLink -> Bool
Prelude.Eq, Int -> VpcLink -> ShowS
[VpcLink] -> ShowS
VpcLink -> String
(Int -> VpcLink -> ShowS)
-> (VpcLink -> String) -> ([VpcLink] -> ShowS) -> Show VpcLink
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> VpcLink -> ShowS
showsPrec :: Int -> VpcLink -> ShowS
$cshow :: VpcLink -> String
show :: VpcLink -> String
$cshowList :: [VpcLink] -> ShowS
showList :: [VpcLink] -> ShowS
Prelude.Show)
mkVpcLink ::
Value Prelude.Text -> ValueList Prelude.Text -> VpcLink
mkVpcLink :: Value Text -> ValueList Text -> VpcLink
mkVpcLink Value Text
name ValueList Text
targetArns
= VpcLink
{haddock_workaround_ :: ()
haddock_workaround_ = (), name :: Value Text
name = Value Text
name, targetArns :: ValueList Text
targetArns = ValueList Text
targetArns,
description :: Maybe (Value Text)
description = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing, tags :: Maybe [Tag]
tags = Maybe [Tag]
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties VpcLink where
toResourceProperties :: VpcLink -> ResourceProperties
toResourceProperties VpcLink {Maybe [Tag]
Maybe (Value Text)
()
ValueList Text
Value Text
haddock_workaround_ :: VpcLink -> ()
description :: VpcLink -> Maybe (Value Text)
name :: VpcLink -> Value Text
tags :: VpcLink -> Maybe [Tag]
targetArns :: VpcLink -> ValueList Text
haddock_workaround_ :: ()
description :: Maybe (Value Text)
name :: Value Text
tags :: Maybe [Tag]
targetArns :: ValueList Text
..}
= ResourceProperties
{awsType :: Text
awsType = Text
"AWS::ApiGateway::VpcLink", 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
"Name" 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
name, Key
"TargetArns" 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
targetArns]
([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
"Description" (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)
description,
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 VpcLink where
toJSON :: VpcLink -> Value
toJSON VpcLink {Maybe [Tag]
Maybe (Value Text)
()
ValueList Text
Value Text
haddock_workaround_ :: VpcLink -> ()
description :: VpcLink -> Maybe (Value Text)
name :: VpcLink -> Value Text
tags :: VpcLink -> Maybe [Tag]
targetArns :: VpcLink -> ValueList Text
haddock_workaround_ :: ()
description :: Maybe (Value Text)
name :: Value Text
tags :: Maybe [Tag]
targetArns :: ValueList 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
"Name" 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
name, Key
"TargetArns" 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
targetArns]
([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
"Description" (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)
description,
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 "Description" VpcLink where
type PropertyType "Description" VpcLink = Value Prelude.Text
set :: PropertyType "Description" VpcLink -> VpcLink -> VpcLink
set PropertyType "Description" VpcLink
newValue VpcLink {Maybe [Tag]
Maybe (Value Text)
()
ValueList Text
Value Text
haddock_workaround_ :: VpcLink -> ()
description :: VpcLink -> Maybe (Value Text)
name :: VpcLink -> Value Text
tags :: VpcLink -> Maybe [Tag]
targetArns :: VpcLink -> ValueList Text
haddock_workaround_ :: ()
description :: Maybe (Value Text)
name :: Value Text
tags :: Maybe [Tag]
targetArns :: ValueList Text
..}
= VpcLink {description :: Maybe (Value Text)
description = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "Description" VpcLink
Value Text
newValue, Maybe [Tag]
()
ValueList Text
Value Text
haddock_workaround_ :: ()
name :: Value Text
tags :: Maybe [Tag]
targetArns :: ValueList Text
haddock_workaround_ :: ()
name :: Value Text
tags :: Maybe [Tag]
targetArns :: ValueList Text
..}
instance Property "Name" VpcLink where
type PropertyType "Name" VpcLink = Value Prelude.Text
set :: PropertyType "Name" VpcLink -> VpcLink -> VpcLink
set PropertyType "Name" VpcLink
newValue VpcLink {Maybe [Tag]
Maybe (Value Text)
()
ValueList Text
Value Text
haddock_workaround_ :: VpcLink -> ()
description :: VpcLink -> Maybe (Value Text)
name :: VpcLink -> Value Text
tags :: VpcLink -> Maybe [Tag]
targetArns :: VpcLink -> ValueList Text
haddock_workaround_ :: ()
description :: Maybe (Value Text)
name :: Value Text
tags :: Maybe [Tag]
targetArns :: ValueList Text
..} = VpcLink {name :: Value Text
name = PropertyType "Name" VpcLink
Value Text
newValue, Maybe [Tag]
Maybe (Value Text)
()
ValueList Text
haddock_workaround_ :: ()
description :: Maybe (Value Text)
tags :: Maybe [Tag]
targetArns :: ValueList Text
haddock_workaround_ :: ()
description :: Maybe (Value Text)
tags :: Maybe [Tag]
targetArns :: ValueList Text
..}
instance Property "Tags" VpcLink where
type PropertyType "Tags" VpcLink = [Tag]
set :: PropertyType "Tags" VpcLink -> VpcLink -> VpcLink
set PropertyType "Tags" VpcLink
newValue VpcLink {Maybe [Tag]
Maybe (Value Text)
()
ValueList Text
Value Text
haddock_workaround_ :: VpcLink -> ()
description :: VpcLink -> Maybe (Value Text)
name :: VpcLink -> Value Text
tags :: VpcLink -> Maybe [Tag]
targetArns :: VpcLink -> ValueList Text
haddock_workaround_ :: ()
description :: Maybe (Value Text)
name :: Value Text
tags :: Maybe [Tag]
targetArns :: ValueList Text
..}
= VpcLink {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" VpcLink
newValue, Maybe (Value Text)
()
ValueList Text
Value Text
haddock_workaround_ :: ()
description :: Maybe (Value Text)
name :: Value Text
targetArns :: ValueList Text
haddock_workaround_ :: ()
description :: Maybe (Value Text)
name :: Value Text
targetArns :: ValueList Text
..}
instance Property "TargetArns" VpcLink where
type PropertyType "TargetArns" VpcLink = ValueList Prelude.Text
set :: PropertyType "TargetArns" VpcLink -> VpcLink -> VpcLink
set PropertyType "TargetArns" VpcLink
newValue VpcLink {Maybe [Tag]
Maybe (Value Text)
()
ValueList Text
Value Text
haddock_workaround_ :: VpcLink -> ()
description :: VpcLink -> Maybe (Value Text)
name :: VpcLink -> Value Text
tags :: VpcLink -> Maybe [Tag]
targetArns :: VpcLink -> ValueList Text
haddock_workaround_ :: ()
description :: Maybe (Value Text)
name :: Value Text
tags :: Maybe [Tag]
targetArns :: ValueList Text
..} = VpcLink {targetArns :: ValueList Text
targetArns = PropertyType "TargetArns" VpcLink
ValueList Text
newValue, Maybe [Tag]
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ()
description :: Maybe (Value Text)
name :: Value Text
tags :: Maybe [Tag]
haddock_workaround_ :: ()
description :: Maybe (Value Text)
name :: Value Text
tags :: Maybe [Tag]
..}