module Stratosphere.SES.ContactList.TopicProperty (
        TopicProperty(..), mkTopicProperty
    ) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data TopicProperty
  = -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ses-contactlist-topic.html>
    TopicProperty {TopicProperty -> ()
haddock_workaround_ :: (),
                   -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ses-contactlist-topic.html#cfn-ses-contactlist-topic-defaultsubscriptionstatus>
                   TopicProperty -> Value Text
defaultSubscriptionStatus :: (Value Prelude.Text),
                   -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ses-contactlist-topic.html#cfn-ses-contactlist-topic-description>
                   TopicProperty -> Maybe (Value Text)
description :: (Prelude.Maybe (Value Prelude.Text)),
                   -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ses-contactlist-topic.html#cfn-ses-contactlist-topic-displayname>
                   TopicProperty -> Value Text
displayName :: (Value Prelude.Text),
                   -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ses-contactlist-topic.html#cfn-ses-contactlist-topic-topicname>
                   TopicProperty -> Value Text
topicName :: (Value Prelude.Text)}
  deriving stock (TopicProperty -> TopicProperty -> Bool
(TopicProperty -> TopicProperty -> Bool)
-> (TopicProperty -> TopicProperty -> Bool) -> Eq TopicProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: TopicProperty -> TopicProperty -> Bool
== :: TopicProperty -> TopicProperty -> Bool
$c/= :: TopicProperty -> TopicProperty -> Bool
/= :: TopicProperty -> TopicProperty -> Bool
Prelude.Eq, Int -> TopicProperty -> ShowS
[TopicProperty] -> ShowS
TopicProperty -> String
(Int -> TopicProperty -> ShowS)
-> (TopicProperty -> String)
-> ([TopicProperty] -> ShowS)
-> Show TopicProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> TopicProperty -> ShowS
showsPrec :: Int -> TopicProperty -> ShowS
$cshow :: TopicProperty -> String
show :: TopicProperty -> String
$cshowList :: [TopicProperty] -> ShowS
showList :: [TopicProperty] -> ShowS
Prelude.Show)
mkTopicProperty ::
  Value Prelude.Text
  -> Value Prelude.Text -> Value Prelude.Text -> TopicProperty
mkTopicProperty :: Value Text -> Value Text -> Value Text -> TopicProperty
mkTopicProperty Value Text
defaultSubscriptionStatus Value Text
displayName Value Text
topicName
  = TopicProperty
      {haddock_workaround_ :: ()
haddock_workaround_ = (),
       defaultSubscriptionStatus :: Value Text
defaultSubscriptionStatus = Value Text
defaultSubscriptionStatus,
       displayName :: Value Text
displayName = Value Text
displayName, topicName :: Value Text
topicName = Value Text
topicName,
       description :: Maybe (Value Text)
description = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties TopicProperty where
  toResourceProperties :: TopicProperty -> ResourceProperties
toResourceProperties TopicProperty {Maybe (Value Text)
()
Value Text
haddock_workaround_ :: TopicProperty -> ()
defaultSubscriptionStatus :: TopicProperty -> Value Text
description :: TopicProperty -> Maybe (Value Text)
displayName :: TopicProperty -> Value Text
topicName :: TopicProperty -> Value Text
haddock_workaround_ :: ()
defaultSubscriptionStatus :: Value Text
description :: Maybe (Value Text)
displayName :: Value Text
topicName :: Value Text
..}
    = ResourceProperties
        {awsType :: Text
awsType = Text
"AWS::SES::ContactList.Topic",
         supportsTags :: Bool
supportsTags = Bool
Prelude.False,
         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
"DefaultSubscriptionStatus" 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
defaultSubscriptionStatus,
                            Key
"DisplayName" 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
displayName, Key
"TopicName" 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
topicName]
                           ([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
"Description" (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)
description]))}
instance JSON.ToJSON TopicProperty where
  toJSON :: TopicProperty -> Value
toJSON TopicProperty {Maybe (Value Text)
()
Value Text
haddock_workaround_ :: TopicProperty -> ()
defaultSubscriptionStatus :: TopicProperty -> Value Text
description :: TopicProperty -> Maybe (Value Text)
displayName :: TopicProperty -> Value Text
topicName :: TopicProperty -> Value Text
haddock_workaround_ :: ()
defaultSubscriptionStatus :: Value Text
description :: Maybe (Value Text)
displayName :: Value Text
topicName :: 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
"DefaultSubscriptionStatus" 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
defaultSubscriptionStatus,
               Key
"DisplayName" 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
displayName, Key
"TopicName" 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
topicName]
              ([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
"Description" (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)
description])))
instance Property "DefaultSubscriptionStatus" TopicProperty where
  type PropertyType "DefaultSubscriptionStatus" TopicProperty = Value Prelude.Text
  set :: PropertyType "DefaultSubscriptionStatus" TopicProperty
