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