module Stratosphere.Wisdom.AIGuardrail.AIGuardrailSensitiveInformationPolicyConfigProperty (
        module Exports,
        AIGuardrailSensitiveInformationPolicyConfigProperty(..),
        mkAIGuardrailSensitiveInformationPolicyConfigProperty
    ) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import {-# SOURCE #-} Stratosphere.Wisdom.AIGuardrail.GuardrailPiiEntityConfigProperty as Exports
import {-# SOURCE #-} Stratosphere.Wisdom.AIGuardrail.GuardrailRegexConfigProperty as Exports
import Stratosphere.ResourceProperties
data AIGuardrailSensitiveInformationPolicyConfigProperty
  = -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-wisdom-aiguardrail-aiguardrailsensitiveinformationpolicyconfig.html>
    AIGuardrailSensitiveInformationPolicyConfigProperty {AIGuardrailSensitiveInformationPolicyConfigProperty -> ()
haddock_workaround_ :: (),
                                                         -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-wisdom-aiguardrail-aiguardrailsensitiveinformationpolicyconfig.html#cfn-wisdom-aiguardrail-aiguardrailsensitiveinformationpolicyconfig-piientitiesconfig>
                                                         AIGuardrailSensitiveInformationPolicyConfigProperty
-> Maybe [GuardrailPiiEntityConfigProperty]
piiEntitiesConfig :: (Prelude.Maybe [GuardrailPiiEntityConfigProperty]),
                                                         -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-wisdom-aiguardrail-aiguardrailsensitiveinformationpolicyconfig.html#cfn-wisdom-aiguardrail-aiguardrailsensitiveinformationpolicyconfig-regexesconfig>
                                                         AIGuardrailSensitiveInformationPolicyConfigProperty
-> Maybe [GuardrailRegexConfigProperty]
regexesConfig :: (Prelude.Maybe [GuardrailRegexConfigProperty])}
  deriving stock (AIGuardrailSensitiveInformationPolicyConfigProperty
-> AIGuardrailSensitiveInformationPolicyConfigProperty -> Bool
(AIGuardrailSensitiveInformationPolicyConfigProperty
 -> AIGuardrailSensitiveInformationPolicyConfigProperty -> Bool)
-> (AIGuardrailSensitiveInformationPolicyConfigProperty
    -> AIGuardrailSensitiveInformationPolicyConfigProperty -> Bool)
-> Eq AIGuardrailSensitiveInformationPolicyConfigProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: AIGuardrailSensitiveInformationPolicyConfigProperty
-> AIGuardrailSensitiveInformationPolicyConfigProperty -> Bool
== :: AIGuardrailSensitiveInformationPolicyConfigProperty
-> AIGuardrailSensitiveInformationPolicyConfigProperty -> Bool
$c/= :: AIGuardrailSensitiveInformationPolicyConfigProperty
-> AIGuardrailSensitiveInformationPolicyConfigProperty -> Bool
/= :: AIGuardrailSensitiveInformationPolicyConfigProperty
-> AIGuardrailSensitiveInformationPolicyConfigProperty -> Bool
Prelude.Eq, Int -> AIGuardrailSensitiveInformationPolicyConfigProperty -> ShowS
[AIGuardrailSensitiveInformationPolicyConfigProperty] -> ShowS
AIGuardrailSensitiveInformationPolicyConfigProperty -> String
(Int
 -> AIGuardrailSensitiveInformationPolicyConfigProperty -> ShowS)
-> (AIGuardrailSensitiveInformationPolicyConfigProperty -> String)
-> ([AIGuardrailSensitiveInformationPolicyConfigProperty] -> ShowS)
-> Show AIGuardrailSensitiveInformationPolicyConfigProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> AIGuardrailSensitiveInformationPolicyConfigProperty -> ShowS
showsPrec :: Int -> AIGuardrailSensitiveInformationPolicyConfigProperty -> ShowS
$cshow :: AIGuardrailSensitiveInformationPolicyConfigProperty -> String
show :: AIGuardrailSensitiveInformationPolicyConfigProperty -> String
$cshowList :: [AIGuardrailSensitiveInformationPolicyConfigProperty] -> ShowS
showList :: [AIGuardrailSensitiveInformationPolicyConfigProperty] -> ShowS
Prelude.Show)
mkAIGuardrailSensitiveInformationPolicyConfigProperty ::
  AIGuardrailSensitiveInformationPolicyConfigProperty
mkAIGuardrailSensitiveInformationPolicyConfigProperty :: AIGuardrailSensitiveInformationPolicyConfigProperty
mkAIGuardrailSensitiveInformationPolicyConfigProperty
  = AIGuardrailSensitiveInformationPolicyConfigProperty
      {haddock_workaround_ :: ()
haddock_workaround_ = (), piiEntitiesConfig :: Maybe [GuardrailPiiEntityConfigProperty]
piiEntitiesConfig = Maybe [GuardrailPiiEntityConfigProperty]
forall a. Maybe a
Prelude.Nothing,
       regexesConfig :: Maybe [GuardrailRegexConfigProperty]
regexesConfig = Maybe [GuardrailRegexConfigProperty]
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties AIGuardrailSensitiveInformationPolicyConfigProperty where
  toResourceProperties :: AIGuardrailSensitiveInformationPolicyConfigProperty
-> ResourceProperties
toResourceProperties
    AIGuardrailSensitiveInformationPolicyConfigProperty {Maybe [GuardrailPiiEntityConfigProperty]
Maybe [GuardrailRegexConfigProperty]
()
haddock_workaround_ :: AIGuardrailSensitiveInformationPolicyConfigProperty -> ()
piiEntitiesConfig :: AIGuardrailSensitiveInformationPolicyConfigProperty
-> Maybe [GuardrailPiiEntityConfigProperty]
regexesConfig :: AIGuardrailSensitiveInformationPolicyConfigProperty
-> Maybe [GuardrailRegexConfigProperty]
haddock_workaround_ :: ()
piiEntitiesConfig :: Maybe [GuardrailPiiEntityConfigProperty]
regexesConfig :: Maybe [GuardrailRegexConfigProperty]
..}
    = ResourceProperties
        {awsType :: Text
awsType = Text
"AWS::Wisdom::AIGuardrail.AIGuardrailSensitiveInformationPolicyConfig",
         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 -> [GuardrailPiiEntityConfigProperty] -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"PiiEntitiesConfig" ([GuardrailPiiEntityConfigProperty] -> (Key, Value))
-> Maybe [GuardrailPiiEntityConfigProperty] -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [GuardrailPiiEntityConfigProperty]
piiEntitiesConfig,
                            Key -> [GuardrailRegexConfigProperty] -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"RegexesConfig" ([GuardrailRegexConfigProperty] -> (Key, Value))
-> Maybe [GuardrailRegexConfigProperty] -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [GuardrailRegexConfigProperty]
regexesConfig])}
instance JSON.ToJSON AIGuardrailSensitiveInformationPolicyConfigProperty where
  toJSON :: AIGuardrailSensitiveInformationPolicyConfigProperty -> Value
toJSON AIGuardrailSensitiveInformationPolicyConfigProperty {Maybe [GuardrailPiiEntityConfigProperty]
Maybe [GuardrailRegexConfigProperty]
()
haddock_workaround_ :: AIGuardrailSensitiveInformationPolicyConfigProperty -> ()
piiEntitiesConfig :: AIGuardrailSensitiveInformationPolicyConfigProperty
-> Maybe [GuardrailPiiEntityConfigProperty]
regexesConfig :: AIGuardrailSensitiveInformationPolicyConfigProperty
-> Maybe [GuardrailRegexConfigProperty]
haddock_workaround_ :: ()
piiEntitiesConfig :: Maybe [GuardrailPiiEntityConfigProperty]
regexesConfig :: Maybe [GuardrailRegexConfigProperty]
..}
    = [(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 -> [GuardrailPiiEntityConfigProperty] -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"PiiEntitiesConfig" ([GuardrailPiiEntityConfigProperty] -> (Key, Value))
-> Maybe [GuardrailPiiEntityConfigProperty] -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [GuardrailPiiEntityConfigProperty]
piiEntitiesConfig,
               Key -> [GuardrailRegexConfigProperty] -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"RegexesConfig" ([GuardrailRegexConfigProperty] -> (Key, Value))
-> Maybe [GuardrailRegexConfigProperty] -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [GuardrailRegexConfigProperty]
regexesConfig]))
instance Property "PiiEntitiesConfig" AIGuardrailSensitiveInformationPolicyConfigProperty where
  type PropertyType "PiiEntitiesConfig" AIGuardrailSensitiveInformationPolicyConfigProperty = [GuardrailPiiEntityConfigProperty]
  set :: PropertyType
  "PiiEntitiesConfig"
  AIGuardrailSensitiveInformationPolicyConfigProperty
