module Stratosphere.KinesisFirehose.DeliveryStream.SecretsManagerConfigurationProperty (
        SecretsManagerConfigurationProperty(..),
        mkSecretsManagerConfigurationProperty
    ) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data SecretsManagerConfigurationProperty
  = -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-kinesisfirehose-deliverystream-secretsmanagerconfiguration.html>
    SecretsManagerConfigurationProperty {SecretsManagerConfigurationProperty -> ()
haddock_workaround_ :: (),
                                         -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-kinesisfirehose-deliverystream-secretsmanagerconfiguration.html#cfn-kinesisfirehose-deliverystream-secretsmanagerconfiguration-enabled>
                                         SecretsManagerConfigurationProperty -> Value Bool
enabled :: (Value Prelude.Bool),
                                         -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-kinesisfirehose-deliverystream-secretsmanagerconfiguration.html#cfn-kinesisfirehose-deliverystream-secretsmanagerconfiguration-rolearn>
                                         SecretsManagerConfigurationProperty -> Maybe (Value Text)
roleARN :: (Prelude.Maybe (Value Prelude.Text)),
                                         -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-kinesisfirehose-deliverystream-secretsmanagerconfiguration.html#cfn-kinesisfirehose-deliverystream-secretsmanagerconfiguration-secretarn>
                                         SecretsManagerConfigurationProperty -> Maybe (Value Text)
secretARN :: (Prelude.Maybe (Value Prelude.Text))}
  deriving stock (SecretsManagerConfigurationProperty
-> SecretsManagerConfigurationProperty -> Bool
(SecretsManagerConfigurationProperty
 -> SecretsManagerConfigurationProperty -> Bool)
-> (SecretsManagerConfigurationProperty
    -> SecretsManagerConfigurationProperty -> Bool)
-> Eq SecretsManagerConfigurationProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: SecretsManagerConfigurationProperty
-> SecretsManagerConfigurationProperty -> Bool
== :: SecretsManagerConfigurationProperty
-> SecretsManagerConfigurationProperty -> Bool
$c/= :: SecretsManagerConfigurationProperty
-> SecretsManagerConfigurationProperty -> Bool
/= :: SecretsManagerConfigurationProperty
-> SecretsManagerConfigurationProperty -> Bool
Prelude.Eq, Int -> SecretsManagerConfigurationProperty -> ShowS
[SecretsManagerConfigurationProperty] -> ShowS
SecretsManagerConfigurationProperty -> String
(Int -> SecretsManagerConfigurationProperty -> ShowS)
-> (SecretsManagerConfigurationProperty -> String)
-> ([SecretsManagerConfigurationProperty] -> ShowS)
-> Show SecretsManagerConfigurationProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> SecretsManagerConfigurationProperty -> ShowS
showsPrec :: Int -> SecretsManagerConfigurationProperty -> ShowS
$cshow :: SecretsManagerConfigurationProperty -> String
show :: SecretsManagerConfigurationProperty -> String
$cshowList :: [SecretsManagerConfigurationProperty] -> ShowS
showList :: [SecretsManagerConfigurationProperty] -> ShowS
Prelude.Show)
mkSecretsManagerConfigurationProperty ::
  Value Prelude.Bool -> SecretsManagerConfigurationProperty
mkSecretsManagerConfigurationProperty :: Value Bool -> SecretsManagerConfigurationProperty
mkSecretsManagerConfigurationProperty Value Bool
enabled
  = SecretsManagerConfigurationProperty
      {haddock_workaround_ :: ()
haddock_workaround_ = (), enabled :: Value Bool
enabled = Value Bool
enabled,
       roleARN :: Maybe (Value Text)
roleARN = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing, secretARN :: Maybe (Value Text)
secretARN = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties SecretsManagerConfigurationProperty where
  toResourceProperties :: SecretsManagerConfigurationProperty -> ResourceProperties
toResourceProperties SecretsManagerConfigurationProperty {Maybe (Value Text)
()
Value Bool
haddock_workaround_ :: SecretsManagerConfigurationProperty -> ()
enabled :: SecretsManagerConfigurationProperty -> Value Bool
roleARN :: SecretsManagerConfigurationProperty -> Maybe (Value Text)
secretARN :: SecretsManagerConfigurationProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
enabled :: Value Bool
roleARN :: Maybe (Value Text)
secretARN :: Maybe (Value Text)
..}
    = ResourceProperties
        {awsType :: Text
awsType = Text
"AWS::KinesisFirehose::DeliveryStream.SecretsManagerConfiguration",
         supportsTags :: Bool
supportsTags = Bool
Prelude.False,
         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
"Enabled" Key -> Value Bool -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= Value Bool
enabled]
                           ([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
"RoleARN" (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)
roleARN,
                               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
"SecretARN" (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)
secretARN]))}
instance JSON.ToJSON SecretsManagerConfigurationProperty where
  toJSON :: SecretsManagerConfigurationProperty -> Value
