module Stratosphere.SSM.ResourceDataSync.S3DestinationProperty (
        S3DestinationProperty(..), mkS3DestinationProperty
    ) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data S3DestinationProperty
  = -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ssm-resourcedatasync-s3destination.html>
    S3DestinationProperty {S3DestinationProperty -> ()
haddock_workaround_ :: (),
                           -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ssm-resourcedatasync-s3destination.html#cfn-ssm-resourcedatasync-s3destination-bucketname>
                           S3DestinationProperty -> Value Text
bucketName :: (Value Prelude.Text),
                           -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ssm-resourcedatasync-s3destination.html#cfn-ssm-resourcedatasync-s3destination-bucketprefix>
                           S3DestinationProperty -> Maybe (Value Text)
bucketPrefix :: (Prelude.Maybe (Value Prelude.Text)),
                           -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ssm-resourcedatasync-s3destination.html#cfn-ssm-resourcedatasync-s3destination-bucketregion>
                           S3DestinationProperty -> Value Text
bucketRegion :: (Value Prelude.Text),
                           -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ssm-resourcedatasync-s3destination.html#cfn-ssm-resourcedatasync-s3destination-kmskeyarn>
                           S3DestinationProperty -> Maybe (Value Text)
kMSKeyArn :: (Prelude.Maybe (Value Prelude.Text)),
                           -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ssm-resourcedatasync-s3destination.html#cfn-ssm-resourcedatasync-s3destination-syncformat>
                           S3DestinationProperty -> Value Text
syncFormat :: (Value Prelude.Text)}
  deriving stock (S3DestinationProperty -> S3DestinationProperty -> Bool
(S3DestinationProperty -> S3DestinationProperty -> Bool)
-> (S3DestinationProperty -> S3DestinationProperty -> Bool)
-> Eq S3DestinationProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: S3DestinationProperty -> S3DestinationProperty -> Bool
== :: S3DestinationProperty -> S3DestinationProperty -> Bool
$c/= :: S3DestinationProperty -> S3DestinationProperty -> Bool
/= :: S3DestinationProperty -> S3DestinationProperty -> Bool
Prelude.Eq, Int -> S3DestinationProperty -> ShowS
[S3DestinationProperty] -> ShowS
S3DestinationProperty -> String
(Int -> S3DestinationProperty -> ShowS)
-> (S3DestinationProperty -> String)
-> ([S3DestinationProperty] -> ShowS)
-> Show S3DestinationProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> S3DestinationProperty -> ShowS
showsPrec :: Int -> S3DestinationProperty -> ShowS
$cshow :: S3DestinationProperty -> String
show :: S3DestinationProperty -> String
$cshowList :: [S3DestinationProperty] -> ShowS
showList :: [S3DestinationProperty] -> ShowS
Prelude.Show)
mkS3DestinationProperty ::
  Value Prelude.Text
  -> Value Prelude.Text
     -> Value Prelude.Text -> S3DestinationProperty
mkS3DestinationProperty :: Value Text -> Value Text -> Value Text -> S3DestinationProperty
mkS3DestinationProperty Value Text
bucketName Value Text
bucketRegion Value Text
syncFormat
  = S3DestinationProperty
      {haddock_workaround_ :: ()
haddock_workaround_ = (), bucketName :: Value Text
bucketName = Value Text
bucketName,
       bucketRegion :: Value Text
bucketRegion = Value Text
bucketRegion, syncFormat :: Value Text
syncFormat = Value Text
syncFormat,
       bucketPrefix :: Maybe (Value Text)
bucketPrefix = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing, kMSKeyArn :: Maybe (Value Text)
kMSKeyArn = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties S3DestinationProperty where
  toResourceProperties :: S3DestinationProperty -> ResourceProperties
toResourceProperties S3DestinationProperty {Maybe (Value Text)
()
Value Text
haddock_workaround_ :: S3DestinationProperty -> ()
bucketName :: S3DestinationProperty -> Value Text
bucketPrefix :: S3DestinationProperty -> Maybe (Value Text)
bucketRegion :: S3DestinationProperty -> Value Text
kMSKeyArn :: S3DestinationProperty -> Maybe (Value Text)
syncFormat :: S3DestinationProperty -> Value Text
haddock_workaround_ :: ()
bucketName :: Value Text
bucketPrefix :: Maybe (Value Text)
bucketRegion :: Value Text
kMSKeyArn :: Maybe (Value Text)
syncFormat :: Value Text
..}
    = ResourceProperties
        {awsType :: Text
awsType = Text
"AWS::SSM::ResourceDataSync.S3Destination",
         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
"BucketName" 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..= Value Text
bucketName,
                            Key
"BucketRegion" 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..= Value Text
bucketRegion,
                            Key
"SyncFormat" 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..= Value Text
syncFormat]
                           ([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
"BucketPrefix" (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)
bucketPrefix,
                               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]))}
