module Stratosphere.Rekognition.StreamProcessor.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
=
S3DestinationProperty {S3DestinationProperty -> ()
haddock_workaround_ :: (),
S3DestinationProperty -> Value Text
bucketName :: (Value Prelude.Text),
S3DestinationProperty -> Maybe (Value Text)
objectKeyPrefix :: (Prelude.Maybe (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 -> S3DestinationProperty
mkS3DestinationProperty :: Value Text -> S3DestinationProperty
mkS3DestinationProperty Value Text
bucketName
= S3DestinationProperty
{haddock_workaround_ :: ()
haddock_workaround_ = (), bucketName :: Value Text
bucketName = Value Text
bucketName,
objectKeyPrefix :: Maybe (Value Text)
objectKeyPrefix = 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
objectKeyPrefix :: S3DestinationProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
bucketName :: Value Text
objectKeyPrefix :: Maybe (Value Text)
..}
= ResourceProperties
{awsType :: Text
awsType = Text
"AWS::Rekognition::StreamProcessor.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]
([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
"ObjectKeyPrefix" (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)
objectKeyPrefix]))}
instance JSON.ToJSON S3DestinationProperty where
toJSON :: S3DestinationProperty -> Value
toJSON S3DestinationProperty {Maybe (Value Text)
()
Value Text
haddock_workaround_ :: S3DestinationProperty -> ()
bucketName :: S3DestinationProperty -> Value Text
objectKeyPrefix :: S3DestinationProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
bucketName :: Value Text
objectKeyPrefix :: 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
"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]
([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
"ObjectKeyPrefix" (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)
objectKeyPrefix])))
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
objectKeyPrefix :: S3DestinationProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
bucketName :: Value Text
objectKeyPrefix :: Maybe (Value Text)
..}
= S3DestinationProperty {bucketName :: Value Text
bucketName = PropertyType "BucketName" S3DestinationProperty
Value Text
newValue, Maybe (Value Text)
()
haddock_workaround_ :: ()
objectKeyPrefix :: Maybe (Value Text)
haddock_workaround_ :: ()
objectKeyPrefix :: Maybe (Value Text)
..}
instance Property "ObjectKeyPrefix" S3DestinationProperty where
type PropertyType "ObjectKeyPrefix" S3DestinationProperty = Value Prelude.Text
set :: PropertyType "ObjectKeyPrefix" S3DestinationProperty
-> S3DestinationProperty -> S3DestinationProperty
set PropertyType "ObjectKeyPrefix" S3DestinationProperty
newValue S3DestinationProperty {Maybe (Value Text)
()
Value Text
haddock_workaround_ :: S3DestinationProperty -> ()
bucketName :: S3DestinationProperty -> Value Text
objectKeyPrefix :: S3DestinationProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
bucketName :: Value Text
objectKeyPrefix :: Maybe (Value Text)
..}
= S3DestinationProperty
{objectKeyPrefix :: Maybe (Value Text)
objectKeyPrefix = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "ObjectKeyPrefix" S3DestinationProperty
Value Text
newValue, ()
Value Text
haddock_workaround_ :: ()
bucketName :: Value Text
haddock_workaround_ :: ()
bucketName :: Value Text
..}