module Stratosphere.IoTFleetHub.Application (
Application(..), mkApplication
) 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 Application
=
Application {Application -> ()
haddock_workaround_ :: (),
Application -> Maybe (Value Text)
applicationDescription :: (Prelude.Maybe (Value Prelude.Text)),
Application -> Value Text
applicationName :: (Value Prelude.Text),
Application -> Value Text
roleArn :: (Value Prelude.Text),
Application -> Maybe [Tag]
tags :: (Prelude.Maybe [Tag])}
deriving stock (Application -> Application -> Bool
(Application -> Application -> Bool)
-> (Application -> Application -> Bool) -> Eq Application
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: Application -> Application -> Bool
== :: Application -> Application -> Bool
$c/= :: Application -> Application -> Bool
/= :: Application -> Application -> Bool
Prelude.Eq, Int -> Application -> ShowS
[Application] -> ShowS
Application -> String
(Int -> Application -> ShowS)
-> (Application -> String)
-> ([Application] -> ShowS)
-> Show Application
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> Application -> ShowS
showsPrec :: Int -> Application -> ShowS
$cshow :: Application -> String
show :: Application -> String
$cshowList :: [Application] -> ShowS
showList :: [Application] -> ShowS
Prelude.Show)
mkApplication ::
Value Prelude.Text -> Value Prelude.Text -> Application
mkApplication :: Value Text -> Value Text -> Application
mkApplication Value Text
applicationName Value Text
roleArn
= Application
{haddock_workaround_ :: ()
haddock_workaround_ = (), applicationName :: Value Text
applicationName = Value Text
applicationName,
roleArn :: Value Text
roleArn = Value Text
roleArn, applicationDescription :: Maybe (Value Text)
applicationDescription = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing,
tags :: Maybe [Tag]
tags = Maybe [Tag]
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties Application where
toResourceProperties :: Application -> ResourceProperties
toResourceProperties Application {Maybe [Tag]
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: Application -> ()
applicationDescription :: Application -> Maybe (Value Text)
applicationName :: Application -> Value Text
roleArn :: Application -> Value Text
tags :: Application -> Maybe [Tag]
haddock_workaround_ :: ()
applicationDescription :: Maybe (Value Text)
applicationName :: Value Text
roleArn :: Value Text
tags :: Maybe [Tag]
..}
= ResourceProperties
{awsType :: Text
awsType = Text
"AWS::IoTFleetHub::Application",
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
"ApplicationName" 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
applicationName,
Key
"RoleArn" 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
roleArn]
([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
"ApplicationDescription"
(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)
applicationDescription,
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 Application where
toJSON :: Application -> Value
toJSON Application {Maybe [Tag]
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: Application -> ()
applicationDescription :: Application -> Maybe (Value Text)
applicationName :: Application -> Value Text
roleArn :: Application -> Value Text
tags :: Application -> Maybe [Tag]
haddock_workaround_ :: ()
applicationDescription :: Maybe (Value Text)
applicationName :: Value Text
roleArn :: 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
"ApplicationName" 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
applicationName,
Key
"RoleArn" 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
roleArn]
([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
"ApplicationDescription"
(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)
applicationDescription,
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 "ApplicationDescription" Application where
type PropertyType "ApplicationDescription" Application = Value Prelude.Text
set :: PropertyType "ApplicationDescription" Application
-> Application -> Application
set PropertyType "ApplicationDescription" Application
newValue Application {Maybe [Tag]
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: Application -> ()
applicationDescription :: Application -> Maybe (Value Text)
applicationName :: Application -> Value Text
roleArn :: Application -> Value Text
tags :: Application -> Maybe [Tag]
haddock_workaround_ :: ()
applicationDescription :: Maybe (Value Text)
applicationName :: Value Text
roleArn :: Value Text
tags :: Maybe [Tag]
..}
= Application {applicationDescription :: Maybe (Value Text)
applicationDescription = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "ApplicationDescription" Application
Value Text
newValue, Maybe [Tag]
()
Value Text
haddock_workaround_ :: ()
applicationName :: Value Text
roleArn :: Value Text
tags :: Maybe [Tag]
haddock_workaround_ :: ()
applicationName :: Value Text
roleArn :: Value Text
tags :: Maybe [Tag]
..}
instance Property "ApplicationName" Application where
type PropertyType "ApplicationName" Application = Value Prelude.Text
set :: PropertyType "ApplicationName" Application
-> Application -> Application
set PropertyType "ApplicationName" Application
newValue Application {Maybe [Tag]
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: Application -> ()
applicationDescription :: Application -> Maybe (Value Text)
applicationName :: Application -> Value Text
roleArn :: Application -> Value Text
tags :: Application -> Maybe [Tag]
haddock_workaround_ :: ()
applicationDescription :: Maybe (Value Text)
applicationName :: Value Text
roleArn :: Value Text
tags :: Maybe [Tag]
..}
= Application {applicationName :: Value Text
applicationName = PropertyType "ApplicationName" Application
Value Text
newValue, Maybe [Tag]
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ()
applicationDescription :: Maybe (Value Text)
roleArn :: Value Text
tags :: Maybe [Tag]
haddock_workaround_ :: ()
applicationDescription :: Maybe (Value Text)
roleArn :: Value Text
tags :: Maybe [Tag]
..}
instance Property "RoleArn" Application where
type PropertyType "RoleArn" Application = Value Prelude.Text
set :: PropertyType "RoleArn" Application -> Application -> Application
set PropertyType "RoleArn" Application
newValue Application {Maybe [Tag]
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: Application -> ()
applicationDescription :: Application -> Maybe (Value Text)
applicationName :: Application -> Value Text
roleArn :: Application -> Value Text
tags :: Application -> Maybe [Tag]
haddock_workaround_ :: ()
applicationDescription :: Maybe (Value Text)
applicationName :: Value Text
roleArn :: Value Text
tags :: Maybe [Tag]
..}
= Application {roleArn :: Value Text
roleArn = PropertyType "RoleArn" Application
Value Text
newValue, Maybe [Tag]
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ()
applicationDescription :: Maybe (Value Text)
applicationName :: Value Text
tags :: Maybe [Tag]
haddock_workaround_ :: ()
applicationDescription :: Maybe (Value Text)
applicationName :: Value Text
tags :: Maybe [Tag]
..}
instance Property "Tags" Application where
type PropertyType "Tags" Application = [Tag]
set :: PropertyType "Tags" Application -> Application -> Application
set PropertyType "Tags" Application
newValue Application {Maybe [Tag]
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: Application -> ()
applicationDescription :: Application -> Maybe (Value Text)
applicationName :: Application -> Value Text
roleArn :: Application -> Value Text
tags :: Application -> Maybe [Tag]
haddock_workaround_ :: ()
applicationDescription :: Maybe (Value Text)
applicationName :: Value Text
roleArn :: Value Text
tags :: Maybe [Tag]
..}
= Application {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" Application
newValue, Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ()
applicationDescription :: Maybe (Value Text)
applicationName :: Value Text
roleArn :: Value Text
haddock_workaround_ :: ()
applicationDescription :: Maybe (Value Text)
applicationName :: Value Text
roleArn :: Value Text
..}