instance JSON.ToJSON S3DestinationProperty where
  toJSON :: S3DestinationProperty -> Value
toJSON S3DestinationProperty {Maybe (Value Text)
()
Value Text
haddock_workaround_ :: S3DestinationProperty -> ()
bucketName :: S3DestinationProperty -> Value Text
bucketPrefix :: S3DestinationProperty -> Maybe (Value Text)
bucketRegion :: S3DestinationProperty -> Value Text
kMSKeyArn :: S3DestinationProperty -> Maybe (Value Text)
syncFormat :: S3DestinationProperty -> Value Text
haddock_workaround_ :: ()
bucketName :: Value Text
bucketPrefix :: Maybe (Value Text)
bucketRegion :: Value Text
kMSKeyArn :: Maybe (Value Text)
syncFormat :: 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
"BucketName" 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..= Value Text
bucketName,
               Key
"BucketRegion" 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..= Value Text
bucketRegion,
               Key
"SyncFormat" 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..= Value Text
syncFormat]
              ([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
"BucketPrefix" (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)
bucketPrefix,
                  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])))
instance Property "BucketName" S3DestinationProperty where
  type PropertyType "BucketName" S3DestinationProperty = Value Prelude.Text
  set :: PropertyType "BucketName" S3DestinationProperty
-> S3DestinationProperty -> S3DestinationProperty
set PropertyType "BucketName" S3DestinationProperty
newValue S3DestinationProperty {Maybe (Value Text)
()
Value Text
haddock_workaround_ :: S3DestinationProperty -> ()
bucketName :: S3DestinationProperty -> Value Text
bucketPrefix :: S3DestinationProperty -> Maybe (Value Text)
bucketRegion :: S3DestinationProperty -> Value Text
kMSKeyArn :: S3DestinationProperty -> Maybe (Value Text)
syncFormat :: S3DestinationProperty -> Value Text
haddock_workaround_ :: ()
bucketName :: Value Text
bucketPrefix :: Maybe (Value Text)
bucketRegion :: Value Text
kMSKeyArn :: Maybe (Value Text)
syncFormat :: Value Text
..}
    = S3DestinationProperty {bucketName :: Value Text
bucketName = PropertyType "BucketName" S3DestinationProperty
Value Text
newValue, Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ()
bucketPrefix :: Maybe (Value Text)
bucketRegion :: Value Text
kMSKeyArn :: Maybe (Value Text)
syncFormat :: Value Text
haddock_workaround_ :: ()
bucketPrefix :: Maybe (Value Text)
bucketRegion :: Value Text
kMSKeyArn :: Maybe (Value Text)
syncFormat :: Value Text
..}
instance Property "BucketPrefix" S3DestinationProperty where
  type PropertyType "BucketPrefix" S3DestinationProperty = Value Prelude.Text
  set :: PropertyType "BucketPrefix" S3DestinationProperty
-> S3DestinationProperty -> S3DestinationProperty
set PropertyType "BucketPrefix" S3DestinationProperty
newValue S3DestinationProperty {Maybe (Value Text)
()
Value Text
haddock_workaround_ :: S3DestinationProperty -> ()
bucketName :: S3DestinationProperty -> Value Text
bucketPrefix :: S3DestinationProperty -> Maybe (Value Text)
bucketRegion :: S3DestinationProperty -> Value Text
kMSKeyArn :: S3DestinationProperty -> Maybe (Value Text)
syncFormat :: S3DestinationProperty -> Value Text
haddock_workaround_ :: ()
bucketName :: Value Text
bucketPrefix :: Maybe (Value Text)
bucketRegion :: Value Text
kMSKeyArn :: Maybe (Value Text)
syncFormat :: Value Text
..}
    = S3DestinationProperty {bucketPrefix :: Maybe (Value Text)
bucketPrefix = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "BucketPrefix" S3DestinationProperty
Value Text
newValue, Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ()
bucketName :: Value Text
bucketRegion :: Value Text
kMSKeyArn :: Maybe (Value Text)
syncFormat :: Value Text
haddock_workaround_ :: ()
bucketName :: Value Text
bucketRegion :: Value Text
kMSKeyArn :: Maybe (Value Text)
syncFormat :: Value Text
..}
instance Property "BucketRegion" S3DestinationProperty where
  type PropertyType "BucketRegion" S3DestinationProperty = Value Prelude.Text
  set :: PropertyType "BucketRegion" S3DestinationProperty
