module Stratosphere.Connect.EvaluationForm.AutomaticFailConfigurationProperty (
AutomaticFailConfigurationProperty(..),
mkAutomaticFailConfigurationProperty
) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data AutomaticFailConfigurationProperty
=
AutomaticFailConfigurationProperty {AutomaticFailConfigurationProperty -> ()
haddock_workaround_ :: (),
AutomaticFailConfigurationProperty -> Maybe (Value Text)
targetSection :: (Prelude.Maybe (Value Prelude.Text))}
deriving stock (AutomaticFailConfigurationProperty
-> AutomaticFailConfigurationProperty -> Bool
(AutomaticFailConfigurationProperty
-> AutomaticFailConfigurationProperty -> Bool)
-> (AutomaticFailConfigurationProperty
-> AutomaticFailConfigurationProperty -> Bool)
-> Eq AutomaticFailConfigurationProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: AutomaticFailConfigurationProperty
-> AutomaticFailConfigurationProperty -> Bool
== :: AutomaticFailConfigurationProperty
-> AutomaticFailConfigurationProperty -> Bool
$c/= :: AutomaticFailConfigurationProperty
-> AutomaticFailConfigurationProperty -> Bool
/= :: AutomaticFailConfigurationProperty
-> AutomaticFailConfigurationProperty -> Bool
Prelude.Eq, Int -> AutomaticFailConfigurationProperty -> ShowS
[AutomaticFailConfigurationProperty] -> ShowS
AutomaticFailConfigurationProperty -> String
(Int -> AutomaticFailConfigurationProperty -> ShowS)
-> (AutomaticFailConfigurationProperty -> String)
-> ([AutomaticFailConfigurationProperty] -> ShowS)
-> Show AutomaticFailConfigurationProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> AutomaticFailConfigurationProperty -> ShowS
showsPrec :: Int -> AutomaticFailConfigurationProperty -> ShowS
$cshow :: AutomaticFailConfigurationProperty -> String
show :: AutomaticFailConfigurationProperty -> String
$cshowList :: [AutomaticFailConfigurationProperty] -> ShowS
showList :: [AutomaticFailConfigurationProperty] -> ShowS
Prelude.Show)
mkAutomaticFailConfigurationProperty ::
AutomaticFailConfigurationProperty
mkAutomaticFailConfigurationProperty :: AutomaticFailConfigurationProperty
mkAutomaticFailConfigurationProperty
= AutomaticFailConfigurationProperty
{haddock_workaround_ :: ()
haddock_workaround_ = (), targetSection :: Maybe (Value Text)
targetSection = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties AutomaticFailConfigurationProperty where
toResourceProperties :: AutomaticFailConfigurationProperty -> ResourceProperties
toResourceProperties AutomaticFailConfigurationProperty {Maybe (Value Text)
()
haddock_workaround_ :: AutomaticFailConfigurationProperty -> ()
targetSection :: AutomaticFailConfigurationProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
targetSection :: Maybe (Value Text)
..}
= ResourceProperties
{awsType :: Text
awsType = Text
"AWS::Connect::EvaluationForm.AutomaticFailConfiguration",
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 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
"TargetSection" (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)
targetSection])}
instance JSON.ToJSON AutomaticFailConfigurationProperty where
toJSON :: AutomaticFailConfigurationProperty -> Value
toJSON AutomaticFailConfigurationProperty {Maybe (Value Text)
()
haddock_workaround_ :: AutomaticFailConfigurationProperty -> ()
targetSection :: AutomaticFailConfigurationProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
targetSection :: Maybe (Value Text)
..}
= [(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 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
"TargetSection" (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)
targetSection]))
instance Property "TargetSection" AutomaticFailConfigurationProperty where
type PropertyType "TargetSection" AutomaticFailConfigurationProperty = Value Prelude.Text
set :: PropertyType "TargetSection" AutomaticFailConfigurationProperty
-> AutomaticFailConfigurationProperty
-> AutomaticFailConfigurationProperty
set PropertyType "TargetSection" AutomaticFailConfigurationProperty
newValue AutomaticFailConfigurationProperty {Maybe (Value Text)
()
haddock_workaround_ :: AutomaticFailConfigurationProperty -> ()
targetSection :: AutomaticFailConfigurationProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
targetSection :: Maybe (Value Text)
..}
= AutomaticFailConfigurationProperty
{targetSection :: Maybe (Value Text)
targetSection = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "TargetSection" AutomaticFailConfigurationProperty
Value Text
newValue, ()
haddock_workaround_ :: ()
haddock_workaround_ :: ()
..}