module Stratosphere.IoT.TopicRule.StepFunctionsActionProperty (
        StepFunctionsActionProperty(..), mkStepFunctionsActionProperty
    ) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data StepFunctionsActionProperty
  = -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-iot-topicrule-stepfunctionsaction.html>
    StepFunctionsActionProperty {StepFunctionsActionProperty -> ()
haddock_workaround_ :: (),
                                 -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-iot-topicrule-stepfunctionsaction.html#cfn-iot-topicrule-stepfunctionsaction-executionnameprefix>
                                 StepFunctionsActionProperty -> Maybe (Value Text)
executionNamePrefix :: (Prelude.Maybe (Value Prelude.Text)),
                                 -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-iot-topicrule-stepfunctionsaction.html#cfn-iot-topicrule-stepfunctionsaction-rolearn>
                                 StepFunctionsActionProperty -> Value Text
roleArn :: (Value Prelude.Text),
                                 -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-iot-topicrule-stepfunctionsaction.html#cfn-iot-topicrule-stepfunctionsaction-statemachinename>
                                 StepFunctionsActionProperty -> Value Text
stateMachineName :: (Value Prelude.Text)}
  deriving stock (StepFunctionsActionProperty -> StepFunctionsActionProperty -> Bool
(StepFunctionsActionProperty
 -> StepFunctionsActionProperty -> Bool)
-> (StepFunctionsActionProperty
    -> StepFunctionsActionProperty -> Bool)
-> Eq StepFunctionsActionProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: StepFunctionsActionProperty -> StepFunctionsActionProperty -> Bool
== :: StepFunctionsActionProperty -> StepFunctionsActionProperty -> Bool
$c/= :: StepFunctionsActionProperty -> StepFunctionsActionProperty -> Bool
/= :: StepFunctionsActionProperty -> StepFunctionsActionProperty -> Bool
Prelude.Eq, Int -> StepFunctionsActionProperty -> ShowS
[StepFunctionsActionProperty] -> ShowS
StepFunctionsActionProperty -> String
(Int -> StepFunctionsActionProperty -> ShowS)
-> (StepFunctionsActionProperty -> String)
-> ([StepFunctionsActionProperty] -> ShowS)
-> Show StepFunctionsActionProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> StepFunctionsActionProperty -> ShowS
showsPrec :: Int -> StepFunctionsActionProperty -> ShowS
$cshow :: StepFunctionsActionProperty -> String
show :: StepFunctionsActionProperty -> String
$cshowList :: [StepFunctionsActionProperty] -> ShowS
showList :: [StepFunctionsActionProperty] -> ShowS
Prelude.Show)
mkStepFunctionsActionProperty ::
  Value Prelude.Text
  -> Value Prelude.Text -> StepFunctionsActionProperty
mkStepFunctionsActionProperty :: Value Text -> Value Text -> StepFunctionsActionProperty
mkStepFunctionsActionProperty Value Text
roleArn Value Text
stateMachineName
  = StepFunctionsActionProperty
      {haddock_workaround_ :: ()
haddock_workaround_ = (), roleArn :: Value Text
roleArn = Value Text
roleArn,
       stateMachineName :: Value Text
stateMachineName = Value Text
stateMachineName,
       executionNamePrefix :: Maybe (Value Text)
executionNamePrefix = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties StepFunctionsActionProperty where
  toResourceProperties :: StepFunctionsActionProperty -> ResourceProperties
toResourceProperties StepFunctionsActionProperty {Maybe (Value Text)
()
Value Text
haddock_workaround_ :: StepFunctionsActionProperty -> ()
executionNamePrefix :: StepFunctionsActionProperty -> Maybe (Value Text)
roleArn :: StepFunctionsActionProperty -> Value Text
stateMachineName :: StepFunctionsActionProperty -> Value Text
haddock_workaround_ :: ()
executionNamePrefix :: Maybe (Value Text)
roleArn :: Value Text
stateMachineName :: Value Text
..}
    = ResourceProperties
        {awsType :: Text
awsType = Text
"AWS::IoT::TopicRule.StepFunctionsAction",
         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
"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
"StateMachineName" 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
stateMachineName]
                           ([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
"ExecutionNamePrefix"
                                 (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)
executionNamePrefix]))}
instance JSON.ToJSON StepFunctionsActionProperty where
  toJSON :: StepFunctionsActionProperty -> Value
