module Stratosphere.Athena.WorkGroup.ManagedStorageEncryptionConfigurationProperty (
        ManagedStorageEncryptionConfigurationProperty(..),
        mkManagedStorageEncryptionConfigurationProperty
    ) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data ManagedStorageEncryptionConfigurationProperty
  = -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-athena-workgroup-managedstorageencryptionconfiguration.html>
    ManagedStorageEncryptionConfigurationProperty {ManagedStorageEncryptionConfigurationProperty -> ()
haddock_workaround_ :: (),
                                                   -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-athena-workgroup-managedstorageencryptionconfiguration.html#cfn-athena-workgroup-managedstorageencryptionconfiguration-kmskey>
                                                   ManagedStorageEncryptionConfigurationProperty -> Maybe (Value Text)
kmsKey :: (Prelude.Maybe (Value Prelude.Text))}
  deriving stock (ManagedStorageEncryptionConfigurationProperty
-> ManagedStorageEncryptionConfigurationProperty -> Bool
(ManagedStorageEncryptionConfigurationProperty
 -> ManagedStorageEncryptionConfigurationProperty -> Bool)
-> (ManagedStorageEncryptionConfigurationProperty
    -> ManagedStorageEncryptionConfigurationProperty -> Bool)
-> Eq ManagedStorageEncryptionConfigurationProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: ManagedStorageEncryptionConfigurationProperty
-> ManagedStorageEncryptionConfigurationProperty -> Bool
== :: ManagedStorageEncryptionConfigurationProperty
-> ManagedStorageEncryptionConfigurationProperty -> Bool
$c/= :: ManagedStorageEncryptionConfigurationProperty
-> ManagedStorageEncryptionConfigurationProperty -> Bool
/= :: ManagedStorageEncryptionConfigurationProperty
-> ManagedStorageEncryptionConfigurationProperty -> Bool
Prelude.Eq, Int -> ManagedStorageEncryptionConfigurationProperty -> ShowS
[ManagedStorageEncryptionConfigurationProperty] -> ShowS
ManagedStorageEncryptionConfigurationProperty -> String
(Int -> ManagedStorageEncryptionConfigurationProperty -> ShowS)
-> (ManagedStorageEncryptionConfigurationProperty -> String)
-> ([ManagedStorageEncryptionConfigurationProperty] -> ShowS)
-> Show ManagedStorageEncryptionConfigurationProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> ManagedStorageEncryptionConfigurationProperty -> ShowS
showsPrec :: Int -> ManagedStorageEncryptionConfigurationProperty -> ShowS
$cshow :: ManagedStorageEncryptionConfigurationProperty -> String
show :: ManagedStorageEncryptionConfigurationProperty -> String
$cshowList :: [ManagedStorageEncryptionConfigurationProperty] -> ShowS
showList :: [ManagedStorageEncryptionConfigurationProperty] -> ShowS
Prelude.Show)
mkManagedStorageEncryptionConfigurationProperty ::
  ManagedStorageEncryptionConfigurationProperty
mkManagedStorageEncryptionConfigurationProperty :: ManagedStorageEncryptionConfigurationProperty
mkManagedStorageEncryptionConfigurationProperty
  = ManagedStorageEncryptionConfigurationProperty
      {haddock_workaround_ :: ()
haddock_workaround_ = (), kmsKey :: Maybe (Value Text)
kmsKey = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties ManagedStorageEncryptionConfigurationProperty where
  toResourceProperties :: ManagedStorageEncryptionConfigurationProperty -> ResourceProperties
toResourceProperties
    ManagedStorageEncryptionConfigurationProperty {Maybe (Value Text)
()
haddock_workaround_ :: ManagedStorageEncryptionConfigurationProperty -> ()
kmsKey :: ManagedStorageEncryptionConfigurationProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
kmsKey :: Maybe (Value Text)
..}
    = ResourceProperties
        {awsType :: Text
awsType = Text
"AWS::Athena::WorkGroup.ManagedStorageEncryptionConfiguration",
         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
"KmsKey" (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)
kmsKey])}
instance JSON.ToJSON ManagedStorageEncryptionConfigurationProperty where
  toJSON :: ManagedStorageEncryptionConfigurationProperty -> Value
toJSON ManagedStorageEncryptionConfigurationProperty {Maybe (Value Text)
()
haddock_workaround_ :: ManagedStorageEncryptionConfigurationProperty -> ()
kmsKey :: ManagedStorageEncryptionConfigurationProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
kmsKey :: 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
"KmsKey" (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)
kmsKey]))
instance Property "KmsKey" ManagedStorageEncryptionConfigurationProperty where
  type PropertyType "KmsKey" ManagedStorageEncryptionConfigurationProperty = Value Prelude.Text
  set :: PropertyType "KmsKey" ManagedStorageEncryptionConfigurationProperty
-> ManagedStorageEncryptionConfigurationProperty
-> ManagedStorageEncryptionConfigurationProperty
set PropertyType "KmsKey" ManagedStorageEncryptionConfigurationProperty
newValue ManagedStorageEncryptionConfigurationProperty {Maybe (Value Text)
()
haddock_workaround_ :: ManagedStorageEncryptionConfigurationProperty -> ()
kmsKey :: ManagedStorageEncryptionConfigurationProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
kmsKey :: Maybe (Value Text)
..}
    = ManagedStorageEncryptionConfigurationProperty
        {kmsKey :: Maybe (Value Text)
kmsKey = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "KmsKey" ManagedStorageEncryptionConfigurationProperty
Value Text
newValue, ()
haddock_workaround_ :: ()
haddock_workaround_ :: ()
..}