module Stratosphere.DMS.ReplicationSubnetGroup (
        ReplicationSubnetGroup(..), mkReplicationSubnetGroup
    ) 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 ReplicationSubnetGroup
  = -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-dms-replicationsubnetgroup.html>
    ReplicationSubnetGroup {ReplicationSubnetGroup -> ()
haddock_workaround_ :: (),
                            -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-dms-replicationsubnetgroup.html#cfn-dms-replicationsubnetgroup-replicationsubnetgroupdescription>
                            ReplicationSubnetGroup -> Value Text
replicationSubnetGroupDescription :: (Value Prelude.Text),
                            -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-dms-replicationsubnetgroup.html#cfn-dms-replicationsubnetgroup-replicationsubnetgroupidentifier>
                            ReplicationSubnetGroup -> Maybe (Value Text)
replicationSubnetGroupIdentifier :: (Prelude.Maybe (Value Prelude.Text)),
                            -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-dms-replicationsubnetgroup.html#cfn-dms-replicationsubnetgroup-subnetids>
                            ReplicationSubnetGroup -> ValueList Text
subnetIds :: (ValueList Prelude.Text),
                            -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-dms-replicationsubnetgroup.html#cfn-dms-replicationsubnetgroup-tags>
                            ReplicationSubnetGroup -> Maybe [Tag]
tags :: (Prelude.Maybe [Tag])}
  deriving stock (ReplicationSubnetGroup -> ReplicationSubnetGroup -> Bool
(ReplicationSubnetGroup -> ReplicationSubnetGroup -> Bool)
-> (ReplicationSubnetGroup -> ReplicationSubnetGroup -> Bool)
-> Eq ReplicationSubnetGroup
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: ReplicationSubnetGroup -> ReplicationSubnetGroup -> Bool
== :: ReplicationSubnetGroup -> ReplicationSubnetGroup -> Bool
$c/= :: ReplicationSubnetGroup -> ReplicationSubnetGroup -> Bool
/= :: ReplicationSubnetGroup -> ReplicationSubnetGroup -> Bool
Prelude.Eq, Int -> ReplicationSubnetGroup -> ShowS
[ReplicationSubnetGroup] -> ShowS
ReplicationSubnetGroup -> String
(Int -> ReplicationSubnetGroup -> ShowS)
-> (ReplicationSubnetGroup -> String)
-> ([ReplicationSubnetGroup] -> ShowS)
-> Show ReplicationSubnetGroup
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> ReplicationSubnetGroup -> ShowS
showsPrec :: Int -> ReplicationSubnetGroup -> ShowS
$cshow :: ReplicationSubnetGroup -> String
show :: ReplicationSubnetGroup -> String
$cshowList :: [ReplicationSubnetGroup] -> ShowS
showList :: [ReplicationSubnetGroup] -> ShowS
Prelude.Show)
mkReplicationSubnetGroup ::
  Value Prelude.Text
  -> ValueList Prelude.Text -> ReplicationSubnetGroup
mkReplicationSubnetGroup :: Value Text -> ValueList Text -> ReplicationSubnetGroup
mkReplicationSubnetGroup
  Value Text
replicationSubnetGroupDescription
  ValueList Text
