module Stratosphere.WorkSpaces.ConnectionAlias (
ConnectionAlias(..), mkConnectionAlias
) 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 ConnectionAlias
=
ConnectionAlias {ConnectionAlias -> ()
haddock_workaround_ :: (),
ConnectionAlias -> Value Text
connectionString :: (Value Prelude.Text),
ConnectionAlias -> Maybe [Tag]
tags :: (Prelude.Maybe [Tag])}
deriving stock (ConnectionAlias -> ConnectionAlias -> Bool
(ConnectionAlias -> ConnectionAlias -> Bool)
-> (ConnectionAlias -> ConnectionAlias -> Bool)
-> Eq ConnectionAlias
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: ConnectionAlias -> ConnectionAlias -> Bool
== :: ConnectionAlias -> ConnectionAlias -> Bool
$c/= :: ConnectionAlias -> ConnectionAlias -> Bool
/= :: ConnectionAlias -> ConnectionAlias -> Bool
Prelude.Eq, Int -> ConnectionAlias -> ShowS
[ConnectionAlias] -> ShowS
ConnectionAlias -> String
(Int -> ConnectionAlias -> ShowS)
-> (ConnectionAlias -> String)
-> ([ConnectionAlias] -> ShowS)
-> Show ConnectionAlias
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> ConnectionAlias -> ShowS
showsPrec :: Int -> ConnectionAlias -> ShowS
$cshow :: ConnectionAlias -> String
show :: ConnectionAlias -> String
$cshowList :: [ConnectionAlias] -> ShowS
showList :: [ConnectionAlias] -> ShowS
Prelude.Show)
mkConnectionAlias :: Value Prelude.Text -> ConnectionAlias
mkConnectionAlias :: Value Text -> ConnectionAlias
mkConnectionAlias Value Text
connectionString
= ConnectionAlias
{haddock_workaround_ :: ()
haddock_workaround_ = (), connectionString :: Value Text
connectionString = Value Text
connectionString,
tags :: Maybe [Tag]
tags = Maybe [Tag]
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties ConnectionAlias where
toResourceProperties :: ConnectionAlias -> ResourceProperties
toResourceProperties ConnectionAlias {Maybe [Tag]
()
Value Text
haddock_workaround_ :: ConnectionAlias -> ()
connectionString :: ConnectionAlias -> Value Text
tags :: ConnectionAlias -> Maybe [Tag]
haddock_workaround_ :: ()
connectionString :: Value Text
tags :: Maybe [Tag]
..}
= ResourceProperties
{awsType :: Text
awsType = Text
"AWS::WorkSpaces::ConnectionAlias",
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
"ConnectionString" 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
connectionString]
([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes [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 ConnectionAlias where
toJSON :: ConnectionAlias -> Value
toJSON ConnectionAlias {Maybe [Tag]
()
Value Text
haddock_workaround_ :: ConnectionAlias -> ()
connectionString :: ConnectionAlias -> Value Text
tags :: ConnectionAlias -> Maybe [Tag]
haddock_workaround_ :: ()
connectionString :: Value Text
tags :: Maybe [Tag]
..}
= [(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
"ConnectionString" 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
connectionString]
([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes [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 "ConnectionString" ConnectionAlias where
type PropertyType "ConnectionString" ConnectionAlias = Value Prelude.Text
set :: PropertyType "ConnectionString" ConnectionAlias
-> ConnectionAlias -> ConnectionAlias
set PropertyType "ConnectionString" ConnectionAlias
newValue ConnectionAlias {Maybe [Tag]
()
Value Text
haddock_workaround_ :: ConnectionAlias -> ()
connectionString :: ConnectionAlias -> Value Text
tags :: ConnectionAlias -> Maybe [Tag]
haddock_workaround_ :: ()
connectionString :: Value Text
tags :: Maybe [Tag]
..}
= ConnectionAlias {connectionString :: Value Text
connectionString = PropertyType "ConnectionString" ConnectionAlias
Value Text
newValue, Maybe [Tag]
()
haddock_workaround_ :: ()
tags :: Maybe [Tag]
haddock_workaround_ :: ()
tags :: Maybe [Tag]
..}
instance Property "Tags" ConnectionAlias where
type PropertyType "Tags" ConnectionAlias = [Tag]
set :: PropertyType "Tags" ConnectionAlias
-> ConnectionAlias -> ConnectionAlias
set PropertyType "Tags" ConnectionAlias
newValue ConnectionAlias {Maybe [Tag]
()
Value Text
haddock_workaround_ :: ConnectionAlias -> ()
connectionString :: ConnectionAlias -> Value Text
tags :: ConnectionAlias -> Maybe [Tag]
haddock_workaround_ :: ()
connectionString :: Value Text
tags :: Maybe [Tag]
..}
= ConnectionAlias {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" ConnectionAlias
newValue, ()
Value Text
haddock_workaround_ :: ()
connectionString :: Value Text
haddock_workaround_ :: ()
connectionString :: Value Text
..}