module Stratosphere.IoT.TopicRule.TimestreamActionProperty (
module Exports, TimestreamActionProperty(..),
mkTimestreamActionProperty
) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import {-# SOURCE #-} Stratosphere.IoT.TopicRule.TimestreamDimensionProperty as Exports
import {-# SOURCE #-} Stratosphere.IoT.TopicRule.TimestreamTimestampProperty as Exports
import Stratosphere.ResourceProperties
import Stratosphere.Value
data TimestreamActionProperty
=
TimestreamActionProperty {TimestreamActionProperty -> ()
haddock_workaround_ :: (),
TimestreamActionProperty -> Value Text
databaseName :: (Value Prelude.Text),
TimestreamActionProperty -> [TimestreamDimensionProperty]
dimensions :: [TimestreamDimensionProperty],
TimestreamActionProperty -> Value Text
roleArn :: (Value Prelude.Text),
TimestreamActionProperty -> Value Text
tableName :: (Value Prelude.Text),
TimestreamActionProperty -> Maybe TimestreamTimestampProperty
timestamp :: (Prelude.Maybe TimestreamTimestampProperty)}
deriving stock (TimestreamActionProperty -> TimestreamActionProperty -> Bool
(TimestreamActionProperty -> TimestreamActionProperty -> Bool)
-> (TimestreamActionProperty -> TimestreamActionProperty -> Bool)
-> Eq TimestreamActionProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: TimestreamActionProperty -> TimestreamActionProperty -> Bool
== :: TimestreamActionProperty -> TimestreamActionProperty -> Bool
$c/= :: TimestreamActionProperty -> TimestreamActionProperty -> Bool
/= :: TimestreamActionProperty -> TimestreamActionProperty -> Bool
Prelude.Eq, Int -> TimestreamActionProperty -> ShowS
[TimestreamActionProperty] -> ShowS
TimestreamActionProperty -> String
(Int -> TimestreamActionProperty -> ShowS)
-> (TimestreamActionProperty -> String)
-> ([TimestreamActionProperty] -> ShowS)
-> Show TimestreamActionProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> TimestreamActionProperty -> ShowS
showsPrec :: Int -> TimestreamActionProperty -> ShowS
$cshow :: TimestreamActionProperty -> String
show :: TimestreamActionProperty -> String
$cshowList :: [TimestreamActionProperty] -> ShowS
showList :: [TimestreamActionProperty] -> ShowS
Prelude.Show)
mkTimestreamActionProperty ::
Value Prelude.Text
-> [TimestreamDimensionProperty]
-> Value Prelude.Text
-> Value Prelude.Text -> TimestreamActionProperty
mkTimestreamActionProperty :: Value Text
-> [TimestreamDimensionProperty]
-> Value Text
-> Value Text
-> TimestreamActionProperty
mkTimestreamActionProperty
Value Text
databaseName
[TimestreamDimensionProperty]
dimensions
Value Text
roleArn
Value Text
tableName
= TimestreamActionProperty
{haddock_workaround_ :: ()
haddock_workaround_ = (), databaseName :: Value Text
databaseName = Value Text
databaseName,
dimensions :: [TimestreamDimensionProperty]
dimensions = [TimestreamDimensionProperty]
dimensions, roleArn :: Value Text
roleArn = Value Text
roleArn, tableName :: Value Text
tableName = Value Text
tableName,
timestamp :: Maybe TimestreamTimestampProperty
timestamp = Maybe TimestreamTimestampProperty
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties TimestreamActionProperty where
toResourceProperties :: TimestreamActionProperty -> ResourceProperties
toResourceProperties TimestreamActionProperty {[TimestreamDimensionProperty]
Maybe TimestreamTimestampProperty
()
Value Text
haddock_workaround_ :: TimestreamActionProperty -> ()
databaseName :: TimestreamActionProperty -> Value Text
dimensions :: TimestreamActionProperty -> [TimestreamDimensionProperty]
roleArn :: TimestreamActionProperty -> Value Text
tableName :: TimestreamActionProperty -> Value Text
timestamp :: TimestreamActionProperty -> Maybe TimestreamTimestampProperty
haddock_workaround_ :: ()
databaseName :: Value Text
dimensions :: [TimestreamDimensionProperty]
roleArn :: Value Text
tableName :: Value Text
timestamp :: Maybe TimestreamTimestampProperty
..}
= ResourceProperties
{awsType :: Text
awsType = Text
"AWS::IoT::TopicRule.TimestreamAction",
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
"DatabaseName" 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
databaseName,
Key
"Dimensions" Key -> [TimestreamDimensionProperty] -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= [TimestreamDimensionProperty]
dimensions, Key
"RoleArn" 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
roleArn,
Key
"TableName" 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
tableName]
([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes [Key -> TimestreamTimestampProperty -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"Timestamp" (TimestreamTimestampProperty -> (Key, Value))
-> Maybe TimestreamTimestampProperty -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe TimestreamTimestampProperty
timestamp]))}
instance JSON.ToJSON TimestreamActionProperty where
toJSON :: TimestreamActionProperty -> Value
toJSON TimestreamActionProperty {[TimestreamDimensionProperty]
Maybe TimestreamTimestampProperty
()
Value Text
haddock_workaround_ :: TimestreamActionProperty -> ()
databaseName :: TimestreamActionProperty -> Value Text
dimensions :: TimestreamActionProperty -> [TimestreamDimensionProperty]
roleArn :: TimestreamActionProperty -> Value Text
tableName :: TimestreamActionProperty -> Value Text
timestamp :: TimestreamActionProperty -> Maybe TimestreamTimestampProperty
haddock_workaround_ :: ()
databaseName :: Value Text
dimensions :: [TimestreamDimensionProperty]
roleArn :: Value Text
tableName :: Value Text
timestamp :: Maybe TimestreamTimestampProperty
..}
= [(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
"DatabaseName" 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
databaseName,
Key
"Dimensions" Key -> [TimestreamDimensionProperty] -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= [TimestreamDimensionProperty]
dimensions, Key
"RoleArn" 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
roleArn,
Key
"TableName" 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
tableName]
([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes [Key -> TimestreamTimestampProperty -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"Timestamp" (TimestreamTimestampProperty -> (Key, Value))
-> Maybe TimestreamTimestampProperty -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe TimestreamTimestampProperty
timestamp])))
instance Property "DatabaseName" TimestreamActionProperty where
type PropertyType "DatabaseName" TimestreamActionProperty = Value Prelude.Text
set :: PropertyType "DatabaseName" TimestreamActionProperty
-> TimestreamActionProperty -> TimestreamActionProperty
set PropertyType "DatabaseName" TimestreamActionProperty
newValue TimestreamActionProperty {[TimestreamDimensionProperty]
Maybe TimestreamTimestampProperty
()
Value Text
haddock_workaround_ :: TimestreamActionProperty -> ()
databaseName :: TimestreamActionProperty -> Value Text
dimensions :: TimestreamActionProperty -> [TimestreamDimensionProperty]
roleArn :: TimestreamActionProperty -> Value Text
tableName :: TimestreamActionProperty -> Value Text
timestamp :: TimestreamActionProperty -> Maybe TimestreamTimestampProperty
haddock_workaround_ :: ()
databaseName :: Value Text
dimensions :: [TimestreamDimensionProperty]
roleArn :: Value Text
tableName :: Value Text
timestamp :: Maybe TimestreamTimestampProperty
..}
= TimestreamActionProperty {databaseName :: Value Text
databaseName = PropertyType "DatabaseName" TimestreamActionProperty
Value Text
newValue, [TimestreamDimensionProperty]
Maybe TimestreamTimestampProperty
()
Value Text
haddock_workaround_ :: ()
dimensions :: [TimestreamDimensionProperty]
roleArn :: Value Text
tableName :: Value Text
timestamp :: Maybe TimestreamTimestampProperty
haddock_workaround_ :: ()
dimensions :: [TimestreamDimensionProperty]
roleArn :: Value Text
tableName :: Value Text
timestamp :: Maybe TimestreamTimestampProperty
..}
instance Property "Dimensions" TimestreamActionProperty where
type PropertyType "Dimensions" TimestreamActionProperty = [TimestreamDimensionProperty]
set :: PropertyType "Dimensions" TimestreamActionProperty
-> TimestreamActionProperty -> TimestreamActionProperty
set PropertyType "Dimensions" TimestreamActionProperty
newValue TimestreamActionProperty {[TimestreamDimensionProperty]
Maybe TimestreamTimestampProperty
()
Value Text
haddock_workaround_ :: TimestreamActionProperty -> ()
databaseName :: TimestreamActionProperty -> Value Text
dimensions :: TimestreamActionProperty -> [TimestreamDimensionProperty]
roleArn :: TimestreamActionProperty -> Value Text
tableName :: TimestreamActionProperty -> Value Text
timestamp :: TimestreamActionProperty -> Maybe TimestreamTimestampProperty
haddock_workaround_ :: ()
databaseName :: Value Text
dimensions :: [TimestreamDimensionProperty]
roleArn :: Value Text
tableName :: Value Text
timestamp :: Maybe TimestreamTimestampProperty
..}
= TimestreamActionProperty {dimensions :: [TimestreamDimensionProperty]
dimensions = [TimestreamDimensionProperty]
PropertyType "Dimensions" TimestreamActionProperty
newValue, Maybe TimestreamTimestampProperty
()
Value Text
haddock_workaround_ :: ()
databaseName :: Value Text
roleArn :: Value Text
tableName :: Value Text
timestamp :: Maybe TimestreamTimestampProperty
haddock_workaround_ :: ()
databaseName :: Value Text
roleArn :: Value Text
tableName :: Value Text
timestamp :: Maybe TimestreamTimestampProperty
..}
instance Property "RoleArn" TimestreamActionProperty where
type PropertyType "RoleArn" TimestreamActionProperty = Value Prelude.Text
set :: PropertyType "RoleArn" TimestreamActionProperty
-> TimestreamActionProperty -> TimestreamActionProperty
set PropertyType "RoleArn" TimestreamActionProperty
newValue TimestreamActionProperty {[TimestreamDimensionProperty]
Maybe TimestreamTimestampProperty
()
Value Text
haddock_workaround_ :: TimestreamActionProperty -> ()
databaseName :: TimestreamActionProperty -> Value Text
dimensions :: TimestreamActionProperty -> [TimestreamDimensionProperty]
roleArn :: TimestreamActionProperty -> Value Text
tableName :: TimestreamActionProperty -> Value Text
timestamp :: TimestreamActionProperty -> Maybe TimestreamTimestampProperty
haddock_workaround_ :: ()
databaseName :: Value Text
dimensions :: [TimestreamDimensionProperty]
roleArn :: Value Text
tableName :: Value Text
timestamp :: Maybe TimestreamTimestampProperty
..}
= TimestreamActionProperty {roleArn :: Value Text
roleArn = PropertyType "RoleArn" TimestreamActionProperty
Value Text
newValue, [TimestreamDimensionProperty]
Maybe TimestreamTimestampProperty
()
Value Text
haddock_workaround_ :: ()
databaseName :: Value Text
dimensions :: [TimestreamDimensionProperty]
tableName :: Value Text
timestamp :: Maybe TimestreamTimestampProperty
haddock_workaround_ :: ()
databaseName :: Value Text
dimensions :: [TimestreamDimensionProperty]
tableName :: Value Text
timestamp :: Maybe TimestreamTimestampProperty
..}
instance Property "TableName" TimestreamActionProperty where
type PropertyType "TableName" TimestreamActionProperty = Value Prelude.Text
set :: PropertyType "TableName" TimestreamActionProperty
-> TimestreamActionProperty -> TimestreamActionProperty
set PropertyType "TableName" TimestreamActionProperty
newValue TimestreamActionProperty {[TimestreamDimensionProperty]
Maybe TimestreamTimestampProperty
()
Value Text
haddock_workaround_ :: TimestreamActionProperty -> ()
databaseName :: TimestreamActionProperty -> Value Text
dimensions :: TimestreamActionProperty -> [TimestreamDimensionProperty]
roleArn :: TimestreamActionProperty -> Value Text
tableName :: TimestreamActionProperty -> Value Text
timestamp :: TimestreamActionProperty -> Maybe TimestreamTimestampProperty
haddock_workaround_ :: ()
databaseName :: Value Text
dimensions :: [TimestreamDimensionProperty]
roleArn :: Value Text
tableName :: Value Text
timestamp :: Maybe TimestreamTimestampProperty
..}
= TimestreamActionProperty {tableName :: Value Text
tableName = PropertyType "TableName" TimestreamActionProperty
Value Text
newValue, [TimestreamDimensionProperty]
Maybe TimestreamTimestampProperty
()
Value Text
haddock_workaround_ :: ()
databaseName :: Value Text
dimensions :: [TimestreamDimensionProperty]
roleArn :: Value Text
timestamp :: Maybe TimestreamTimestampProperty
haddock_workaround_ :: ()
databaseName :: Value Text
dimensions :: [TimestreamDimensionProperty]
roleArn :: Value Text
timestamp :: Maybe TimestreamTimestampProperty
..}
instance Property "Timestamp" TimestreamActionProperty where
type PropertyType "Timestamp" TimestreamActionProperty = TimestreamTimestampProperty
set :: PropertyType "Timestamp" TimestreamActionProperty
-> TimestreamActionProperty -> TimestreamActionProperty
set PropertyType "Timestamp" TimestreamActionProperty
newValue TimestreamActionProperty {[TimestreamDimensionProperty]
Maybe TimestreamTimestampProperty
()
Value Text
haddock_workaround_ :: TimestreamActionProperty -> ()
databaseName :: TimestreamActionProperty -> Value Text
dimensions :: TimestreamActionProperty -> [TimestreamDimensionProperty]
roleArn :: TimestreamActionProperty -> Value Text
tableName :: TimestreamActionProperty -> Value Text
timestamp :: TimestreamActionProperty -> Maybe TimestreamTimestampProperty
haddock_workaround_ :: ()
databaseName :: Value Text
dimensions :: [TimestreamDimensionProperty]
roleArn :: Value Text
tableName :: Value Text
timestamp :: Maybe TimestreamTimestampProperty
..}
= TimestreamActionProperty {timestamp :: Maybe TimestreamTimestampProperty
timestamp = TimestreamTimestampProperty -> Maybe TimestreamTimestampProperty
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "Timestamp" TimestreamActionProperty
TimestreamTimestampProperty
newValue, [TimestreamDimensionProperty]
()
Value Text
haddock_workaround_ :: ()
databaseName :: Value Text
dimensions :: [TimestreamDimensionProperty]
roleArn :: Value Text
tableName :: Value Text
haddock_workaround_ :: ()
databaseName :: Value Text
dimensions :: [TimestreamDimensionProperty]
roleArn :: Value Text
tableName :: Value Text
..}