subnetIds
  = ReplicationSubnetGroup
      {haddock_workaround_ :: ()
haddock_workaround_ = (),
       replicationSubnetGroupDescription :: Value Text
replicationSubnetGroupDescription = Value Text
replicationSubnetGroupDescription,
       subnetIds :: ValueList Text
subnetIds = ValueList Text
subnetIds,
       replicationSubnetGroupIdentifier :: Maybe (Value Text)
replicationSubnetGroupIdentifier = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing,
       tags :: Maybe [Tag]
tags = Maybe [Tag]
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties ReplicationSubnetGroup where
  toResourceProperties :: ReplicationSubnetGroup -> ResourceProperties
toResourceProperties ReplicationSubnetGroup {Maybe [Tag]
Maybe (Value Text)
()
ValueList Text
Value Text
haddock_workaround_ :: ReplicationSubnetGroup -> ()
replicationSubnetGroupDescription :: ReplicationSubnetGroup -> Value Text
replicationSubnetGroupIdentifier :: ReplicationSubnetGroup -> Maybe (Value Text)
subnetIds :: ReplicationSubnetGroup -> ValueList Text
tags :: ReplicationSubnetGroup -> Maybe [Tag]
haddock_workaround_ :: ()
replicationSubnetGroupDescription :: Value Text
replicationSubnetGroupIdentifier :: Maybe (Value Text)
subnetIds :: ValueList Text
tags :: Maybe [Tag]
..}
    = ResourceProperties
        {awsType :: Text
awsType = Text
"AWS::DMS::ReplicationSubnetGroup",
         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
"ReplicationSubnetGroupDescription"
                              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
replicationSubnetGroupDescription,
                            Key
"SubnetIds" 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..= ValueList Text
subnetIds]
                           ([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
"ReplicationSubnetGroupIdentifier"
                                 (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)
replicationSubnetGroupIdentifier,
                               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 ReplicationSubnetGroup where
  toJSON :: ReplicationSubnetGroup -> Value
toJSON ReplicationSubnetGroup {Maybe [Tag]
Maybe (Value Text)
()
ValueList Text
Value Text
haddock_workaround_ :: ReplicationSubnetGroup -> ()
replicationSubnetGroupDescription :: ReplicationSubnetGroup -> Value Text
replicationSubnetGroupIdentifier :: ReplicationSubnetGroup -> Maybe (Value Text)
subnetIds :: ReplicationSubnetGroup -> ValueList Text
tags :: ReplicationSubnetGroup -> Maybe [Tag]
haddock_workaround_ :: ()
replicationSubnetGroupDescription :: Value Text
replicationSubnetGroupIdentifier :: Maybe (Value Text)
subnetIds :: ValueList 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
"ReplicationSubnetGroupDescription"
                 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
replicationSubnetGroupDescription,
               Key
"SubnetIds" 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..= ValueList Text
subnetIds]
              ([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
"ReplicationSubnetGroupIdentifier"
                    (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)
replicationSubnetGroupIdentifier,
                  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 "ReplicationSubnetGroupDescription" ReplicationSubnetGroup where
  type PropertyType "ReplicationSubnetGroupDescription" ReplicationSubnetGroup = Value Prelude.Text
  set :: PropertyType
  "ReplicationSubnetGroupDescription" ReplicationSubnetGroup
-> ReplicationSubnetGroup -> ReplicationSubnetGroup
set PropertyType
  "ReplicationSubnetGroupDescription" ReplicationSubnetGroup
newValue ReplicationSubnetGroup {Maybe [Tag]
Maybe (Value Text)
()
ValueList Text
Value Text
haddock_workaround_ :: ReplicationSubnetGroup -> ()
replicationSubnetGroupDescription :: ReplicationSubnetGroup -> Value Text
replicationSubnetGroupIdentifier :: ReplicationSubnetGroup -> Maybe (Value Text)
subnetIds :: ReplicationSubnetGroup -> ValueList Text
tags :: ReplicationSubnetGroup -> Maybe [Tag]
haddock_workaround_ :: ()
replicationSubnetGroupDescription :: Value Text
replicationSubnetGroupIdentifier :: Maybe (Value Text)
subnetIds :: ValueList Text
tags :: Maybe [Tag]
..}
    = ReplicationSubnetGroup
        {replicationSubnetGroupDescription :: Value Text
replicationSubnetGroupDescription = PropertyType
  "ReplicationSubnetGroupDescription" ReplicationSubnetGroup
Value Text
newValue, Maybe [Tag]
Maybe (Value Text)
()
ValueList Text
haddock_workaround_ :: ()
replicationSubnetGroupIdentifier :: Maybe (Value Text)
subnetIds :: ValueList Text
tags :: Maybe [Tag]
haddock_workaround_ :: ()
replicationSubnetGroupIdentifier :: Maybe (Value Text)
subnetIds :: ValueList Text
tags :: Maybe [Tag]
..}
instance Property "ReplicationSubnetGroupIdentifier" ReplicationSubnetGroup where
  type PropertyType "ReplicationSubnetGroupIdentifier" ReplicationSubnetGroup = Value Prelude.Text
  set :: PropertyType
  "ReplicationSubnetGroupIdentifier" ReplicationSubnetGroup
-> ReplicationSubnetGroup -> ReplicationSubnetGroup
set PropertyType
  "ReplicationSubnetGroupIdentifier" ReplicationSubnetGroup
newValue ReplicationSubnetGroup {Maybe [Tag]
Maybe (Value Text)
()
ValueList Text
Value Text
haddock_workaround_ :: ReplicationSubnetGroup -> ()
replicationSubnetGroupDescription :: ReplicationSubnetGroup -> Value Text
replicationSubnetGroupIdentifier :: ReplicationSubnetGroup -> Maybe (Value Text)
subnetIds :: ReplicationSubnetGroup -> ValueList Text
tags :: ReplicationSubnetGroup -> Maybe [Tag]
haddock_workaround_ :: ()
replicationSubnetGroupDescription :: Value Text
replicationSubnetGroupIdentifier :: Maybe (Value Text)
subnetIds :: ValueList Text
tags :: Maybe [Tag]
..}
    = ReplicationSubnetGroup
        {replicationSubnetGroupIdentifier :: Maybe (Value Text)
replicationSubnetGroupIdentifier = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType
  "ReplicationSubnetGroupIdentifier" ReplicationSubnetGroup
Value Text
newValue, Maybe [Tag]
()
ValueList Text
Value Text
haddock_workaround_ :: ()
replicationSubnetGroupDescription :: Value Text
subnetIds :: ValueList Text
tags :: Maybe [Tag]
haddock_workaround_ :: ()
replicationSubnetGroupDescription :: Value Text
subnetIds :: ValueList Text
tags :: Maybe [Tag]
..}
instance Property "SubnetIds" ReplicationSubnetGroup where
  type PropertyType "SubnetIds" ReplicationSubnetGroup = ValueList Prelude.Text
  set :: PropertyType "SubnetIds" ReplicationSubnetGroup
-> ReplicationSubnetGroup -> ReplicationSubnetGroup
set PropertyType "SubnetIds" ReplicationSubnetGroup
newValue ReplicationSubnetGroup {Maybe [Tag]
Maybe (Value Text)
()
ValueList Text
Value Text
haddock_workaround_ :: ReplicationSubnetGroup -> ()
replicationSubnetGroupDescription :: ReplicationSubnetGroup -> Value Text
replicationSubnetGroupIdentifier :: ReplicationSubnetGroup -> Maybe (Value Text)
subnetIds :: ReplicationSubnetGroup -> ValueList Text
tags :: ReplicationSubnetGroup -> Maybe [Tag]
haddock_workaround_ :: ()
replicationSubnetGroupDescription :: Value Text
replicationSubnetGroupIdentifier :: Maybe (Value Text)
subnetIds :: ValueList Text
tags :: Maybe [Tag]
..}
    = ReplicationSubnetGroup {subnetIds :: ValueList Text
subnetIds = PropertyType "SubnetIds" ReplicationSubnetGroup
ValueList Text
newValue, Maybe [Tag]
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ()
replicationSubnetGroupDescription :: Value Text
replicationSubnetGroupIdentifier :: Maybe (Value Text)
tags :: Maybe [Tag]
haddock_workaround_ :: ()
replicationSubnetGroupDescription :: Value Text
replicationSubnetGroupIdentifier :: Maybe (Value Text)
tags :: Maybe [Tag]
..}
instance Property "Tags" ReplicationSubnetGroup where
  type PropertyType "Tags" ReplicationSubnetGroup = [Tag]
  set :: PropertyType "Tags" ReplicationSubnetGroup
-> ReplicationSubnetGroup -> ReplicationSubnetGroup
set PropertyType "Tags" ReplicationSubnetGroup
newValue ReplicationSubnetGroup {Maybe [Tag]
Maybe (Value Text)
()
ValueList Text
Value Text
haddock_workaround_ :: ReplicationSubnetGroup -> ()
replicationSubnetGroupDescription :: ReplicationSubnetGroup -> Value Text
replicationSubnetGroupIdentifier :: ReplicationSubnetGroup -> Maybe (Value Text)
subnetIds :: ReplicationSubnetGroup -> ValueList Text
tags :: ReplicationSubnetGroup -> Maybe [Tag]
haddock_workaround_ :: ()
replicationSubnetGroupDescription :: Value Text
replicationSubnetGroupIdentifier :: Maybe (Value Text)
subnetIds :: ValueList Text
tags :: Maybe [Tag]
..}
    = ReplicationSubnetGroup {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" ReplicationSubnetGroup
newValue, Maybe (Value Text)
()
ValueList Text
Value Text
haddock_workaround_ :: ()
replicationSubnetGroupDescription :: Value Text
replicationSubnetGroupIdentifier :: Maybe (Value Text)
subnetIds :: ValueList Text
haddock_workaround_ :: ()
replicationSubnetGroupDescription :: Value Text
replicationSubnetGroupIdentifier :: Maybe (Value Text)
subnetIds :: ValueList Text
..}