{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}
module Amazonka.SWF.Types.StartTimerFailedEventAttributes where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
import Amazonka.SWF.Types.StartTimerFailedCause
data StartTimerFailedEventAttributes = StartTimerFailedEventAttributes'
{
StartTimerFailedEventAttributes -> Text
timerId :: Prelude.Text,
StartTimerFailedEventAttributes -> StartTimerFailedCause
cause :: StartTimerFailedCause,
StartTimerFailedEventAttributes -> Integer
decisionTaskCompletedEventId :: Prelude.Integer
}
deriving (StartTimerFailedEventAttributes
-> StartTimerFailedEventAttributes -> Bool
(StartTimerFailedEventAttributes
-> StartTimerFailedEventAttributes -> Bool)
-> (StartTimerFailedEventAttributes
-> StartTimerFailedEventAttributes -> Bool)
-> Eq StartTimerFailedEventAttributes
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: StartTimerFailedEventAttributes
-> StartTimerFailedEventAttributes -> Bool
$c/= :: StartTimerFailedEventAttributes
-> StartTimerFailedEventAttributes -> Bool
== :: StartTimerFailedEventAttributes
-> StartTimerFailedEventAttributes -> Bool
$c== :: StartTimerFailedEventAttributes
-> StartTimerFailedEventAttributes -> Bool
Prelude.Eq, ReadPrec [StartTimerFailedEventAttributes]
ReadPrec StartTimerFailedEventAttributes
Int -> ReadS StartTimerFailedEventAttributes
ReadS [StartTimerFailedEventAttributes]
(Int -> ReadS StartTimerFailedEventAttributes)
-> ReadS [StartTimerFailedEventAttributes]
-> ReadPrec StartTimerFailedEventAttributes
-> ReadPrec [StartTimerFailedEventAttributes]
-> Read StartTimerFailedEventAttributes
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [StartTimerFailedEventAttributes]
$creadListPrec :: ReadPrec [StartTimerFailedEventAttributes]
readPrec :: ReadPrec StartTimerFailedEventAttributes
$creadPrec :: ReadPrec StartTimerFailedEventAttributes
readList :: ReadS [StartTimerFailedEventAttributes]
$creadList :: ReadS [StartTimerFailedEventAttributes]
readsPrec :: Int -> ReadS StartTimerFailedEventAttributes
$creadsPrec :: Int -> ReadS StartTimerFailedEventAttributes
Prelude.Read, Int -> StartTimerFailedEventAttributes -> ShowS
[StartTimerFailedEventAttributes] -> ShowS
StartTimerFailedEventAttributes -> String
(Int -> StartTimerFailedEventAttributes -> ShowS)
-> (StartTimerFailedEventAttributes -> String)
-> ([StartTimerFailedEventAttributes] -> ShowS)
-> Show StartTimerFailedEventAttributes
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [StartTimerFailedEventAttributes] -> ShowS
$cshowList :: [StartTimerFailedEventAttributes] -> ShowS
show :: StartTimerFailedEventAttributes -> String
$cshow :: StartTimerFailedEventAttributes -> String
showsPrec :: Int -> StartTimerFailedEventAttributes -> ShowS
$cshowsPrec :: Int -> StartTimerFailedEventAttributes -> ShowS
Prelude.Show, (forall x.
StartTimerFailedEventAttributes
-> Rep StartTimerFailedEventAttributes x)
-> (forall x.
Rep StartTimerFailedEventAttributes x
-> StartTimerFailedEventAttributes)
-> Generic StartTimerFailedEventAttributes
forall x.
Rep StartTimerFailedEventAttributes x
-> StartTimerFailedEventAttributes
forall x.
StartTimerFailedEventAttributes
-> Rep StartTimerFailedEventAttributes x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep StartTimerFailedEventAttributes x
-> StartTimerFailedEventAttributes
$cfrom :: forall x.
StartTimerFailedEventAttributes
-> Rep StartTimerFailedEventAttributes x
Prelude.Generic)
newStartTimerFailedEventAttributes ::
Prelude.Text ->
StartTimerFailedCause ->
Prelude.Integer ->
StartTimerFailedEventAttributes
newStartTimerFailedEventAttributes :: Text
-> StartTimerFailedCause
-> Integer
-> StartTimerFailedEventAttributes
newStartTimerFailedEventAttributes
Text
pTimerId_
StartTimerFailedCause
pCause_
Integer
pDecisionTaskCompletedEventId_ =
StartTimerFailedEventAttributes' :: Text
-> StartTimerFailedCause
-> Integer
-> StartTimerFailedEventAttributes
StartTimerFailedEventAttributes'
{ $sel:timerId:StartTimerFailedEventAttributes' :: Text
timerId =
Text
pTimerId_,
$sel:cause:StartTimerFailedEventAttributes' :: StartTimerFailedCause
cause = StartTimerFailedCause
pCause_,
$sel:decisionTaskCompletedEventId:StartTimerFailedEventAttributes' :: Integer
decisionTaskCompletedEventId =
Integer
pDecisionTaskCompletedEventId_
}
startTimerFailedEventAttributes_timerId :: Lens.Lens' StartTimerFailedEventAttributes Prelude.Text
startTimerFailedEventAttributes_timerId :: (Text -> f Text)
-> StartTimerFailedEventAttributes
-> f StartTimerFailedEventAttributes
startTimerFailedEventAttributes_timerId = (StartTimerFailedEventAttributes -> Text)
-> (StartTimerFailedEventAttributes
-> Text -> StartTimerFailedEventAttributes)
-> Lens
StartTimerFailedEventAttributes
StartTimerFailedEventAttributes
Text
Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\StartTimerFailedEventAttributes' {Text
timerId :: Text
$sel:timerId:StartTimerFailedEventAttributes' :: StartTimerFailedEventAttributes -> Text
timerId} -> Text
timerId) (\s :: StartTimerFailedEventAttributes
s@StartTimerFailedEventAttributes' {} Text
a -> StartTimerFailedEventAttributes
s {$sel:timerId:StartTimerFailedEventAttributes' :: Text
timerId = Text
a} :: StartTimerFailedEventAttributes)
startTimerFailedEventAttributes_cause :: Lens.Lens' StartTimerFailedEventAttributes StartTimerFailedCause
startTimerFailedEventAttributes_cause :: (StartTimerFailedCause -> f StartTimerFailedCause)
-> StartTimerFailedEventAttributes
-> f StartTimerFailedEventAttributes
startTimerFailedEventAttributes_cause = (StartTimerFailedEventAttributes -> StartTimerFailedCause)
-> (StartTimerFailedEventAttributes
-> StartTimerFailedCause -> StartTimerFailedEventAttributes)
-> Lens
StartTimerFailedEventAttributes
StartTimerFailedEventAttributes
StartTimerFailedCause
StartTimerFailedCause
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\StartTimerFailedEventAttributes' {StartTimerFailedCause
cause :: StartTimerFailedCause
$sel:cause:StartTimerFailedEventAttributes' :: StartTimerFailedEventAttributes -> StartTimerFailedCause
cause} -> StartTimerFailedCause
cause) (\s :: StartTimerFailedEventAttributes
s@StartTimerFailedEventAttributes' {} StartTimerFailedCause
a -> StartTimerFailedEventAttributes
s {$sel:cause:StartTimerFailedEventAttributes' :: StartTimerFailedCause
cause = StartTimerFailedCause
a} :: StartTimerFailedEventAttributes)
startTimerFailedEventAttributes_decisionTaskCompletedEventId :: Lens.Lens' StartTimerFailedEventAttributes Prelude.Integer
startTimerFailedEventAttributes_decisionTaskCompletedEventId :: (Integer -> f Integer)
-> StartTimerFailedEventAttributes
-> f StartTimerFailedEventAttributes
startTimerFailedEventAttributes_decisionTaskCompletedEventId = (StartTimerFailedEventAttributes -> Integer)
-> (StartTimerFailedEventAttributes
-> Integer -> StartTimerFailedEventAttributes)
-> Lens
StartTimerFailedEventAttributes
StartTimerFailedEventAttributes
Integer
Integer
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\StartTimerFailedEventAttributes' {Integer
decisionTaskCompletedEventId :: Integer
$sel:decisionTaskCompletedEventId:StartTimerFailedEventAttributes' :: StartTimerFailedEventAttributes -> Integer
decisionTaskCompletedEventId} -> Integer
decisionTaskCompletedEventId) (\s :: StartTimerFailedEventAttributes
s@StartTimerFailedEventAttributes' {} Integer
a -> StartTimerFailedEventAttributes
s {$sel:decisionTaskCompletedEventId:StartTimerFailedEventAttributes' :: Integer
decisionTaskCompletedEventId = Integer
a} :: StartTimerFailedEventAttributes)
instance
Core.FromJSON
StartTimerFailedEventAttributes
where
parseJSON :: Value -> Parser StartTimerFailedEventAttributes
parseJSON =
String
-> (Object -> Parser StartTimerFailedEventAttributes)
-> Value
-> Parser StartTimerFailedEventAttributes
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
String
"StartTimerFailedEventAttributes"
( \Object
x ->
Text
-> StartTimerFailedCause
-> Integer
-> StartTimerFailedEventAttributes
StartTimerFailedEventAttributes'
(Text
-> StartTimerFailedCause
-> Integer
-> StartTimerFailedEventAttributes)
-> Parser Text
-> Parser
(StartTimerFailedCause
-> Integer -> StartTimerFailedEventAttributes)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Parser Text
forall a. FromJSON a => Object -> Text -> Parser a
Core..: Text
"timerId")
Parser
(StartTimerFailedCause
-> Integer -> StartTimerFailedEventAttributes)
-> Parser StartTimerFailedCause
-> Parser (Integer -> StartTimerFailedEventAttributes)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser StartTimerFailedCause
forall a. FromJSON a => Object -> Text -> Parser a
Core..: Text
"cause")
Parser (Integer -> StartTimerFailedEventAttributes)
-> Parser Integer -> Parser StartTimerFailedEventAttributes
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser Integer
forall a. FromJSON a => Object -> Text -> Parser a
Core..: Text
"decisionTaskCompletedEventId")
)
instance
Prelude.Hashable
StartTimerFailedEventAttributes
instance
Prelude.NFData
StartTimerFailedEventAttributes