{-# 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.DecisionTaskTimedOutEventAttributes where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
import Amazonka.SWF.Types.DecisionTaskTimeoutType
data DecisionTaskTimedOutEventAttributes = DecisionTaskTimedOutEventAttributes'
{
DecisionTaskTimedOutEventAttributes -> DecisionTaskTimeoutType
timeoutType :: DecisionTaskTimeoutType,
DecisionTaskTimedOutEventAttributes -> Integer
scheduledEventId :: Prelude.Integer,
DecisionTaskTimedOutEventAttributes -> Integer
startedEventId :: Prelude.Integer
}
deriving (DecisionTaskTimedOutEventAttributes
-> DecisionTaskTimedOutEventAttributes -> Bool
(DecisionTaskTimedOutEventAttributes
-> DecisionTaskTimedOutEventAttributes -> Bool)
-> (DecisionTaskTimedOutEventAttributes
-> DecisionTaskTimedOutEventAttributes -> Bool)
-> Eq DecisionTaskTimedOutEventAttributes
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DecisionTaskTimedOutEventAttributes
-> DecisionTaskTimedOutEventAttributes -> Bool
$c/= :: DecisionTaskTimedOutEventAttributes
-> DecisionTaskTimedOutEventAttributes -> Bool
== :: DecisionTaskTimedOutEventAttributes
-> DecisionTaskTimedOutEventAttributes -> Bool
$c== :: DecisionTaskTimedOutEventAttributes
-> DecisionTaskTimedOutEventAttributes -> Bool
Prelude.Eq, ReadPrec [DecisionTaskTimedOutEventAttributes]
ReadPrec DecisionTaskTimedOutEventAttributes
Int -> ReadS DecisionTaskTimedOutEventAttributes
ReadS [DecisionTaskTimedOutEventAttributes]
(Int -> ReadS DecisionTaskTimedOutEventAttributes)
-> ReadS [DecisionTaskTimedOutEventAttributes]
-> ReadPrec DecisionTaskTimedOutEventAttributes
-> ReadPrec [DecisionTaskTimedOutEventAttributes]
-> Read DecisionTaskTimedOutEventAttributes
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DecisionTaskTimedOutEventAttributes]
$creadListPrec :: ReadPrec [DecisionTaskTimedOutEventAttributes]
readPrec :: ReadPrec DecisionTaskTimedOutEventAttributes
$creadPrec :: ReadPrec DecisionTaskTimedOutEventAttributes
readList :: ReadS [DecisionTaskTimedOutEventAttributes]
$creadList :: ReadS [DecisionTaskTimedOutEventAttributes]
readsPrec :: Int -> ReadS DecisionTaskTimedOutEventAttributes
$creadsPrec :: Int -> ReadS DecisionTaskTimedOutEventAttributes
Prelude.Read, Int -> DecisionTaskTimedOutEventAttributes -> ShowS
[DecisionTaskTimedOutEventAttributes] -> ShowS
DecisionTaskTimedOutEventAttributes -> String
(Int -> DecisionTaskTimedOutEventAttributes -> ShowS)
-> (DecisionTaskTimedOutEventAttributes -> String)
-> ([DecisionTaskTimedOutEventAttributes] -> ShowS)
-> Show DecisionTaskTimedOutEventAttributes
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DecisionTaskTimedOutEventAttributes] -> ShowS
$cshowList :: [DecisionTaskTimedOutEventAttributes] -> ShowS
show :: DecisionTaskTimedOutEventAttributes -> String
$cshow :: DecisionTaskTimedOutEventAttributes -> String
showsPrec :: Int -> DecisionTaskTimedOutEventAttributes -> ShowS
$cshowsPrec :: Int -> DecisionTaskTimedOutEventAttributes -> ShowS
Prelude.Show, (forall x.
DecisionTaskTimedOutEventAttributes
-> Rep DecisionTaskTimedOutEventAttributes x)
-> (forall x.
Rep DecisionTaskTimedOutEventAttributes x
-> DecisionTaskTimedOutEventAttributes)
-> Generic DecisionTaskTimedOutEventAttributes
forall x.
Rep DecisionTaskTimedOutEventAttributes x
-> DecisionTaskTimedOutEventAttributes
forall x.
DecisionTaskTimedOutEventAttributes
-> Rep DecisionTaskTimedOutEventAttributes x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep DecisionTaskTimedOutEventAttributes x
-> DecisionTaskTimedOutEventAttributes
$cfrom :: forall x.
DecisionTaskTimedOutEventAttributes
-> Rep DecisionTaskTimedOutEventAttributes x
Prelude.Generic)
newDecisionTaskTimedOutEventAttributes ::
DecisionTaskTimeoutType ->
Prelude.Integer ->
Prelude.Integer ->
DecisionTaskTimedOutEventAttributes
newDecisionTaskTimedOutEventAttributes :: DecisionTaskTimeoutType
-> Integer -> Integer -> DecisionTaskTimedOutEventAttributes
newDecisionTaskTimedOutEventAttributes
DecisionTaskTimeoutType
pTimeoutType_
Integer
pScheduledEventId_
Integer
pStartedEventId_ =
DecisionTaskTimedOutEventAttributes' :: DecisionTaskTimeoutType
-> Integer -> Integer -> DecisionTaskTimedOutEventAttributes
DecisionTaskTimedOutEventAttributes'
{ $sel:timeoutType:DecisionTaskTimedOutEventAttributes' :: DecisionTaskTimeoutType
timeoutType =
DecisionTaskTimeoutType
pTimeoutType_,
$sel:scheduledEventId:DecisionTaskTimedOutEventAttributes' :: Integer
scheduledEventId = Integer
pScheduledEventId_,
$sel:startedEventId:DecisionTaskTimedOutEventAttributes' :: Integer
startedEventId = Integer
pStartedEventId_
}
decisionTaskTimedOutEventAttributes_timeoutType :: Lens.Lens' DecisionTaskTimedOutEventAttributes DecisionTaskTimeoutType
decisionTaskTimedOutEventAttributes_timeoutType :: (DecisionTaskTimeoutType -> f DecisionTaskTimeoutType)
-> DecisionTaskTimedOutEventAttributes
-> f DecisionTaskTimedOutEventAttributes
decisionTaskTimedOutEventAttributes_timeoutType = (DecisionTaskTimedOutEventAttributes -> DecisionTaskTimeoutType)
-> (DecisionTaskTimedOutEventAttributes
-> DecisionTaskTimeoutType -> DecisionTaskTimedOutEventAttributes)
-> Lens
DecisionTaskTimedOutEventAttributes
DecisionTaskTimedOutEventAttributes
DecisionTaskTimeoutType
DecisionTaskTimeoutType
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DecisionTaskTimedOutEventAttributes' {DecisionTaskTimeoutType
timeoutType :: DecisionTaskTimeoutType
$sel:timeoutType:DecisionTaskTimedOutEventAttributes' :: DecisionTaskTimedOutEventAttributes -> DecisionTaskTimeoutType
timeoutType} -> DecisionTaskTimeoutType
timeoutType) (\s :: DecisionTaskTimedOutEventAttributes
s@DecisionTaskTimedOutEventAttributes' {} DecisionTaskTimeoutType
a -> DecisionTaskTimedOutEventAttributes
s {$sel:timeoutType:DecisionTaskTimedOutEventAttributes' :: DecisionTaskTimeoutType
timeoutType = DecisionTaskTimeoutType
a} :: DecisionTaskTimedOutEventAttributes)
decisionTaskTimedOutEventAttributes_scheduledEventId :: Lens.Lens' DecisionTaskTimedOutEventAttributes Prelude.Integer
decisionTaskTimedOutEventAttributes_scheduledEventId :: (Integer -> f Integer)
-> DecisionTaskTimedOutEventAttributes
-> f DecisionTaskTimedOutEventAttributes
decisionTaskTimedOutEventAttributes_scheduledEventId = (DecisionTaskTimedOutEventAttributes -> Integer)
-> (DecisionTaskTimedOutEventAttributes
-> Integer -> DecisionTaskTimedOutEventAttributes)
-> Lens
DecisionTaskTimedOutEventAttributes
DecisionTaskTimedOutEventAttributes
Integer
Integer
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DecisionTaskTimedOutEventAttributes' {Integer
scheduledEventId :: Integer
$sel:scheduledEventId:DecisionTaskTimedOutEventAttributes' :: DecisionTaskTimedOutEventAttributes -> Integer
scheduledEventId} -> Integer
scheduledEventId) (\s :: DecisionTaskTimedOutEventAttributes
s@DecisionTaskTimedOutEventAttributes' {} Integer
a -> DecisionTaskTimedOutEventAttributes
s {$sel:scheduledEventId:DecisionTaskTimedOutEventAttributes' :: Integer
scheduledEventId = Integer
a} :: DecisionTaskTimedOutEventAttributes)
decisionTaskTimedOutEventAttributes_startedEventId :: Lens.Lens' DecisionTaskTimedOutEventAttributes Prelude.Integer
decisionTaskTimedOutEventAttributes_startedEventId :: (Integer -> f Integer)
-> DecisionTaskTimedOutEventAttributes
-> f DecisionTaskTimedOutEventAttributes
decisionTaskTimedOutEventAttributes_startedEventId = (DecisionTaskTimedOutEventAttributes -> Integer)
-> (DecisionTaskTimedOutEventAttributes
-> Integer -> DecisionTaskTimedOutEventAttributes)
-> Lens
DecisionTaskTimedOutEventAttributes
DecisionTaskTimedOutEventAttributes
Integer
Integer
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DecisionTaskTimedOutEventAttributes' {Integer
startedEventId :: Integer
$sel:startedEventId:DecisionTaskTimedOutEventAttributes' :: DecisionTaskTimedOutEventAttributes -> Integer
startedEventId} -> Integer
startedEventId) (\s :: DecisionTaskTimedOutEventAttributes
s@DecisionTaskTimedOutEventAttributes' {} Integer
a -> DecisionTaskTimedOutEventAttributes
s {$sel:startedEventId:DecisionTaskTimedOutEventAttributes' :: Integer
startedEventId = Integer
a} :: DecisionTaskTimedOutEventAttributes)
instance
Core.FromJSON
DecisionTaskTimedOutEventAttributes
where
parseJSON :: Value -> Parser DecisionTaskTimedOutEventAttributes
parseJSON =
String
-> (Object -> Parser DecisionTaskTimedOutEventAttributes)
-> Value
-> Parser DecisionTaskTimedOutEventAttributes
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
String
"DecisionTaskTimedOutEventAttributes"
( \Object
x ->
DecisionTaskTimeoutType
-> Integer -> Integer -> DecisionTaskTimedOutEventAttributes
DecisionTaskTimedOutEventAttributes'
(DecisionTaskTimeoutType
-> Integer -> Integer -> DecisionTaskTimedOutEventAttributes)
-> Parser DecisionTaskTimeoutType
-> Parser
(Integer -> Integer -> DecisionTaskTimedOutEventAttributes)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Parser DecisionTaskTimeoutType
forall a. FromJSON a => Object -> Text -> Parser a
Core..: Text
"timeoutType")
Parser (Integer -> Integer -> DecisionTaskTimedOutEventAttributes)
-> Parser Integer
-> Parser (Integer -> DecisionTaskTimedOutEventAttributes)
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
"scheduledEventId")
Parser (Integer -> DecisionTaskTimedOutEventAttributes)
-> Parser Integer -> Parser DecisionTaskTimedOutEventAttributes
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
"startedEventId")
)
instance
Prelude.Hashable
DecisionTaskTimedOutEventAttributes
instance
Prelude.NFData
DecisionTaskTimedOutEventAttributes