module Stratosphere.Connect.EmailAddress (
        module Exports, EmailAddress(..), mkEmailAddress
    ) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import {-# SOURCE #-} Stratosphere.Connect.EmailAddress.AliasConfigurationProperty as Exports
import Stratosphere.ResourceProperties
import Stratosphere.Tag
import Stratosphere.Value
data EmailAddress
  = -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-connect-emailaddress.html>
    EmailAddress {EmailAddress -> ()
haddock_workaround_ :: (),
                  -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-connect-emailaddress.html#cfn-connect-emailaddress-aliasconfigurations>
                  EmailAddress -> Maybe [AliasConfigurationProperty]
aliasConfigurations :: (Prelude.Maybe [AliasConfigurationProperty]),
                  -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-connect-emailaddress.html#cfn-connect-emailaddress-description>
                  EmailAddress -> Maybe (Value Text)
description :: (Prelude.Maybe (Value Prelude.Text)),
                  -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-connect-emailaddress.html#cfn-connect-emailaddress-displayname>
                  EmailAddress -> Maybe (Value Text)
displayName :: (Prelude.Maybe (Value Prelude.Text)),
                  -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-connect-emailaddress.html#cfn-connect-emailaddress-emailaddress>
                  EmailAddress -> Value Text
emailAddress :: (Value Prelude.Text),
                  -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-connect-emailaddress.html#cfn-connect-emailaddress-instancearn>
                  EmailAddress -> Value Text
instanceArn :: (Value Prelude.Text),
                  -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-connect-emailaddress.html#cfn-connect-emailaddress-tags>
                  EmailAddress -> Maybe [Tag]
tags :: (Prelude.Maybe [Tag])}
  deriving stock (EmailAddress -> EmailAddress -> Bool
(EmailAddress -> EmailAddress -> Bool)
-> (EmailAddress -> EmailAddress -> Bool) -> Eq EmailAddress
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: EmailAddress -> EmailAddress -> Bool
== :: EmailAddress -> EmailAddress -> Bool
$c/= :: EmailAddress -> EmailAddress -> Bool
/= :: EmailAddress -> EmailAddress -> Bool
Prelude.Eq, Int -> EmailAddress -> ShowS
[EmailAddress] -> ShowS
EmailAddress -> String
(Int -> EmailAddress -> ShowS)
-> (EmailAddress -> String)
-> ([EmailAddress] -> ShowS)
-> Show EmailAddress
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> EmailAddress -> ShowS
showsPrec :: Int -> EmailAddress -> ShowS
$cshow :: EmailAddress -> String
show :: EmailAddress -> String
$cshowList :: [EmailAddress] -> ShowS
showList :: [EmailAddress] -> ShowS
Prelude.Show)
mkEmailAddress ::
  Value Prelude.Text -> Value Prelude.Text -> EmailAddress
mkEmailAddress :: Value Text -> Value Text -> EmailAddress
mkEmailAddress Value Text
emailAddress Value Text
instanceArn
  = EmailAddress
      {haddock_workaround_ :: ()
haddock_workaround_ = (), emailAddress :: Value Text
emailAddress = Value Text
emailAddress,
       instanceArn :: Value Text
instanceArn = Value Text
instanceArn, aliasConfigurations :: Maybe [AliasConfigurationProperty]
aliasConfigurations = Maybe [AliasConfigurationProperty]
forall a. Maybe a
Prelude.Nothing,
       description :: Maybe (Value Text)
description = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing, displayName :: Maybe (Value Text)
displayName = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing,
       tags :: Maybe [Tag]
tags = Maybe [Tag]
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties EmailAddress where
  toResourceProperties :: EmailAddress -> ResourceProperties
toResourceProperties EmailAddress {Maybe [Tag]
Maybe [AliasConfigurationProperty]
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: EmailAddress -> ()
aliasConfigurations :: EmailAddress -> Maybe [AliasConfigurationProperty]
description :: EmailAddress -> Maybe (Value Text)
displayName :: EmailAddress -> Maybe (Value Text)
emailAddress :: EmailAddress -> Value Text
instanceArn :: EmailAddress -> Value Text
tags :: EmailAddress -> Maybe [Tag]
haddock_workaround_ :: ()
aliasConfigurations :: Maybe [AliasConfigurationProperty]
description :: Maybe (Value Text)
displayName :: Maybe (Value Text)
emailAddress :: Value Text
instanceArn :: Value Text
tags :: Maybe [Tag]
..}
    = ResourceProperties
        {awsType :: Text
awsType = Text
"AWS::Connect::EmailAddress",
         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
"EmailAddress" 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
emailAddress,
                            Key
"InstanceArn" 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
instanceArn]
                           ([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
                              [Key -> [AliasConfigurationProperty] -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"AliasConfigurations" ([AliasConfigurationProperty] -> (Key, Value))
-> Maybe [AliasConfigurationProperty] -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [AliasConfigurationProperty]
aliasConfigurations,
                               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,
                               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
"DisplayName" (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)
displayName,
                               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 EmailAddress where
  toJSON :: EmailAddress -> Value
toJSON EmailAddress {Maybe [Tag]
Maybe [AliasConfigurationProperty]
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: EmailAddress -> ()
aliasConfigurations :: EmailAddress -> Maybe [AliasConfigurationProperty]
description :: EmailAddress -> Maybe (Value Text)
displayName :: EmailAddress -> Maybe (Value Text)
emailAddress :: EmailAddress -> Value Text
instanceArn :: EmailAddress -> Value Text
tags :: EmailAddress -> Maybe [Tag]
haddock_workaround_ :: ()
aliasConfigurations :: Maybe [AliasConfigurationProperty]
description :: Maybe (Value Text)
displayName :: Maybe (Value Text)
emailAddress :: Value Text
instanceArn :: Value 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
"EmailAddress" 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
emailAddress,
               Key
"InstanceArn" 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
instanceArn]
              ([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
                 [Key -> [AliasConfigurationProperty] -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"AliasConfigurations" ([AliasConfigurationProperty] -> (Key, Value))
-> Maybe [AliasConfigurationProperty] -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [AliasConfigurationProperty]
aliasConfigurations,
                  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,
                  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
"DisplayName" (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)
displayName,
                  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 "AliasConfigurations" EmailAddress where
  type PropertyType "AliasConfigurations" EmailAddress = [AliasConfigurationProperty]
  set :: PropertyType "AliasConfigurations" EmailAddress
-> EmailAddress -> EmailAddress
set PropertyType "AliasConfigurations" EmailAddress
newValue EmailAddress {Maybe [Tag]
Maybe [AliasConfigurationProperty]
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: EmailAddress -> ()
aliasConfigurations :: EmailAddress -> Maybe [AliasConfigurationProperty]
description :: EmailAddress -> Maybe (Value Text)
displayName :: EmailAddress -> Maybe (Value Text)
emailAddress :: EmailAddress -> Value Text
instanceArn :: EmailAddress -> Value Text
tags :: EmailAddress -> Maybe [Tag]
haddock_workaround_ :: ()
aliasConfigurations :: Maybe [AliasConfigurationProperty]
description :: Maybe (Value Text)
displayName :: Maybe (Value Text)
emailAddress :: Value Text
instanceArn :: Value Text
tags :: Maybe [Tag]
..}
    = EmailAddress {aliasConfigurations :: Maybe [AliasConfigurationProperty]
aliasConfigurations = [AliasConfigurationProperty] -> Maybe [AliasConfigurationProperty]
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure [AliasConfigurationProperty]
PropertyType "AliasConfigurations" EmailAddress
newValue, Maybe [Tag]
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ()
description :: Maybe (Value Text)
displayName :: Maybe (Value Text)
emailAddress :: Value Text
instanceArn :: Value Text
tags :: Maybe [Tag]
haddock_workaround_ :: ()
description :: Maybe (Value Text)
displayName :: Maybe (Value Text)
emailAddress :: Value Text
instanceArn :: Value Text
tags :: Maybe [Tag]
..}
instance Property "Description" EmailAddress where
  type PropertyType "Description" EmailAddress = Value Prelude.Text
  set :: PropertyType "Description" EmailAddress
-> EmailAddress -> EmailAddress
set PropertyType "Description" EmailAddress
newValue EmailAddress {Maybe [Tag]
Maybe [AliasConfigurationProperty]
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: EmailAddress -> ()
aliasConfigurations :: EmailAddress -> Maybe [AliasConfigurationProperty]
description :: EmailAddress -> Maybe (Value Text)
displayName :: EmailAddress -> Maybe (Value Text)
emailAddress :: EmailAddress -> Value Text
instanceArn :: EmailAddress -> Value Text
tags :: EmailAddress -> Maybe [Tag]
haddock_workaround_ :: ()
aliasConfigurations :: Maybe [AliasConfigurationProperty]
description :: Maybe (Value Text)
displayName :: Maybe (Value Text)
emailAddress :: Value Text
instanceArn :: Value Text
tags :: Maybe [Tag]
..}
    = EmailAddress {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" EmailAddress
Value Text
newValue, Maybe [Tag]
Maybe [AliasConfigurationProperty]
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ()
aliasConfigurations :: Maybe [AliasConfigurationProperty]
displayName :: Maybe (Value Text)
emailAddress :: Value Text
instanceArn :: Value Text
tags :: Maybe [Tag]
haddock_workaround_ :: ()
aliasConfigurations :: Maybe [AliasConfigurationProperty]
displayName :: Maybe (Value Text)
emailAddress :: Value Text
instanceArn :: Value Text
tags :: Maybe [Tag]
..}
instance Property "DisplayName" EmailAddress where
  type PropertyType "DisplayName" EmailAddress = Value Prelude.Text
  set :: PropertyType "DisplayName" EmailAddress
-> EmailAddress -> EmailAddress
set PropertyType "DisplayName" EmailAddress
newValue EmailAddress {Maybe [Tag]
Maybe [AliasConfigurationProperty]
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: EmailAddress -> ()
aliasConfigurations :: EmailAddress -> Maybe [AliasConfigurationProperty]
description :: EmailAddress -> Maybe (Value Text)
displayName :: EmailAddress -> Maybe (Value Text)
emailAddress :: EmailAddress -> Value Text
instanceArn :: EmailAddress -> Value Text
tags :: EmailAddress -> Maybe [Tag]
haddock_workaround_ :: ()
aliasConfigurations :: Maybe [AliasConfigurationProperty]
description :: Maybe (Value Text)
displayName :: Maybe (Value Text)
emailAddress :: Value Text
instanceArn :: Value Text
tags :: Maybe [Tag]
..}
    = EmailAddress {displayName :: Maybe (Value Text)
displayName = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "DisplayName" EmailAddress
Value Text
newValue, Maybe [Tag]
Maybe [AliasConfigurationProperty]
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ()
aliasConfigurations :: Maybe [AliasConfigurationProperty]
description :: Maybe (Value Text)
emailAddress :: Value Text
instanceArn :: Value Text
tags :: Maybe [Tag]
haddock_workaround_ :: ()
aliasConfigurations :: Maybe [AliasConfigurationProperty]
description :: Maybe (Value Text)
emailAddress :: Value Text
instanceArn :: Value Text
tags :: Maybe [Tag]
..}
instance Property "EmailAddress" EmailAddress where
  type PropertyType "EmailAddress" EmailAddress = Value Prelude.Text
  set :: PropertyType "EmailAddress" EmailAddress
-> EmailAddress -> EmailAddress
set PropertyType "EmailAddress" EmailAddress
newValue EmailAddress {Maybe [Tag]
Maybe [AliasConfigurationProperty]
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: EmailAddress -> ()
aliasConfigurations :: EmailAddress -> Maybe [AliasConfigurationProperty]
description :: EmailAddress -> Maybe (Value Text)
displayName :: EmailAddress -> Maybe (Value Text)
emailAddress :: EmailAddress -> Value Text
instanceArn :: EmailAddress -> Value Text
tags :: EmailAddress -> Maybe [Tag]
haddock_workaround_ :: ()
aliasConfigurations :: Maybe [AliasConfigurationProperty]
description :: Maybe (Value Text)
displayName :: Maybe (Value Text)
emailAddress :: Value Text
instanceArn :: Value Text
tags :: Maybe [Tag]
..}
    = EmailAddress {emailAddress :: Value Text
emailAddress = PropertyType "EmailAddress" EmailAddress
Value Text
newValue, Maybe [Tag]
Maybe [AliasConfigurationProperty]
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ()
aliasConfigurations :: Maybe [AliasConfigurationProperty]
description :: Maybe (Value Text)
displayName :: Maybe (Value Text)
instanceArn :: Value Text
tags :: Maybe [Tag]
haddock_workaround_ :: ()
aliasConfigurations :: Maybe [AliasConfigurationProperty]
description :: Maybe (Value Text)
displayName :: Maybe (Value Text)
instanceArn :: Value Text
tags :: Maybe [Tag]
..}
instance Property "InstanceArn" EmailAddress where
  type PropertyType "InstanceArn" EmailAddress = Value Prelude.Text
  set :: PropertyType "InstanceArn" EmailAddress
-> EmailAddress -> EmailAddress
set PropertyType "InstanceArn" EmailAddress
newValue EmailAddress {Maybe [Tag]
Maybe [AliasConfigurationProperty]
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: EmailAddress -> ()
aliasConfigurations :: EmailAddress -> Maybe [AliasConfigurationProperty]
description :: EmailAddress -> Maybe (Value Text)
displayName :: EmailAddress -> Maybe (Value Text)
emailAddress :: EmailAddress -> Value Text
instanceArn :: EmailAddress -> Value Text
tags :: EmailAddress -> Maybe [Tag]
haddock_workaround_ :: ()
aliasConfigurations :: Maybe [AliasConfigurationProperty]
description :: Maybe (Value Text)
displayName :: Maybe (Value Text)
emailAddress :: Value Text
instanceArn :: Value Text
tags :: Maybe [Tag]
..}
    = EmailAddress {instanceArn :: Value Text
instanceArn = PropertyType "InstanceArn" EmailAddress
Value Text
newValue, Maybe [Tag]
Maybe [AliasConfigurationProperty]
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ()
aliasConfigurations :: Maybe [AliasConfigurationProperty]
description :: Maybe (Value Text)
displayName :: Maybe (Value Text)
emailAddress :: Value Text
tags :: Maybe [Tag]
haddock_workaround_ :: ()
aliasConfigurations :: Maybe [AliasConfigurationProperty]
description :: Maybe (Value Text)
displayName :: Maybe (Value Text)
emailAddress :: Value Text
tags :: Maybe [Tag]
..}
instance Property "Tags" EmailAddress where
  type PropertyType "Tags" EmailAddress = [Tag]
  set :: PropertyType "Tags" EmailAddress -> EmailAddress -> EmailAddress
set PropertyType "Tags" EmailAddress
newValue EmailAddress {Maybe [Tag]
Maybe [AliasConfigurationProperty]
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: EmailAddress -> ()
aliasConfigurations :: EmailAddress -> Maybe [AliasConfigurationProperty]
description :: EmailAddress -> Maybe (Value Text)
displayName :: EmailAddress -> Maybe (Value Text)
emailAddress :: EmailAddress -> Value Text
instanceArn :: EmailAddress -> Value Text
tags :: EmailAddress -> Maybe [Tag]
haddock_workaround_ :: ()
aliasConfigurations :: Maybe [AliasConfigurationProperty]
description :: Maybe (Value Text)
displayName :: Maybe (Value Text)
emailAddress :: Value Text
instanceArn :: Value Text
tags :: Maybe [Tag]
..}
    = EmailAddress {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" EmailAddress
newValue, Maybe [AliasConfigurationProperty]
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ()
aliasConfigurations :: Maybe [AliasConfigurationProperty]
description :: Maybe (Value Text)
displayName :: Maybe (Value Text)
emailAddress :: Value Text
instanceArn :: Value Text
haddock_workaround_ :: ()
aliasConfigurations :: Maybe [AliasConfigurationProperty]
description :: Maybe (Value Text)
displayName :: Maybe (Value Text)
emailAddress :: Value Text
instanceArn :: Value Text
..}