module Stratosphere.DataSync.LocationAzureBlob.CmkSecretConfigProperty (
CmkSecretConfigProperty(..), mkCmkSecretConfigProperty
) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data CmkSecretConfigProperty
=
CmkSecretConfigProperty {CmkSecretConfigProperty -> ()
haddock_workaround_ :: (),
CmkSecretConfigProperty -> Maybe (Value Text)
kmsKeyArn :: (Prelude.Maybe (Value Prelude.Text)),
CmkSecretConfigProperty -> Maybe (Value Text)
secretArn :: (Prelude.Maybe (Value Prelude.Text))}
deriving stock (CmkSecretConfigProperty -> CmkSecretConfigProperty -> Bool
(CmkSecretConfigProperty -> CmkSecretConfigProperty -> Bool)
-> (CmkSecretConfigProperty -> CmkSecretConfigProperty -> Bool)
-> Eq CmkSecretConfigProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: CmkSecretConfigProperty -> CmkSecretConfigProperty -> Bool
== :: CmkSecretConfigProperty -> CmkSecretConfigProperty -> Bool
$c/= :: CmkSecretConfigProperty -> CmkSecretConfigProperty -> Bool
/= :: CmkSecretConfigProperty -> CmkSecretConfigProperty -> Bool
Prelude.Eq, Int -> CmkSecretConfigProperty -> ShowS
[CmkSecretConfigProperty] -> ShowS
CmkSecretConfigProperty -> String
(Int -> CmkSecretConfigProperty -> ShowS)
-> (CmkSecretConfigProperty -> String)
-> ([CmkSecretConfigProperty] -> ShowS)
-> Show CmkSecretConfigProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> CmkSecretConfigProperty -> ShowS
showsPrec :: Int -> CmkSecretConfigProperty -> ShowS
$cshow :: CmkSecretConfigProperty -> String
show :: CmkSecretConfigProperty -> String
$cshowList :: [CmkSecretConfigProperty] -> ShowS
showList :: [CmkSecretConfigProperty] -> ShowS
Prelude.Show)
mkCmkSecretConfigProperty :: CmkSecretConfigProperty
mkCmkSecretConfigProperty :: CmkSecretConfigProperty
mkCmkSecretConfigProperty
= CmkSecretConfigProperty
{haddock_workaround_ :: ()
haddock_workaround_ = (), kmsKeyArn :: Maybe (Value Text)
kmsKeyArn = 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 CmkSecretConfigProperty where
toResourceProperties :: CmkSecretConfigProperty -> ResourceProperties
toResourceProperties CmkSecretConfigProperty {Maybe (Value Text)
()
haddock_workaround_ :: CmkSecretConfigProperty -> ()
kmsKeyArn :: CmkSecretConfigProperty -> Maybe (Value Text)
secretArn :: CmkSecretConfigProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
kmsKeyArn :: Maybe (Value Text)
secretArn :: Maybe (Value Text)
..}
= ResourceProperties
{awsType :: Text
awsType = Text
"AWS::DataSync::LocationAzureBlob.CmkSecretConfig",
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
"KmsKeyArn" (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)
kmsKeyArn,
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 CmkSecretConfigProperty where
toJSON :: CmkSecretConfigProperty -> Value
toJSON CmkSecretConfigProperty {Maybe (Value Text)
()
haddock_workaround_ :: CmkSecretConfigProperty -> ()
kmsKeyArn :: CmkSecretConfigProperty -> Maybe (Value Text)
secretArn :: CmkSecretConfigProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
kmsKeyArn :: 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
([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
"KmsKeyArn" (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)
kmsKeyArn,
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 "KmsKeyArn" CmkSecretConfigProperty where
type PropertyType "KmsKeyArn" CmkSecretConfigProperty = Value Prelude.Text
set :: PropertyType "KmsKeyArn" CmkSecretConfigProperty
-> CmkSecretConfigProperty -> CmkSecretConfigProperty
set PropertyType "KmsKeyArn" CmkSecretConfigProperty
newValue CmkSecretConfigProperty {Maybe (Value Text)
()
haddock_workaround_ :: CmkSecretConfigProperty -> ()
kmsKeyArn :: CmkSecretConfigProperty -> Maybe (Value Text)
secretArn :: CmkSecretConfigProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
kmsKeyArn :: Maybe (Value Text)
secretArn :: Maybe (Value Text)
..}
= CmkSecretConfigProperty {kmsKeyArn :: Maybe (Value Text)
kmsKeyArn = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "KmsKeyArn" CmkSecretConfigProperty
Value Text
newValue, Maybe (Value Text)
()
haddock_workaround_ :: ()
secretArn :: Maybe (Value Text)
haddock_workaround_ :: ()
secretArn :: Maybe (Value Text)
..}
instance Property "SecretArn" CmkSecretConfigProperty where
type PropertyType "SecretArn" CmkSecretConfigProperty = Value Prelude.Text
set :: PropertyType "SecretArn" CmkSecretConfigProperty
-> CmkSecretConfigProperty -> CmkSecretConfigProperty
set PropertyType "SecretArn" CmkSecretConfigProperty
newValue CmkSecretConfigProperty {Maybe (Value Text)
()
haddock_workaround_ :: CmkSecretConfigProperty -> ()
kmsKeyArn :: CmkSecretConfigProperty -> Maybe (Value Text)
secretArn :: CmkSecretConfigProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
kmsKeyArn :: Maybe (Value Text)
secretArn :: Maybe (Value Text)
..}
= CmkSecretConfigProperty {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" CmkSecretConfigProperty
Value Text
newValue, Maybe (Value Text)
()
haddock_workaround_ :: ()
kmsKeyArn :: Maybe (Value Text)
haddock_workaround_ :: ()
kmsKeyArn :: Maybe (Value Text)
..}