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