module Stratosphere.Route53RecoveryReadiness.RecoveryGroup (
        RecoveryGroup(..), mkRecoveryGroup
    ) 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 RecoveryGroup
  = -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-route53recoveryreadiness-recoverygroup.html>
    RecoveryGroup {RecoveryGroup -> ()
haddock_workaround_ :: (),
                   -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-route53recoveryreadiness-recoverygroup.html#cfn-route53recoveryreadiness-recoverygroup-cells>
                   RecoveryGroup -> Maybe (ValueList Text)
cells :: (Prelude.Maybe (ValueList Prelude.Text)),
                   -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-route53recoveryreadiness-recoverygroup.html#cfn-route53recoveryreadiness-recoverygroup-recoverygroupname>
                   RecoveryGroup -> Maybe (Value Text)
recoveryGroupName :: (Prelude.Maybe (Value Prelude.Text)),
                   -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-route53recoveryreadiness-recoverygroup.html#cfn-route53recoveryreadiness-recoverygroup-tags>
                   RecoveryGroup -> Maybe [Tag]
tags :: (Prelude.Maybe [Tag])}
  deriving stock (RecoveryGroup -> RecoveryGroup -> Bool
(RecoveryGroup -> RecoveryGroup -> Bool)
-> (RecoveryGroup -> RecoveryGroup -> Bool) -> Eq RecoveryGroup
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: RecoveryGroup -> RecoveryGroup -> Bool
== :: RecoveryGroup -> RecoveryGroup -> Bool
$c/= :: RecoveryGroup -> RecoveryGroup -> Bool
/= :: RecoveryGroup -> RecoveryGroup -> Bool
Prelude.Eq, Int -> RecoveryGroup -> ShowS
[RecoveryGroup] -> ShowS
RecoveryGroup -> String
(Int -> RecoveryGroup -> ShowS)
-> (RecoveryGroup -> String)
-> ([RecoveryGroup] -> ShowS)
-> Show RecoveryGroup
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> RecoveryGroup -> ShowS
showsPrec :: Int -> RecoveryGroup -> ShowS
$cshow :: RecoveryGroup -> String
show :: RecoveryGroup -> String
$cshowList :: [RecoveryGroup] -> ShowS
showList :: [RecoveryGroup] -> ShowS
Prelude.Show)
mkRecoveryGroup :: RecoveryGroup
mkRecoveryGroup :: RecoveryGroup
mkRecoveryGroup
  = RecoveryGroup
      {haddock_workaround_ :: ()
haddock_workaround_ = (), cells :: Maybe (ValueList Text)
cells = Maybe (ValueList Text)
forall a. Maybe a
Prelude.Nothing,
       recoveryGroupName :: Maybe (Value Text)
recoveryGroupName = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing, tags :: Maybe [Tag]
tags = Maybe [Tag]
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties RecoveryGroup where
  toResourceProperties :: RecoveryGroup -> ResourceProperties
toResourceProperties RecoveryGroup {Maybe [Tag]
Maybe (ValueList Text)
Maybe (Value Text)
()
haddock_workaround_ :: RecoveryGroup -> ()
cells :: RecoveryGroup -> Maybe (ValueList Text)
recoveryGroupName :: RecoveryGroup -> Maybe (Value Text)
tags :: RecoveryGroup -> Maybe [Tag]
haddock_workaround_ :: ()
cells :: Maybe (ValueList Text)
recoveryGroupName :: Maybe (Value Text)
tags :: Maybe [Tag]
..}
    = ResourceProperties
        {awsType :: Text
awsType = Text
"AWS::Route53RecoveryReadiness::RecoveryGroup",
         supportsTags :: Bool
supportsTags = Bool
Prelude.True,
         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 -> 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..=) Key
"Cells" (ValueList Text -> (Key, Value))
-> Maybe (ValueList Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (ValueList Text)
cells,
                            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
"RecoveryGroupName" (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)
recoveryGroupName,
                            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 RecoveryGroup where
  toJSON :: RecoveryGroup -> Value
toJSON RecoveryGroup {Maybe [Tag]
Maybe (ValueList Text)
Maybe (Value Text)
()
haddock_workaround_ :: RecoveryGroup -> ()
cells :: RecoveryGroup -> Maybe (ValueList Text)
recoveryGroupName :: RecoveryGroup -> Maybe (Value Text)
tags :: RecoveryGroup -> Maybe [Tag]
haddock_workaround_ :: ()
cells :: Maybe (ValueList Text)
recoveryGroupName :: Maybe (Value Text)
tags :: Maybe [Tag]
..}
    = [(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 -> 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..=) Key
"Cells" (ValueList Text -> (Key, Value))
-> Maybe (ValueList Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (ValueList Text)
cells,
               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
"RecoveryGroupName" (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)
recoveryGroupName,
               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 "Cells" RecoveryGroup where
  type PropertyType "Cells" RecoveryGroup = ValueList Prelude.Text
  set :: PropertyType "Cells" RecoveryGroup
-> RecoveryGroup -> RecoveryGroup
set PropertyType "Cells" RecoveryGroup
newValue RecoveryGroup {Maybe [Tag]
Maybe (ValueList Text)
Maybe (Value Text)
()
haddock_workaround_ :: RecoveryGroup -> ()
cells :: RecoveryGroup -> Maybe (ValueList Text)
recoveryGroupName :: RecoveryGroup -> Maybe (Value Text)
tags :: RecoveryGroup -> Maybe [Tag]
haddock_workaround_ :: ()
cells :: Maybe (ValueList Text)
recoveryGroupName :: Maybe (Value Text)
tags :: Maybe [Tag]
..}
    = RecoveryGroup {cells :: Maybe (ValueList Text)
cells = ValueList Text -> Maybe (ValueList Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "Cells" RecoveryGroup
ValueList Text
newValue, Maybe [Tag]
Maybe (Value Text)
()
haddock_workaround_ :: ()
recoveryGroupName :: Maybe (Value Text)
tags :: Maybe [Tag]
haddock_workaround_ :: ()
recoveryGroupName :: Maybe (Value Text)
tags :: Maybe [Tag]
..}
instance Property "RecoveryGroupName" RecoveryGroup where
  type PropertyType "RecoveryGroupName" RecoveryGroup = Value Prelude.Text
  set :: PropertyType "RecoveryGroupName" RecoveryGroup
-> RecoveryGroup -> RecoveryGroup
set PropertyType "RecoveryGroupName" RecoveryGroup
newValue RecoveryGroup {Maybe [Tag]
Maybe (ValueList Text)
Maybe (Value Text)
()
haddock_workaround_ :: RecoveryGroup -> ()
cells :: RecoveryGroup -> Maybe (ValueList Text)
recoveryGroupName :: RecoveryGroup -> Maybe (Value Text)
tags :: RecoveryGroup -> Maybe [Tag]
haddock_workaround_ :: ()
cells :: Maybe (ValueList Text)
recoveryGroupName :: Maybe (Value Text)
tags :: Maybe [Tag]
..}
    = RecoveryGroup {recoveryGroupName :: Maybe (Value Text)
recoveryGroupName = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "RecoveryGroupName" RecoveryGroup
Value Text
newValue, Maybe [Tag]
Maybe (ValueList Text)
()
haddock_workaround_ :: ()
cells :: Maybe (ValueList Text)
tags :: Maybe [Tag]
haddock_workaround_ :: ()
cells :: Maybe (ValueList Text)
tags :: Maybe [Tag]
..}
instance Property "Tags" RecoveryGroup where
  type PropertyType "Tags" RecoveryGroup = [Tag]
  set :: PropertyType "Tags" RecoveryGroup -> RecoveryGroup -> RecoveryGroup
set PropertyType "Tags" RecoveryGroup
newValue RecoveryGroup {Maybe [Tag]
Maybe (ValueList Text)
Maybe (Value Text)
()
haddock_workaround_ :: RecoveryGroup -> ()
cells :: RecoveryGroup -> Maybe (ValueList Text)
recoveryGroupName :: RecoveryGroup -> Maybe (Value Text)
tags :: RecoveryGroup -> Maybe [Tag]
haddock_workaround_ :: ()
cells :: Maybe (ValueList Text)
recoveryGroupName :: Maybe (Value Text)
tags :: Maybe [Tag]
..}
    = RecoveryGroup {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" RecoveryGroup
newValue, Maybe (ValueList Text)
Maybe (Value Text)
()
haddock_workaround_ :: ()
cells :: Maybe (ValueList Text)
recoveryGroupName :: Maybe (Value Text)
haddock_workaround_ :: ()
cells :: Maybe (ValueList Text)
recoveryGroupName :: Maybe (Value Text)
..}