-> AIGuardrailSensitiveInformationPolicyConfigProperty
-> AIGuardrailSensitiveInformationPolicyConfigProperty
set
    PropertyType
  "PiiEntitiesConfig"
  AIGuardrailSensitiveInformationPolicyConfigProperty
newValue
    AIGuardrailSensitiveInformationPolicyConfigProperty {Maybe [GuardrailPiiEntityConfigProperty]
Maybe [GuardrailRegexConfigProperty]
()
haddock_workaround_ :: AIGuardrailSensitiveInformationPolicyConfigProperty -> ()
piiEntitiesConfig :: AIGuardrailSensitiveInformationPolicyConfigProperty
-> Maybe [GuardrailPiiEntityConfigProperty]
regexesConfig :: AIGuardrailSensitiveInformationPolicyConfigProperty
-> Maybe [GuardrailRegexConfigProperty]
haddock_workaround_ :: ()
piiEntitiesConfig :: Maybe [GuardrailPiiEntityConfigProperty]
regexesConfig :: Maybe [GuardrailRegexConfigProperty]
..}
    = AIGuardrailSensitiveInformationPolicyConfigProperty
        {piiEntitiesConfig :: Maybe [GuardrailPiiEntityConfigProperty]
piiEntitiesConfig = [GuardrailPiiEntityConfigProperty]
-> Maybe [GuardrailPiiEntityConfigProperty]
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure [GuardrailPiiEntityConfigProperty]
PropertyType
  "PiiEntitiesConfig"
  AIGuardrailSensitiveInformationPolicyConfigProperty
newValue, Maybe [GuardrailRegexConfigProperty]
()
haddock_workaround_ :: ()
regexesConfig :: Maybe [GuardrailRegexConfigProperty]
haddock_workaround_ :: ()
regexesConfig :: Maybe [GuardrailRegexConfigProperty]
..}
instance Property "RegexesConfig" AIGuardrailSensitiveInformationPolicyConfigProperty where
  type PropertyType "RegexesConfig" AIGuardrailSensitiveInformationPolicyConfigProperty = [GuardrailRegexConfigProperty]
  set :: PropertyType
  "RegexesConfig" AIGuardrailSensitiveInformationPolicyConfigProperty