toJSON SecretsManagerConfigurationProperty {Maybe (Value Text)
()
Value Bool
haddock_workaround_ :: SecretsManagerConfigurationProperty -> ()
enabled :: SecretsManagerConfigurationProperty -> Value Bool
roleARN :: SecretsManagerConfigurationProperty -> Maybe (Value Text)
secretARN :: SecretsManagerConfigurationProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
enabled :: Value Bool
roleARN :: Maybe (Value Text)
secretARN :: Maybe (Value Text)
..}
    = [(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
"Enabled" Key -> Value Bool -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= Value Bool
enabled]
              ([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
"RoleARN" (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)
roleARN,
                  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
"SecretARN" (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)
secretARN])))
instance Property "Enabled" SecretsManagerConfigurationProperty where
  type PropertyType "Enabled" SecretsManagerConfigurationProperty = Value Prelude.Bool
  set :: PropertyType "Enabled" SecretsManagerConfigurationProperty
-> SecretsManagerConfigurationProperty
-> SecretsManagerConfigurationProperty
set PropertyType "Enabled" SecretsManagerConfigurationProperty
newValue SecretsManagerConfigurationProperty {Maybe (Value Text)
()
Value Bool
haddock_workaround_ :: SecretsManagerConfigurationProperty -> ()
enabled :: SecretsManagerConfigurationProperty -> Value Bool
roleARN :: SecretsManagerConfigurationProperty -> Maybe (Value Text)
secretARN :: SecretsManagerConfigurationProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
enabled :: Value Bool
roleARN :: Maybe (Value Text)
secretARN :: Maybe (Value Text)
..}
    = SecretsManagerConfigurationProperty {enabled :: Value Bool
enabled = PropertyType "Enabled" SecretsManagerConfigurationProperty
Value Bool
newValue, Maybe (Value Text)
()
haddock_workaround_ :: ()
roleARN :: Maybe (Value Text)
secretARN :: Maybe (Value Text)
haddock_workaround_ :: ()
roleARN :: Maybe (Value Text)
secretARN :: Maybe (Value Text)
..}
instance Property "RoleARN" SecretsManagerConfigurationProperty where
  type PropertyType "RoleARN" SecretsManagerConfigurationProperty = Value Prelude.Text
  set :: PropertyType "RoleARN" SecretsManagerConfigurationProperty
-> SecretsManagerConfigurationProperty
-> SecretsManagerConfigurationProperty
set PropertyType "RoleARN" SecretsManagerConfigurationProperty
newValue SecretsManagerConfigurationProperty {Maybe (Value Text)
()
Value Bool
haddock_workaround_ :: SecretsManagerConfigurationProperty -> ()
enabled :: SecretsManagerConfigurationProperty -> Value Bool
roleARN :: SecretsManagerConfigurationProperty -> Maybe (Value Text)
secretARN :: SecretsManagerConfigurationProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
enabled :: Value Bool
roleARN :: Maybe (Value Text)
secretARN :: Maybe (Value Text)
..}
    = SecretsManagerConfigurationProperty
        {roleARN :: Maybe (Value Text)
roleARN = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "RoleARN" SecretsManagerConfigurationProperty
Value Text
newValue, Maybe (Value Text)
()
Value Bool
haddock_workaround_ :: ()
enabled :: Value Bool
secretARN :: Maybe (Value Text)
haddock_workaround_ :: ()
enabled :: Value Bool
secretARN :: Maybe (Value Text)
..}
instance Property "SecretARN" SecretsManagerConfigurationProperty where
  type PropertyType "SecretARN" SecretsManagerConfigurationProperty = Value Prelude.Text
  set :: PropertyType "SecretARN" SecretsManagerConfigurationProperty
-> SecretsManagerConfigurationProperty
-> SecretsManagerConfigurationProperty
set PropertyType "SecretARN" SecretsManagerConfigurationProperty
newValue SecretsManagerConfigurationProperty {Maybe (Value Text)
()
Value Bool
haddock_workaround_ :: SecretsManagerConfigurationProperty -> ()
enabled :: SecretsManagerConfigurationProperty -> Value Bool
roleARN :: SecretsManagerConfigurationProperty -> Maybe (Value Text)
secretARN :: SecretsManagerConfigurationProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
enabled :: Value Bool
roleARN :: Maybe (Value Text)
secretARN :: Maybe (Value Text)
..}
    = SecretsManagerConfigurationProperty
        {secretARN :: Maybe (Value Text)
secretARN = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "SecretARN" SecretsManagerConfigurationProperty
Value Text
newValue, Maybe (Value Text)
()
Value Bool
haddock_workaround_ :: ()
enabled :: Value Bool
roleARN :: Maybe (Value Text)
haddock_workaround_ :: ()
enabled :: Value Bool
roleARN :: Maybe (Value Text)
..}