packages feed

stratosphere-datasync-1.0.0: gen/Stratosphere/DataSync/LocationObjectStorage/CmkSecretConfigProperty.hs

module Stratosphere.DataSync.LocationObjectStorage.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
  = -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-datasync-locationobjectstorage-cmksecretconfig.html>
    CmkSecretConfigProperty {haddock_workaround_ :: (),
                             -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-datasync-locationobjectstorage-cmksecretconfig.html#cfn-datasync-locationobjectstorage-cmksecretconfig-kmskeyarn>
                             kmsKeyArn :: (Prelude.Maybe (Value Prelude.Text)),
                             -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-datasync-locationobjectstorage-cmksecretconfig.html#cfn-datasync-locationobjectstorage-cmksecretconfig-secretarn>
                             secretArn :: (Prelude.Maybe (Value Prelude.Text))}
  deriving stock (Prelude.Eq, Prelude.Show)
mkCmkSecretConfigProperty :: CmkSecretConfigProperty
mkCmkSecretConfigProperty
  = CmkSecretConfigProperty
      {haddock_workaround_ = (), kmsKeyArn = Prelude.Nothing,
       secretArn = Prelude.Nothing}
instance ToResourceProperties CmkSecretConfigProperty where
  toResourceProperties CmkSecretConfigProperty {..}
    = ResourceProperties
        {awsType = "AWS::DataSync::LocationObjectStorage.CmkSecretConfig",
         supportsTags = Prelude.False,
         properties = Prelude.fromList
                        (Prelude.catMaybes
                           [(JSON..=) "KmsKeyArn" Prelude.<$> kmsKeyArn,
                            (JSON..=) "SecretArn" Prelude.<$> secretArn])}
instance JSON.ToJSON CmkSecretConfigProperty where
  toJSON CmkSecretConfigProperty {..}
    = JSON.object
        (Prelude.fromList
           (Prelude.catMaybes
              [(JSON..=) "KmsKeyArn" Prelude.<$> kmsKeyArn,
               (JSON..=) "SecretArn" Prelude.<$> secretArn]))
instance Property "KmsKeyArn" CmkSecretConfigProperty where
  type PropertyType "KmsKeyArn" CmkSecretConfigProperty = Value Prelude.Text
  set newValue CmkSecretConfigProperty {..}
    = CmkSecretConfigProperty {kmsKeyArn = Prelude.pure newValue, ..}
instance Property "SecretArn" CmkSecretConfigProperty where
  type PropertyType "SecretArn" CmkSecretConfigProperty = Value Prelude.Text
  set newValue CmkSecretConfigProperty {..}
    = CmkSecretConfigProperty {secretArn = Prelude.pure newValue, ..}