-> S3DestinationProperty -> S3DestinationProperty
set PropertyType "BucketRegion" S3DestinationProperty
newValue S3DestinationProperty {Maybe (Value Text)
()
Value Text
haddock_workaround_ :: S3DestinationProperty -> ()
bucketName :: S3DestinationProperty -> Value Text
bucketPrefix :: S3DestinationProperty -> Maybe (Value Text)
bucketRegion :: S3DestinationProperty -> Value Text
kMSKeyArn :: S3DestinationProperty -> Maybe (Value Text)
syncFormat :: S3DestinationProperty -> Value Text
haddock_workaround_ :: ()
bucketName :: Value Text
bucketPrefix :: Maybe (Value Text)
bucketRegion :: Value Text
kMSKeyArn :: Maybe (Value Text)
syncFormat :: Value Text
..}
    = S3DestinationProperty {bucketRegion :: Value Text
bucketRegion = PropertyType "BucketRegion" S3DestinationProperty
Value Text
newValue, Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ()
bucketName :: Value Text
bucketPrefix :: Maybe (Value Text)
kMSKeyArn :: Maybe (Value Text)
syncFormat :: Value Text
haddock_workaround_ :: ()
bucketName :: Value Text
bucketPrefix :: Maybe (Value Text)
kMSKeyArn :: Maybe (Value Text)
syncFormat :: Value Text
..}
instance Property "KMSKeyArn" S3DestinationProperty where
  type PropertyType "KMSKeyArn" S3DestinationProperty = Value Prelude.Text
  set :: PropertyType "KMSKeyArn" S3DestinationProperty
-> S3DestinationProperty -> S3DestinationProperty
set PropertyType "KMSKeyArn" S3DestinationProperty
newValue S3DestinationProperty {Maybe (Value Text)
()
Value Text
haddock_workaround_ :: S3DestinationProperty -> ()
bucketName :: S3DestinationProperty -> Value Text
bucketPrefix :: S3DestinationProperty -> Maybe (Value Text)
bucketRegion :: S3DestinationProperty -> Value Text
kMSKeyArn :: S3DestinationProperty -> Maybe (Value Text)
syncFormat :: S3DestinationProperty -> Value Text
haddock_workaround_ :: ()
bucketName :: Value Text
bucketPrefix :: Maybe (Value Text)
bucketRegion :: Value Text
kMSKeyArn :: Maybe (Value Text)
syncFormat :: Value Text
..}
    = S3DestinationProperty {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" S3DestinationProperty
Value Text
newValue, Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ()
bucketName :: Value Text
bucketPrefix :: Maybe (Value Text)
bucketRegion :: Value Text
syncFormat :: Value Text
haddock_workaround_ :: ()
bucketName :: Value Text
bucketPrefix :: Maybe (Value Text)
bucketRegion :: Value Text
syncFormat :: Value Text
..}
instance Property "SyncFormat" S3DestinationProperty where
  type PropertyType "SyncFormat" S3DestinationProperty = Value Prelude.Text
  set :: PropertyType "SyncFormat" S3DestinationProperty
-> S3DestinationProperty -> S3DestinationProperty
set PropertyType "SyncFormat" S3DestinationProperty
newValue S3DestinationProperty {Maybe (Value Text)
()
Value Text
haddock_workaround_ :: S3DestinationProperty -> ()
bucketName :: S3DestinationProperty -> Value Text
bucketPrefix :: S3DestinationProperty -> Maybe (Value Text)
bucketRegion :: S3DestinationProperty -> Value Text
kMSKeyArn :: S3DestinationProperty -> Maybe (Value Text)
syncFormat :: S3DestinationProperty -> Value Text
haddock_workaround_ :: ()
bucketName :: Value Text
bucketPrefix :: Maybe (Value Text)
bucketRegion :: Value Text
kMSKeyArn :: Maybe (Value Text)
syncFormat :: Value Text
..}
    = S3DestinationProperty {syncFormat :: Value Text
syncFormat = PropertyType "SyncFormat" S3DestinationProperty
Value Text
newValue, Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ()
bucketName :: Value Text
bucketPrefix :: Maybe (Value Text)
bucketRegion :: Value Text
kMSKeyArn :: Maybe (Value Text)
haddock_workaround_ :: ()
bucketName :: Value Text
bucketPrefix :: Maybe (Value Text)
bucketRegion :: Value Text
kMSKeyArn :: Maybe (Value Text)
..}