module Stratosphere.WAFv2.WebACL.CaptchaConfigProperty (
module Exports, CaptchaConfigProperty(..), mkCaptchaConfigProperty
) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import {-# SOURCE #-} Stratosphere.WAFv2.WebACL.ImmunityTimePropertyProperty as Exports
import Stratosphere.ResourceProperties
data CaptchaConfigProperty
=
CaptchaConfigProperty {CaptchaConfigProperty -> ()
haddock_workaround_ :: (),
CaptchaConfigProperty -> Maybe ImmunityTimePropertyProperty
immunityTimeProperty :: (Prelude.Maybe ImmunityTimePropertyProperty)}
deriving stock (CaptchaConfigProperty -> CaptchaConfigProperty -> Bool
(CaptchaConfigProperty -> CaptchaConfigProperty -> Bool)
-> (CaptchaConfigProperty -> CaptchaConfigProperty -> Bool)
-> Eq CaptchaConfigProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: CaptchaConfigProperty -> CaptchaConfigProperty -> Bool
== :: CaptchaConfigProperty -> CaptchaConfigProperty -> Bool
$c/= :: CaptchaConfigProperty -> CaptchaConfigProperty -> Bool
/= :: CaptchaConfigProperty -> CaptchaConfigProperty -> Bool
Prelude.Eq, Int -> CaptchaConfigProperty -> ShowS
[CaptchaConfigProperty] -> ShowS
CaptchaConfigProperty -> String
(Int -> CaptchaConfigProperty -> ShowS)
-> (CaptchaConfigProperty -> String)
-> ([CaptchaConfigProperty] -> ShowS)
-> Show CaptchaConfigProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> CaptchaConfigProperty -> ShowS
showsPrec :: Int -> CaptchaConfigProperty -> ShowS
$cshow :: CaptchaConfigProperty -> String
show :: CaptchaConfigProperty -> String
$cshowList :: [CaptchaConfigProperty] -> ShowS
showList :: [CaptchaConfigProperty] -> ShowS
Prelude.Show)
mkCaptchaConfigProperty :: CaptchaConfigProperty
mkCaptchaConfigProperty :: CaptchaConfigProperty
mkCaptchaConfigProperty
= CaptchaConfigProperty
{haddock_workaround_ :: ()
haddock_workaround_ = (), immunityTimeProperty :: Maybe ImmunityTimePropertyProperty
immunityTimeProperty = Maybe ImmunityTimePropertyProperty
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties CaptchaConfigProperty where
toResourceProperties :: CaptchaConfigProperty -> ResourceProperties
toResourceProperties CaptchaConfigProperty {Maybe ImmunityTimePropertyProperty
()
haddock_workaround_ :: CaptchaConfigProperty -> ()
immunityTimeProperty :: CaptchaConfigProperty -> Maybe ImmunityTimePropertyProperty
haddock_workaround_ :: ()
immunityTimeProperty :: Maybe ImmunityTimePropertyProperty
..}
= ResourceProperties
{awsType :: Text
awsType = Text
"AWS::WAFv2::WebACL.CaptchaConfig",
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 -> ImmunityTimePropertyProperty -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"ImmunityTimeProperty"
(ImmunityTimePropertyProperty -> (Key, Value))
-> Maybe ImmunityTimePropertyProperty -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe ImmunityTimePropertyProperty
immunityTimeProperty])}
instance JSON.ToJSON CaptchaConfigProperty where
toJSON :: CaptchaConfigProperty -> Value
toJSON CaptchaConfigProperty {Maybe ImmunityTimePropertyProperty
()
haddock_workaround_ :: CaptchaConfigProperty -> ()
immunityTimeProperty :: CaptchaConfigProperty -> Maybe ImmunityTimePropertyProperty
haddock_workaround_ :: ()
immunityTimeProperty :: Maybe ImmunityTimePropertyProperty
..}
= [(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 -> ImmunityTimePropertyProperty -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"ImmunityTimeProperty"
(ImmunityTimePropertyProperty -> (Key, Value))
-> Maybe ImmunityTimePropertyProperty -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe ImmunityTimePropertyProperty
immunityTimeProperty]))
instance Property "ImmunityTimeProperty" CaptchaConfigProperty where
type PropertyType "ImmunityTimeProperty" CaptchaConfigProperty = ImmunityTimePropertyProperty
set :: PropertyType "ImmunityTimeProperty" CaptchaConfigProperty
-> CaptchaConfigProperty -> CaptchaConfigProperty
set PropertyType "ImmunityTimeProperty" CaptchaConfigProperty
newValue CaptchaConfigProperty {Maybe ImmunityTimePropertyProperty
()
haddock_workaround_ :: CaptchaConfigProperty -> ()
immunityTimeProperty :: CaptchaConfigProperty -> Maybe ImmunityTimePropertyProperty
haddock_workaround_ :: ()
immunityTimeProperty :: Maybe ImmunityTimePropertyProperty
..}
= CaptchaConfigProperty
{immunityTimeProperty :: Maybe ImmunityTimePropertyProperty
immunityTimeProperty = ImmunityTimePropertyProperty -> Maybe ImmunityTimePropertyProperty
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "ImmunityTimeProperty" CaptchaConfigProperty
ImmunityTimePropertyProperty
newValue, ()
haddock_workaround_ :: ()
haddock_workaround_ :: ()
..}