module Stratosphere.CloudFormation.StackSet.AutoDeploymentProperty (
        AutoDeploymentProperty(..), mkAutoDeploymentProperty
    ) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data AutoDeploymentProperty
  = -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-cloudformation-stackset-autodeployment.html>
    AutoDeploymentProperty {AutoDeploymentProperty -> ()
haddock_workaround_ :: (),
                            -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-cloudformation-stackset-autodeployment.html#cfn-cloudformation-stackset-autodeployment-enabled>
                            AutoDeploymentProperty -> Maybe (Value Bool)
enabled :: (Prelude.Maybe (Value Prelude.Bool)),
                            -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-cloudformation-stackset-autodeployment.html#cfn-cloudformation-stackset-autodeployment-retainstacksonaccountremoval>
                            AutoDeploymentProperty -> Maybe (Value Bool)
retainStacksOnAccountRemoval :: (Prelude.Maybe (Value Prelude.Bool))}
  deriving stock (AutoDeploymentProperty -> AutoDeploymentProperty -> Bool
(AutoDeploymentProperty -> AutoDeploymentProperty -> Bool)
-> (AutoDeploymentProperty -> AutoDeploymentProperty -> Bool)
-> Eq AutoDeploymentProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: AutoDeploymentProperty -> AutoDeploymentProperty -> Bool
== :: AutoDeploymentProperty -> AutoDeploymentProperty -> Bool
$c/= :: AutoDeploymentProperty -> AutoDeploymentProperty -> Bool
/= :: AutoDeploymentProperty -> AutoDeploymentProperty -> Bool
Prelude.Eq, Int -> AutoDeploymentProperty -> ShowS
[AutoDeploymentProperty] -> ShowS
AutoDeploymentProperty -> String
(Int -> AutoDeploymentProperty -> ShowS)
-> (AutoDeploymentProperty -> String)
-> ([AutoDeploymentProperty] -> ShowS)
-> Show AutoDeploymentProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> AutoDeploymentProperty -> ShowS
showsPrec :: Int -> AutoDeploymentProperty -> ShowS
$cshow :: AutoDeploymentProperty -> String
show :: AutoDeploymentProperty -> String
$cshowList :: [AutoDeploymentProperty] -> ShowS
showList :: [AutoDeploymentProperty] -> ShowS
Prelude.Show)
mkAutoDeploymentProperty :: AutoDeploymentProperty
mkAutoDeploymentProperty :: AutoDeploymentProperty
mkAutoDeploymentProperty
  = AutoDeploymentProperty
      {haddock_workaround_ :: ()
haddock_workaround_ = (), enabled :: Maybe (Value Bool)
enabled = Maybe (Value Bool)
forall a. Maybe a
Prelude.Nothing,
       retainStacksOnAccountRemoval :: Maybe (Value Bool)
retainStacksOnAccountRemoval = Maybe (Value Bool)
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties AutoDeploymentProperty where
  toResourceProperties :: AutoDeploymentProperty -> ResourceProperties
toResourceProperties AutoDeploymentProperty {Maybe (Value Bool)
()
haddock_workaround_ :: AutoDeploymentProperty -> ()
enabled :: AutoDeploymentProperty -> Maybe (Value Bool)
retainStacksOnAccountRemoval :: AutoDeploymentProperty -> Maybe (Value Bool)
haddock_workaround_ :: ()
enabled :: Maybe (Value Bool)
retainStacksOnAccountRemoval :: Maybe (Value Bool)
..}
    = ResourceProperties
        {awsType :: Text
awsType = Text
"AWS::CloudFormation::StackSet.AutoDeployment",
         supportsTags :: Bool
supportsTags = Bool
Prelude.False,
         properties :: Object
properties = [Item Object] -> Object
forall l. IsList l => [Item l] -> l
Prelude.fromList
                        ([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
"Enabled" (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)
enabled,
                            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
"RetainStacksOnAccountRemoval"
                              (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)
retainStacksOnAccountRemoval])}
instance JSON.ToJSON AutoDeploymentProperty where
  toJSON :: AutoDeploymentProperty -> Value
toJSON AutoDeploymentProperty {Maybe (Value Bool)
()
haddock_workaround_ :: AutoDeploymentProperty -> ()
enabled :: AutoDeploymentProperty -> Maybe (Value Bool)
retainStacksOnAccountRemoval :: AutoDeploymentProperty -> Maybe (Value Bool)
haddock_workaround_ :: ()
enabled :: Maybe (Value Bool)
retainStacksOnAccountRemoval :: Maybe (Value Bool)
..}
    = [(Key, Value)] -> Value
JSON.object
        ([Item [(Key, Value)]] -> [(Key, Value)]
forall l. IsList l => [Item l] -> l
Prelude.fromList
           ([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
"Enabled" (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)
enabled,
               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
"RetainStacksOnAccountRemoval"
                 (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)
retainStacksOnAccountRemoval]))
instance Property "Enabled" AutoDeploymentProperty where
  type PropertyType "Enabled" AutoDeploymentProperty = Value Prelude.Bool
  set :: PropertyType "Enabled" AutoDeploymentProperty
-> AutoDeploymentProperty -> AutoDeploymentProperty
set PropertyType "Enabled" AutoDeploymentProperty
newValue AutoDeploymentProperty {Maybe (Value Bool)
()
haddock_workaround_ :: AutoDeploymentProperty -> ()
enabled :: AutoDeploymentProperty -> Maybe (Value Bool)
retainStacksOnAccountRemoval :: AutoDeploymentProperty -> Maybe (Value Bool)
haddock_workaround_ :: ()
enabled :: Maybe (Value Bool)
retainStacksOnAccountRemoval :: Maybe (Value Bool)
..}
    = AutoDeploymentProperty {enabled :: Maybe (Value Bool)
enabled = Value Bool -> Maybe (Value Bool)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "Enabled" AutoDeploymentProperty
Value Bool
newValue, Maybe (Value Bool)
()
haddock_workaround_ :: ()
retainStacksOnAccountRemoval :: Maybe (Value Bool)
haddock_workaround_ :: ()
retainStacksOnAccountRemoval :: Maybe (Value Bool)
..}
instance Property "RetainStacksOnAccountRemoval" AutoDeploymentProperty where
  type PropertyType "RetainStacksOnAccountRemoval" AutoDeploymentProperty = Value Prelude.Bool
  set :: PropertyType "RetainStacksOnAccountRemoval" AutoDeploymentProperty
-> AutoDeploymentProperty -> AutoDeploymentProperty
set PropertyType "RetainStacksOnAccountRemoval" AutoDeploymentProperty
newValue AutoDeploymentProperty {Maybe (Value Bool)
()
haddock_workaround_ :: AutoDeploymentProperty -> ()
enabled :: AutoDeploymentProperty -> Maybe (Value Bool)
retainStacksOnAccountRemoval :: AutoDeploymentProperty -> Maybe (Value Bool)
haddock_workaround_ :: ()
enabled :: Maybe (Value Bool)
retainStacksOnAccountRemoval :: Maybe (Value Bool)
..}
    = AutoDeploymentProperty
        {retainStacksOnAccountRemoval :: Maybe (Value Bool)
retainStacksOnAccountRemoval = Value Bool -> Maybe (Value Bool)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "RetainStacksOnAccountRemoval" AutoDeploymentProperty
Value Bool
newValue, Maybe (Value Bool)
()
haddock_workaround_ :: ()
enabled :: Maybe (Value Bool)
haddock_workaround_ :: ()
enabled :: Maybe (Value Bool)
..}