module Stratosphere.PCAConnectorAD.Template (
module Exports, Template(..), mkTemplate
) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import {-# SOURCE #-} Stratosphere.PCAConnectorAD.Template.TemplateDefinitionProperty as Exports
import Stratosphere.ResourceProperties
import Stratosphere.Value
data Template
=
Template {Template -> ()
haddock_workaround_ :: (),
Template -> Value Text
connectorArn :: (Value Prelude.Text),
Template -> TemplateDefinitionProperty
definition :: TemplateDefinitionProperty,
Template -> Value Text
name :: (Value Prelude.Text),
Template -> Maybe (Value Bool)
reenrollAllCertificateHolders :: (Prelude.Maybe (Value Prelude.Bool)),
Template -> Maybe (Map Text (Value Text))
tags :: (Prelude.Maybe (Prelude.Map Prelude.Text (Value Prelude.Text)))}
deriving stock (Template -> Template -> Bool
(Template -> Template -> Bool)
-> (Template -> Template -> Bool) -> Eq Template
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: Template -> Template -> Bool
== :: Template -> Template -> Bool
$c/= :: Template -> Template -> Bool
/= :: Template -> Template -> Bool
Prelude.Eq, Int -> Template -> ShowS
[Template] -> ShowS
Template -> String
(Int -> Template -> ShowS)
-> (Template -> String) -> ([Template] -> ShowS) -> Show Template
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> Template -> ShowS
showsPrec :: Int -> Template -> ShowS
$cshow :: Template -> String
show :: Template -> String
$cshowList :: [Template] -> ShowS
showList :: [Template] -> ShowS
Prelude.Show)
mkTemplate ::
Value Prelude.Text
-> TemplateDefinitionProperty -> Value Prelude.Text -> Template
mkTemplate :: Value Text -> TemplateDefinitionProperty -> Value Text -> Template
mkTemplate Value Text
connectorArn TemplateDefinitionProperty
definition Value Text
name
= Template
{haddock_workaround_ :: ()
haddock_workaround_ = (), connectorArn :: Value Text
connectorArn = Value Text
connectorArn,
definition :: TemplateDefinitionProperty
definition = TemplateDefinitionProperty
definition, name :: Value Text
name = Value Text
name,
reenrollAllCertificateHolders :: Maybe (Value Bool)
reenrollAllCertificateHolders = Maybe (Value Bool)
forall a. Maybe a
Prelude.Nothing,
tags :: Maybe (Map Text (Value Text))
tags = Maybe (Map Text (Value Text))
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties Template where
toResourceProperties :: Template -> ResourceProperties
toResourceProperties Template {Maybe (Map Text (Value Text))
Maybe (Value Bool)
()
Value Text
TemplateDefinitionProperty
haddock_workaround_ :: Template -> ()
connectorArn :: Template -> Value Text
definition :: Template -> TemplateDefinitionProperty
name :: Template -> Value Text
reenrollAllCertificateHolders :: Template -> Maybe (Value Bool)
tags :: Template -> Maybe (Map Text (Value Text))
haddock_workaround_ :: ()
connectorArn :: Value Text
definition :: TemplateDefinitionProperty
name :: Value Text
reenrollAllCertificateHolders :: Maybe (Value Bool)
tags :: Maybe (Map Text (Value Text))
..}
= ResourceProperties
{awsType :: Text
awsType = Text
"AWS::PCAConnectorAD::Template",
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
"ConnectorArn" 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
connectorArn,
Key
"Definition" Key -> TemplateDefinitionProperty -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= TemplateDefinitionProperty
definition, 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]
([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[Key -> Value Bool -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"ReenrollAllCertificateHolders"
(Value Bool -> (Key, Value))
-> Maybe (Value Bool) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Bool)
reenrollAllCertificateHolders,
Key -> Map Text (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
"Tags" (Map Text (Value Text) -> (Key, Value))
-> Maybe (Map Text (Value Text)) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Map Text (Value Text))
tags]))}
instance JSON.ToJSON Template where
toJSON :: Template -> Value
toJSON Template {Maybe (Map Text (Value Text))
Maybe (Value Bool)
()
Value Text
TemplateDefinitionProperty
haddock_workaround_ :: Template -> ()
connectorArn :: Template -> Value Text
definition :: Template -> TemplateDefinitionProperty
name :: Template -> Value Text
reenrollAllCertificateHolders :: Template -> Maybe (Value Bool)
tags :: Template -> Maybe (Map Text (Value Text))
haddock_workaround_ :: ()
connectorArn :: Value Text
definition :: TemplateDefinitionProperty
name :: Value Text
reenrollAllCertificateHolders :: Maybe (Value Bool)
tags :: Maybe (Map Text (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
"ConnectorArn" 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
connectorArn,
Key
"Definition" Key -> TemplateDefinitionProperty -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= TemplateDefinitionProperty
definition, 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]
([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[Key -> Value Bool -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"ReenrollAllCertificateHolders"
(Value Bool -> (Key, Value))
-> Maybe (Value Bool) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Bool)
reenrollAllCertificateHolders,
Key -> Map Text (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
"Tags" (Map Text (Value Text) -> (Key, Value))
-> Maybe (Map Text (Value Text)) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Map Text (Value Text))
tags])))
instance Property "ConnectorArn" Template where
type PropertyType "ConnectorArn" Template = Value Prelude.Text
set :: PropertyType "ConnectorArn" Template -> Template -> Template
set PropertyType "ConnectorArn" Template
newValue Template {Maybe (Map Text (Value Text))
Maybe (Value Bool)
()
Value Text
TemplateDefinitionProperty
haddock_workaround_ :: Template -> ()
connectorArn :: Template -> Value Text
definition :: Template -> TemplateDefinitionProperty
name :: Template -> Value Text
reenrollAllCertificateHolders :: Template -> Maybe (Value Bool)
tags :: Template -> Maybe (Map Text (Value Text))
haddock_workaround_ :: ()
connectorArn :: Value Text
definition :: TemplateDefinitionProperty
name :: Value Text
reenrollAllCertificateHolders :: Maybe (Value Bool)
tags :: Maybe (Map Text (Value Text))
..} = Template {connectorArn :: Value Text
connectorArn = PropertyType "ConnectorArn" Template
Value Text
newValue, Maybe (Map Text (Value Text))
Maybe (Value Bool)
()
Value Text
TemplateDefinitionProperty
haddock_workaround_ :: ()
definition :: TemplateDefinitionProperty
name :: Value Text
reenrollAllCertificateHolders :: Maybe (Value Bool)
tags :: Maybe (Map Text (Value Text))
haddock_workaround_ :: ()
definition :: TemplateDefinitionProperty
name :: Value Text
reenrollAllCertificateHolders :: Maybe (Value Bool)
tags :: Maybe (Map Text (Value Text))
..}
instance Property "Definition" Template where
type PropertyType "Definition" Template = TemplateDefinitionProperty
set :: PropertyType "Definition" Template -> Template -> Template
set PropertyType "Definition" Template
newValue Template {Maybe (Map Text (Value Text))
Maybe (Value Bool)
()
Value Text
TemplateDefinitionProperty
haddock_workaround_ :: Template -> ()
connectorArn :: Template -> Value Text
definition :: Template -> TemplateDefinitionProperty
name :: Template -> Value Text
reenrollAllCertificateHolders :: Template -> Maybe (Value Bool)
tags :: Template -> Maybe (Map Text (Value Text))
haddock_workaround_ :: ()
connectorArn :: Value Text
definition :: TemplateDefinitionProperty
name :: Value Text
reenrollAllCertificateHolders :: Maybe (Value Bool)
tags :: Maybe (Map Text (Value Text))
..} = Template {definition :: TemplateDefinitionProperty
definition = PropertyType "Definition" Template
TemplateDefinitionProperty
newValue, Maybe (Map Text (Value Text))
Maybe (Value Bool)
()
Value Text
haddock_workaround_ :: ()
connectorArn :: Value Text
name :: Value Text
reenrollAllCertificateHolders :: Maybe (Value Bool)
tags :: Maybe (Map Text (Value Text))
haddock_workaround_ :: ()
connectorArn :: Value Text
name :: Value Text
reenrollAllCertificateHolders :: Maybe (Value Bool)
tags :: Maybe (Map Text (Value Text))
..}
instance Property "Name" Template where
type PropertyType "Name" Template = Value Prelude.Text
set :: PropertyType "Name" Template -> Template -> Template
set PropertyType "Name" Template
newValue Template {Maybe (Map Text (Value Text))
Maybe (Value Bool)
()
Value Text
TemplateDefinitionProperty
haddock_workaround_ :: Template -> ()
connectorArn :: Template -> Value Text
definition :: Template -> TemplateDefinitionProperty
name :: Template -> Value Text
reenrollAllCertificateHolders :: Template -> Maybe (Value Bool)
tags :: Template -> Maybe (Map Text (Value Text))
haddock_workaround_ :: ()
connectorArn :: Value Text
definition :: TemplateDefinitionProperty
name :: Value Text
reenrollAllCertificateHolders :: Maybe (Value Bool)
tags :: Maybe (Map Text (Value Text))
..} = Template {name :: Value Text
name = PropertyType "Name" Template
Value Text
newValue, Maybe (Map Text (Value Text))
Maybe (Value Bool)
()
Value Text
TemplateDefinitionProperty
haddock_workaround_ :: ()
connectorArn :: Value Text
definition :: TemplateDefinitionProperty
reenrollAllCertificateHolders :: Maybe (Value Bool)
tags :: Maybe (Map Text (Value Text))
haddock_workaround_ :: ()
connectorArn :: Value Text
definition :: TemplateDefinitionProperty
reenrollAllCertificateHolders :: Maybe (Value Bool)
tags :: Maybe (Map Text (Value Text))
..}
instance Property "ReenrollAllCertificateHolders" Template where
type PropertyType "ReenrollAllCertificateHolders" Template = Value Prelude.Bool
set :: PropertyType "ReenrollAllCertificateHolders" Template
-> Template -> Template
set PropertyType "ReenrollAllCertificateHolders" Template
newValue Template {Maybe (Map Text (Value Text))
Maybe (Value Bool)
()
Value Text
TemplateDefinitionProperty
haddock_workaround_ :: Template -> ()
connectorArn :: Template -> Value Text
definition :: Template -> TemplateDefinitionProperty
name :: Template -> Value Text
reenrollAllCertificateHolders :: Template -> Maybe (Value Bool)
tags :: Template -> Maybe (Map Text (Value Text))
haddock_workaround_ :: ()
connectorArn :: Value Text
definition :: TemplateDefinitionProperty
name :: Value Text
reenrollAllCertificateHolders :: Maybe (Value Bool)
tags :: Maybe (Map Text (Value Text))
..}
= Template
{reenrollAllCertificateHolders :: Maybe (Value Bool)
reenrollAllCertificateHolders = Value Bool -> Maybe (Value Bool)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "ReenrollAllCertificateHolders" Template
Value Bool
newValue, Maybe (Map Text (Value Text))
()
Value Text
TemplateDefinitionProperty
haddock_workaround_ :: ()
connectorArn :: Value Text
definition :: TemplateDefinitionProperty
name :: Value Text
tags :: Maybe (Map Text (Value Text))
haddock_workaround_ :: ()
connectorArn :: Value Text
definition :: TemplateDefinitionProperty
name :: Value Text
tags :: Maybe (Map Text (Value Text))
..}
instance Property "Tags" Template where
type PropertyType "Tags" Template = Prelude.Map Prelude.Text (Value Prelude.Text)
set :: PropertyType "Tags" Template -> Template -> Template
set PropertyType "Tags" Template
newValue Template {Maybe (Map Text (Value Text))
Maybe (Value Bool)
()
Value Text
TemplateDefinitionProperty
haddock_workaround_ :: Template -> ()
connectorArn :: Template -> Value Text
definition :: Template -> TemplateDefinitionProperty
name :: Template -> Value Text
reenrollAllCertificateHolders :: Template -> Maybe (Value Bool)
tags :: Template -> Maybe (Map Text (Value Text))
haddock_workaround_ :: ()
connectorArn :: Value Text
definition :: TemplateDefinitionProperty
name :: Value Text
reenrollAllCertificateHolders :: Maybe (Value Bool)
tags :: Maybe (Map Text (Value Text))
..}
= Template {tags :: Maybe (Map Text (Value Text))
tags = Map Text (Value Text) -> Maybe (Map Text (Value Text))
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure Map Text (Value Text)
PropertyType "Tags" Template
newValue, Maybe (Value Bool)
()
Value Text
TemplateDefinitionProperty
haddock_workaround_ :: ()
connectorArn :: Value Text
definition :: TemplateDefinitionProperty
name :: Value Text
reenrollAllCertificateHolders :: Maybe (Value Bool)
haddock_workaround_ :: ()
connectorArn :: Value Text
definition :: TemplateDefinitionProperty
name :: Value Text
reenrollAllCertificateHolders :: Maybe (Value Bool)
..}