-> AIGuardrailSensitiveInformationPolicyConfigProperty
-> AIGuardrailSensitiveInformationPolicyConfigProperty
set
    PropertyType
  "RegexesConfig" AIGuardrailSensitiveInformationPolicyConfigProperty
newValue
    AIGuardrailSensitiveInformationPolicyConfigProperty {Maybe [GuardrailPiiEntityConfigProperty]
Maybe [GuardrailRegexConfigProperty]
()
haddock_workaround_ :: AIGuardrailSensitiveInformationPolicyConfigProperty -> ()
piiEntitiesConfig :: AIGuardrailSensitiveInformationPolicyConfigProperty
-> Maybe [GuardrailPiiEntityConfigProperty]
regexesConfig :: AIGuardrailSensitiveInformationPolicyConfigProperty
-> Maybe [GuardrailRegexConfigProperty]
haddock_workaround_ :: ()
piiEntitiesConfig :: Maybe [GuardrailPiiEntityConfigProperty]
regexesConfig :: Maybe [GuardrailRegexConfigProperty]
..}
    = AIGuardrailSensitiveInformationPolicyConfigProperty
        {regexesConfig :: Maybe [GuardrailRegexConfigProperty]
regexesConfig = [GuardrailRegexConfigProperty]
-> Maybe [GuardrailRegexConfigProperty]
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure [GuardrailRegexConfigProperty]
PropertyType
  "RegexesConfig" AIGuardrailSensitiveInformationPolicyConfigProperty
newValue, Maybe [GuardrailPiiEntityConfigProperty]
()
haddock_workaround_ :: ()
piiEntitiesConfig :: Maybe [GuardrailPiiEntityConfigProperty]
haddock_workaround_ :: ()
piiEntitiesConfig :: Maybe [GuardrailPiiEntityConfigProperty]
..}