{-# 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.ChildWorkflowExecutionCanceledEventAttributes where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
import Amazonka.SWF.Types.WorkflowExecution
import Amazonka.SWF.Types.WorkflowType
data ChildWorkflowExecutionCanceledEventAttributes = ChildWorkflowExecutionCanceledEventAttributes'
{
ChildWorkflowExecutionCanceledEventAttributes -> Maybe Text
details :: Prelude.Maybe Prelude.Text,
ChildWorkflowExecutionCanceledEventAttributes -> WorkflowExecution
workflowExecution :: WorkflowExecution,
ChildWorkflowExecutionCanceledEventAttributes -> WorkflowType
workflowType :: WorkflowType,
ChildWorkflowExecutionCanceledEventAttributes -> Integer
initiatedEventId :: Prelude.Integer,
ChildWorkflowExecutionCanceledEventAttributes -> Integer
startedEventId :: Prelude.Integer
}
deriving (ChildWorkflowExecutionCanceledEventAttributes
-> ChildWorkflowExecutionCanceledEventAttributes -> Bool
(ChildWorkflowExecutionCanceledEventAttributes
-> ChildWorkflowExecutionCanceledEventAttributes -> Bool)
-> (ChildWorkflowExecutionCanceledEventAttributes
-> ChildWorkflowExecutionCanceledEventAttributes -> Bool)
-> Eq ChildWorkflowExecutionCanceledEventAttributes
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ChildWorkflowExecutionCanceledEventAttributes
-> ChildWorkflowExecutionCanceledEventAttributes -> Bool
$c/= :: ChildWorkflowExecutionCanceledEventAttributes
-> ChildWorkflowExecutionCanceledEventAttributes -> Bool
== :: ChildWorkflowExecutionCanceledEventAttributes
-> ChildWorkflowExecutionCanceledEventAttributes -> Bool
$c== :: ChildWorkflowExecutionCanceledEventAttributes
-> ChildWorkflowExecutionCanceledEventAttributes -> Bool
Prelude.Eq, ReadPrec [ChildWorkflowExecutionCanceledEventAttributes]
ReadPrec ChildWorkflowExecutionCanceledEventAttributes
Int -> ReadS ChildWorkflowExecutionCanceledEventAttributes
ReadS [ChildWorkflowExecutionCanceledEventAttributes]
(Int -> ReadS ChildWorkflowExecutionCanceledEventAttributes)
-> ReadS [ChildWorkflowExecutionCanceledEventAttributes]
-> ReadPrec ChildWorkflowExecutionCanceledEventAttributes
-> ReadPrec [ChildWorkflowExecutionCanceledEventAttributes]
-> Read ChildWorkflowExecutionCanceledEventAttributes
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ChildWorkflowExecutionCanceledEventAttributes]
$creadListPrec :: ReadPrec [ChildWorkflowExecutionCanceledEventAttributes]
readPrec :: ReadPrec ChildWorkflowExecutionCanceledEventAttributes
$creadPrec :: ReadPrec ChildWorkflowExecutionCanceledEventAttributes
readList :: ReadS [ChildWorkflowExecutionCanceledEventAttributes]
$creadList :: ReadS [ChildWorkflowExecutionCanceledEventAttributes]
readsPrec :: Int -> ReadS ChildWorkflowExecutionCanceledEventAttributes
$creadsPrec :: Int -> ReadS ChildWorkflowExecutionCanceledEventAttributes
Prelude.Read, Int -> ChildWorkflowExecutionCanceledEventAttributes -> ShowS
[ChildWorkflowExecutionCanceledEventAttributes] -> ShowS
ChildWorkflowExecutionCanceledEventAttributes -> String
(Int -> ChildWorkflowExecutionCanceledEventAttributes -> ShowS)
-> (ChildWorkflowExecutionCanceledEventAttributes -> String)
-> ([ChildWorkflowExecutionCanceledEventAttributes] -> ShowS)
-> Show ChildWorkflowExecutionCanceledEventAttributes
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ChildWorkflowExecutionCanceledEventAttributes] -> ShowS
$cshowList :: [ChildWorkflowExecutionCanceledEventAttributes] -> ShowS
show :: ChildWorkflowExecutionCanceledEventAttributes -> String
$cshow :: ChildWorkflowExecutionCanceledEventAttributes -> String
showsPrec :: Int -> ChildWorkflowExecutionCanceledEventAttributes -> ShowS
$cshowsPrec :: Int -> ChildWorkflowExecutionCanceledEventAttributes -> ShowS
Prelude.Show, (forall x.
ChildWorkflowExecutionCanceledEventAttributes
-> Rep ChildWorkflowExecutionCanceledEventAttributes x)
-> (forall x.
Rep ChildWorkflowExecutionCanceledEventAttributes x
-> ChildWorkflowExecutionCanceledEventAttributes)
-> Generic ChildWorkflowExecutionCanceledEventAttributes
forall x.
Rep ChildWorkflowExecutionCanceledEventAttributes x
-> ChildWorkflowExecutionCanceledEventAttributes
forall x.
ChildWorkflowExecutionCanceledEventAttributes
-> Rep ChildWorkflowExecutionCanceledEventAttributes x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep ChildWorkflowExecutionCanceledEventAttributes x
-> ChildWorkflowExecutionCanceledEventAttributes
$cfrom :: forall x.
ChildWorkflowExecutionCanceledEventAttributes
-> Rep ChildWorkflowExecutionCanceledEventAttributes x
Prelude.Generic)
newChildWorkflowExecutionCanceledEventAttributes ::
WorkflowExecution ->
WorkflowType ->
Prelude.Integer ->
Prelude.Integer ->
ChildWorkflowExecutionCanceledEventAttributes
newChildWorkflowExecutionCanceledEventAttributes :: WorkflowExecution
-> WorkflowType
-> Integer
-> Integer
-> ChildWorkflowExecutionCanceledEventAttributes
newChildWorkflowExecutionCanceledEventAttributes
WorkflowExecution
pWorkflowExecution_
WorkflowType
pWorkflowType_
Integer
pInitiatedEventId_
Integer
pStartedEventId_ =
ChildWorkflowExecutionCanceledEventAttributes' :: Maybe Text
-> WorkflowExecution
-> WorkflowType
-> Integer
-> Integer
-> ChildWorkflowExecutionCanceledEventAttributes
ChildWorkflowExecutionCanceledEventAttributes'
{ $sel:details:ChildWorkflowExecutionCanceledEventAttributes' :: Maybe Text
details =
Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:workflowExecution:ChildWorkflowExecutionCanceledEventAttributes' :: WorkflowExecution
workflowExecution =
WorkflowExecution
pWorkflowExecution_,
$sel:workflowType:ChildWorkflowExecutionCanceledEventAttributes' :: WorkflowType
workflowType =
WorkflowType
pWorkflowType_,
$sel:initiatedEventId:ChildWorkflowExecutionCanceledEventAttributes' :: Integer
initiatedEventId =
Integer
pInitiatedEventId_,
$sel:startedEventId:ChildWorkflowExecutionCanceledEventAttributes' :: Integer
startedEventId =
Integer
pStartedEventId_
}
childWorkflowExecutionCanceledEventAttributes_details :: Lens.Lens' ChildWorkflowExecutionCanceledEventAttributes (Prelude.Maybe Prelude.Text)
childWorkflowExecutionCanceledEventAttributes_details :: (Maybe Text -> f (Maybe Text))
-> ChildWorkflowExecutionCanceledEventAttributes
-> f ChildWorkflowExecutionCanceledEventAttributes
childWorkflowExecutionCanceledEventAttributes_details = (ChildWorkflowExecutionCanceledEventAttributes -> Maybe Text)
-> (ChildWorkflowExecutionCanceledEventAttributes
-> Maybe Text -> ChildWorkflowExecutionCanceledEventAttributes)
-> Lens
ChildWorkflowExecutionCanceledEventAttributes
ChildWorkflowExecutionCanceledEventAttributes
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ChildWorkflowExecutionCanceledEventAttributes' {Maybe Text
details :: Maybe Text
$sel:details:ChildWorkflowExecutionCanceledEventAttributes' :: ChildWorkflowExecutionCanceledEventAttributes -> Maybe Text
details} -> Maybe Text
details) (\s :: ChildWorkflowExecutionCanceledEventAttributes
s@ChildWorkflowExecutionCanceledEventAttributes' {} Maybe Text
a -> ChildWorkflowExecutionCanceledEventAttributes
s {$sel:details:ChildWorkflowExecutionCanceledEventAttributes' :: Maybe Text
details = Maybe Text
a} :: ChildWorkflowExecutionCanceledEventAttributes)
childWorkflowExecutionCanceledEventAttributes_workflowExecution :: Lens.Lens' ChildWorkflowExecutionCanceledEventAttributes WorkflowExecution
childWorkflowExecutionCanceledEventAttributes_workflowExecution :: (WorkflowExecution -> f WorkflowExecution)
-> ChildWorkflowExecutionCanceledEventAttributes
-> f ChildWorkflowExecutionCanceledEventAttributes
childWorkflowExecutionCanceledEventAttributes_workflowExecution = (ChildWorkflowExecutionCanceledEventAttributes
-> WorkflowExecution)
-> (ChildWorkflowExecutionCanceledEventAttributes
-> WorkflowExecution
-> ChildWorkflowExecutionCanceledEventAttributes)
-> Lens
ChildWorkflowExecutionCanceledEventAttributes
ChildWorkflowExecutionCanceledEventAttributes
WorkflowExecution
WorkflowExecution
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ChildWorkflowExecutionCanceledEventAttributes' {WorkflowExecution
workflowExecution :: WorkflowExecution
$sel:workflowExecution:ChildWorkflowExecutionCanceledEventAttributes' :: ChildWorkflowExecutionCanceledEventAttributes -> WorkflowExecution
workflowExecution} -> WorkflowExecution
workflowExecution) (\s :: ChildWorkflowExecutionCanceledEventAttributes
s@ChildWorkflowExecutionCanceledEventAttributes' {} WorkflowExecution
a -> ChildWorkflowExecutionCanceledEventAttributes
s {$sel:workflowExecution:ChildWorkflowExecutionCanceledEventAttributes' :: WorkflowExecution
workflowExecution = WorkflowExecution
a} :: ChildWorkflowExecutionCanceledEventAttributes)
childWorkflowExecutionCanceledEventAttributes_workflowType :: Lens.Lens' ChildWorkflowExecutionCanceledEventAttributes WorkflowType
childWorkflowExecutionCanceledEventAttributes_workflowType :: (WorkflowType -> f WorkflowType)
-> ChildWorkflowExecutionCanceledEventAttributes
-> f ChildWorkflowExecutionCanceledEventAttributes
childWorkflowExecutionCanceledEventAttributes_workflowType = (ChildWorkflowExecutionCanceledEventAttributes -> WorkflowType)
-> (ChildWorkflowExecutionCanceledEventAttributes
-> WorkflowType -> ChildWorkflowExecutionCanceledEventAttributes)
-> Lens
ChildWorkflowExecutionCanceledEventAttributes
ChildWorkflowExecutionCanceledEventAttributes
WorkflowType
WorkflowType
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ChildWorkflowExecutionCanceledEventAttributes' {WorkflowType
workflowType :: WorkflowType
$sel:workflowType:ChildWorkflowExecutionCanceledEventAttributes' :: ChildWorkflowExecutionCanceledEventAttributes -> WorkflowType
workflowType} -> WorkflowType
workflowType) (\s :: ChildWorkflowExecutionCanceledEventAttributes
s@ChildWorkflowExecutionCanceledEventAttributes' {} WorkflowType
a -> ChildWorkflowExecutionCanceledEventAttributes
s {$sel:workflowType:ChildWorkflowExecutionCanceledEventAttributes' :: WorkflowType
workflowType = WorkflowType
a} :: ChildWorkflowExecutionCanceledEventAttributes)
childWorkflowExecutionCanceledEventAttributes_initiatedEventId :: Lens.Lens' ChildWorkflowExecutionCanceledEventAttributes Prelude.Integer
childWorkflowExecutionCanceledEventAttributes_initiatedEventId :: (Integer -> f Integer)
-> ChildWorkflowExecutionCanceledEventAttributes
-> f ChildWorkflowExecutionCanceledEventAttributes
childWorkflowExecutionCanceledEventAttributes_initiatedEventId = (ChildWorkflowExecutionCanceledEventAttributes -> Integer)
-> (ChildWorkflowExecutionCanceledEventAttributes
-> Integer -> ChildWorkflowExecutionCanceledEventAttributes)
-> Lens
ChildWorkflowExecutionCanceledEventAttributes
ChildWorkflowExecutionCanceledEventAttributes
Integer
Integer
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ChildWorkflowExecutionCanceledEventAttributes' {Integer
initiatedEventId :: Integer
$sel:initiatedEventId:ChildWorkflowExecutionCanceledEventAttributes' :: ChildWorkflowExecutionCanceledEventAttributes -> Integer
initiatedEventId} -> Integer
initiatedEventId) (\s :: ChildWorkflowExecutionCanceledEventAttributes
s@ChildWorkflowExecutionCanceledEventAttributes' {} Integer
a -> ChildWorkflowExecutionCanceledEventAttributes
s {$sel:initiatedEventId:ChildWorkflowExecutionCanceledEventAttributes' :: Integer
initiatedEventId = Integer
a} :: ChildWorkflowExecutionCanceledEventAttributes)
childWorkflowExecutionCanceledEventAttributes_startedEventId :: Lens.Lens' ChildWorkflowExecutionCanceledEventAttributes Prelude.Integer
childWorkflowExecutionCanceledEventAttributes_startedEventId :: (Integer -> f Integer)
-> ChildWorkflowExecutionCanceledEventAttributes
-> f ChildWorkflowExecutionCanceledEventAttributes
childWorkflowExecutionCanceledEventAttributes_startedEventId = (ChildWorkflowExecutionCanceledEventAttributes -> Integer)
-> (ChildWorkflowExecutionCanceledEventAttributes
-> Integer -> ChildWorkflowExecutionCanceledEventAttributes)
-> Lens
ChildWorkflowExecutionCanceledEventAttributes
ChildWorkflowExecutionCanceledEventAttributes
Integer
Integer
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ChildWorkflowExecutionCanceledEventAttributes' {Integer
startedEventId :: Integer
$sel:startedEventId:ChildWorkflowExecutionCanceledEventAttributes' :: ChildWorkflowExecutionCanceledEventAttributes -> Integer
startedEventId} -> Integer
startedEventId) (\s :: ChildWorkflowExecutionCanceledEventAttributes
s@ChildWorkflowExecutionCanceledEventAttributes' {} Integer
a -> ChildWorkflowExecutionCanceledEventAttributes
s {$sel:startedEventId:ChildWorkflowExecutionCanceledEventAttributes' :: Integer
startedEventId = Integer
a} :: ChildWorkflowExecutionCanceledEventAttributes)
instance
Core.FromJSON
ChildWorkflowExecutionCanceledEventAttributes
where
parseJSON :: Value -> Parser ChildWorkflowExecutionCanceledEventAttributes
parseJSON =
String
-> (Object -> Parser ChildWorkflowExecutionCanceledEventAttributes)
-> Value
-> Parser ChildWorkflowExecutionCanceledEventAttributes
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
String
"ChildWorkflowExecutionCanceledEventAttributes"
( \Object
x ->
Maybe Text
-> WorkflowExecution
-> WorkflowType
-> Integer
-> Integer
-> ChildWorkflowExecutionCanceledEventAttributes
ChildWorkflowExecutionCanceledEventAttributes'
(Maybe Text
-> WorkflowExecution
-> WorkflowType
-> Integer
-> Integer
-> ChildWorkflowExecutionCanceledEventAttributes)
-> Parser (Maybe Text)
-> Parser
(WorkflowExecution
-> WorkflowType
-> Integer
-> Integer
-> ChildWorkflowExecutionCanceledEventAttributes)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"details")
Parser
(WorkflowExecution
-> WorkflowType
-> Integer
-> Integer
-> ChildWorkflowExecutionCanceledEventAttributes)
-> Parser WorkflowExecution
-> Parser
(WorkflowType
-> Integer
-> Integer
-> ChildWorkflowExecutionCanceledEventAttributes)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser WorkflowExecution
forall a. FromJSON a => Object -> Text -> Parser a
Core..: Text
"workflowExecution")
Parser
(WorkflowType
-> Integer
-> Integer
-> ChildWorkflowExecutionCanceledEventAttributes)
-> Parser WorkflowType
-> Parser
(Integer
-> Integer -> ChildWorkflowExecutionCanceledEventAttributes)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser WorkflowType
forall a. FromJSON a => Object -> Text -> Parser a
Core..: Text
"workflowType")
Parser
(Integer
-> Integer -> ChildWorkflowExecutionCanceledEventAttributes)
-> Parser Integer
-> Parser
(Integer -> ChildWorkflowExecutionCanceledEventAttributes)
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
"initiatedEventId")
Parser (Integer -> ChildWorkflowExecutionCanceledEventAttributes)
-> Parser Integer
-> Parser ChildWorkflowExecutionCanceledEventAttributes
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
ChildWorkflowExecutionCanceledEventAttributes
instance
Prelude.NFData
ChildWorkflowExecutionCanceledEventAttributes