-> TopicProperty -> TopicProperty
set PropertyType "DefaultSubscriptionStatus" TopicProperty
newValue TopicProperty {Maybe (Value Text)
()
Value Text
haddock_workaround_ :: TopicProperty -> ()
defaultSubscriptionStatus :: TopicProperty -> Value Text
description :: TopicProperty -> Maybe (Value Text)
displayName :: TopicProperty -> Value Text
topicName :: TopicProperty -> Value Text
haddock_workaround_ :: ()
defaultSubscriptionStatus :: Value Text
description :: Maybe (Value Text)
displayName :: Value Text
topicName :: Value Text
..}
    = TopicProperty {defaultSubscriptionStatus :: Value Text
defaultSubscriptionStatus = PropertyType "DefaultSubscriptionStatus" TopicProperty
Value Text
newValue, Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ()
description :: Maybe (Value Text)
displayName :: Value Text
topicName :: Value Text
haddock_workaround_ :: ()
description :: Maybe (Value Text)
displayName :: Value Text
topicName :: Value Text
..}
instance Property "Description" TopicProperty where
  type PropertyType "Description" TopicProperty = Value Prelude.Text
  set :: PropertyType "Description" TopicProperty
-> TopicProperty -> TopicProperty
set PropertyType "Description" TopicProperty
newValue TopicProperty {Maybe (Value Text)
()
Value Text
haddock_workaround_ :: TopicProperty -> ()
defaultSubscriptionStatus :: TopicProperty -> Value Text
description :: TopicProperty -> Maybe (Value Text)
displayName :: TopicProperty -> Value Text
topicName :: TopicProperty -> Value Text
haddock_workaround_ :: ()
defaultSubscriptionStatus :: Value Text
description :: Maybe (Value Text)
displayName :: Value Text
topicName :: Value Text
..}
    = TopicProperty {description :: Maybe (Value Text)
description = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "Description" TopicProperty
Value Text
newValue, ()
Value Text
haddock_workaround_ :: ()
defaultSubscriptionStatus :: Value Text
displayName :: Value Text
topicName :: Value Text
haddock_workaround_ :: ()
defaultSubscriptionStatus :: Value Text
displayName :: Value Text
topicName :: Value Text
..}
instance Property "DisplayName" TopicProperty where
  type PropertyType "DisplayName" TopicProperty = Value Prelude.Text
  set :: PropertyType "DisplayName" TopicProperty
-> TopicProperty -> TopicProperty
set PropertyType "DisplayName" TopicProperty
newValue TopicProperty {Maybe (Value Text)
()
Value Text
haddock_workaround_ :: TopicProperty -> ()
defaultSubscriptionStatus :: TopicProperty -> Value Text
description :: TopicProperty -> Maybe (Value Text)
displayName :: TopicProperty -> Value Text
topicName :: TopicProperty -> Value Text
haddock_workaround_ :: ()
defaultSubscriptionStatus :: Value Text
description :: Maybe (Value Text)
displayName :: Value Text
topicName :: Value Text
..}
    = TopicProperty {displayName :: Value Text
displayName = PropertyType "DisplayName" TopicProperty
Value Text
newValue, Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ()
defaultSubscriptionStatus :: Value Text
description :: Maybe (Value Text)
topicName :: Value Text
haddock_workaround_ :: ()
defaultSubscriptionStatus :: Value Text
description :: Maybe (Value Text)
topicName :: Value Text
..}
instance Property "TopicName" TopicProperty where
  type PropertyType "TopicName" TopicProperty = Value Prelude.Text
  set :: PropertyType "TopicName" TopicProperty
-> TopicProperty -> TopicProperty
set PropertyType "TopicName" TopicProperty
newValue TopicProperty {Maybe (Value Text)
()
Value Text
haddock_workaround_ :: TopicProperty -> ()
defaultSubscriptionStatus :: TopicProperty -> Value Text
description :: TopicProperty -> Maybe (Value Text)
displayName :: TopicProperty -> Value Text
topicName :: TopicProperty -> Value Text
haddock_workaround_ :: ()
defaultSubscriptionStatus :: Value Text
description :: Maybe (Value Text)
displayName :: Value Text
topicName :: Value Text
..}
    = TopicProperty {topicName :: Value Text
topicName = PropertyType "TopicName" TopicProperty
Value Text
newValue, Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ()
defaultSubscriptionStatus :: Value Text
description :: Maybe (Value Text)
displayName :: Value Text
haddock_workaround_ :: ()
defaultSubscriptionStatus :: Value Text
description :: Maybe (Value Text)
displayName :: Value Text
..}