toJSON StepFunctionsActionProperty {Maybe (Value Text)
()
Value Text
haddock_workaround_ :: StepFunctionsActionProperty -> ()
executionNamePrefix :: StepFunctionsActionProperty -> Maybe (Value Text)
roleArn :: StepFunctionsActionProperty -> Value Text
stateMachineName :: StepFunctionsActionProperty -> Value Text
haddock_workaround_ :: ()
executionNamePrefix :: Maybe (Value Text)
roleArn :: Value Text
stateMachineName :: 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
"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
"StateMachineName" 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
stateMachineName]
              ([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
"ExecutionNamePrefix"
                    (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)
executionNamePrefix])))
instance Property "ExecutionNamePrefix" StepFunctionsActionProperty where
  type PropertyType "ExecutionNamePrefix" StepFunctionsActionProperty = Value Prelude.Text
  set :: PropertyType "ExecutionNamePrefix" StepFunctionsActionProperty
-> StepFunctionsActionProperty -> StepFunctionsActionProperty
set PropertyType "ExecutionNamePrefix" StepFunctionsActionProperty
newValue StepFunctionsActionProperty {Maybe (Value Text)
()
Value Text
haddock_workaround_ :: StepFunctionsActionProperty -> ()
executionNamePrefix :: StepFunctionsActionProperty -> Maybe (Value Text)
roleArn :: StepFunctionsActionProperty -> Value Text
stateMachineName :: StepFunctionsActionProperty -> Value Text
haddock_workaround_ :: ()
executionNamePrefix :: Maybe (Value Text)
roleArn :: Value Text
stateMachineName :: Value Text
..}
    = StepFunctionsActionProperty
        {executionNamePrefix :: Maybe (Value Text)
executionNamePrefix = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "ExecutionNamePrefix" StepFunctionsActionProperty
Value Text
newValue, ()
Value Text
haddock_workaround_ :: ()
roleArn :: Value Text
stateMachineName :: Value Text
haddock_workaround_ :: ()
roleArn :: Value Text
stateMachineName :: Value Text
..}
instance Property "RoleArn" StepFunctionsActionProperty where
  type PropertyType "RoleArn" StepFunctionsActionProperty = Value Prelude.Text
  set :: PropertyType "RoleArn" StepFunctionsActionProperty
-> StepFunctionsActionProperty -> StepFunctionsActionProperty
set PropertyType "RoleArn" StepFunctionsActionProperty
newValue StepFunctionsActionProperty {Maybe (Value Text)
()
Value Text
haddock_workaround_ :: StepFunctionsActionProperty -> ()
executionNamePrefix :: StepFunctionsActionProperty -> Maybe (Value Text)
roleArn :: StepFunctionsActionProperty -> Value Text
stateMachineName :: StepFunctionsActionProperty -> Value Text
haddock_workaround_ :: ()
executionNamePrefix :: Maybe (Value Text)
roleArn :: Value Text
stateMachineName :: Value Text
..}
    = StepFunctionsActionProperty {roleArn :: Value Text
roleArn = PropertyType "RoleArn" StepFunctionsActionProperty
Value Text
newValue, Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ()
executionNamePrefix :: Maybe (Value Text)
stateMachineName :: Value Text
haddock_workaround_ :: ()
executionNamePrefix :: Maybe (Value Text)
stateMachineName :: Value Text
..}
instance Property "StateMachineName" StepFunctionsActionProperty where
  type PropertyType "StateMachineName" StepFunctionsActionProperty = Value Prelude.Text
  set :: PropertyType "StateMachineName" StepFunctionsActionProperty
-> StepFunctionsActionProperty -> StepFunctionsActionProperty
set PropertyType "StateMachineName" StepFunctionsActionProperty
newValue StepFunctionsActionProperty {Maybe (Value Text)
()
Value Text
haddock_workaround_ :: StepFunctionsActionProperty -> ()
executionNamePrefix :: StepFunctionsActionProperty -> Maybe (Value Text)
roleArn :: StepFunctionsActionProperty -> Value Text
stateMachineName :: StepFunctionsActionProperty -> Value Text
haddock_workaround_ :: ()
executionNamePrefix :: Maybe (Value Text)
roleArn :: Value Text
stateMachineName :: Value Text
..}
    = StepFunctionsActionProperty {stateMachineName :: Value Text
stateMachineName = PropertyType "StateMachineName" StepFunctionsActionProperty
Value Text
newValue, Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ()
executionNamePrefix :: Maybe (Value Text)
roleArn :: Value Text
haddock_workaround_ :: ()
executionNamePrefix :: Maybe (Value Text)
roleArn :: Value Text
..}