{-# 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.WorkflowExecutionFailedEventAttributes 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
data WorkflowExecutionFailedEventAttributes = WorkflowExecutionFailedEventAttributes'
{
WorkflowExecutionFailedEventAttributes -> Maybe Text
details :: Prelude.Maybe Prelude.Text,
WorkflowExecutionFailedEventAttributes -> Maybe Text
reason :: Prelude.Maybe Prelude.Text,
WorkflowExecutionFailedEventAttributes -> Integer
decisionTaskCompletedEventId :: Prelude.Integer
}
deriving (WorkflowExecutionFailedEventAttributes
-> WorkflowExecutionFailedEventAttributes -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: WorkflowExecutionFailedEventAttributes
-> WorkflowExecutionFailedEventAttributes -> Bool
$c/= :: WorkflowExecutionFailedEventAttributes
-> WorkflowExecutionFailedEventAttributes -> Bool
== :: WorkflowExecutionFailedEventAttributes
-> WorkflowExecutionFailedEventAttributes -> Bool
$c== :: WorkflowExecutionFailedEventAttributes
-> WorkflowExecutionFailedEventAttributes -> Bool
Prelude.Eq, ReadPrec [WorkflowExecutionFailedEventAttributes]
ReadPrec WorkflowExecutionFailedEventAttributes
Int -> ReadS WorkflowExecutionFailedEventAttributes
ReadS [WorkflowExecutionFailedEventAttributes]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [WorkflowExecutionFailedEventAttributes]
$creadListPrec :: ReadPrec [WorkflowExecutionFailedEventAttributes]
readPrec :: ReadPrec WorkflowExecutionFailedEventAttributes
$creadPrec :: ReadPrec WorkflowExecutionFailedEventAttributes
readList :: ReadS [WorkflowExecutionFailedEventAttributes]
$creadList :: ReadS [WorkflowExecutionFailedEventAttributes]
readsPrec :: Int -> ReadS WorkflowExecutionFailedEventAttributes
$creadsPrec :: Int -> ReadS WorkflowExecutionFailedEventAttributes
Prelude.Read, Int -> WorkflowExecutionFailedEventAttributes -> ShowS
[WorkflowExecutionFailedEventAttributes] -> ShowS
WorkflowExecutionFailedEventAttributes -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [WorkflowExecutionFailedEventAttributes] -> ShowS
$cshowList :: [WorkflowExecutionFailedEventAttributes] -> ShowS
show :: WorkflowExecutionFailedEventAttributes -> String
$cshow :: WorkflowExecutionFailedEventAttributes -> String
showsPrec :: Int -> WorkflowExecutionFailedEventAttributes -> ShowS
$cshowsPrec :: Int -> WorkflowExecutionFailedEventAttributes -> ShowS
Prelude.Show, forall x.
Rep WorkflowExecutionFailedEventAttributes x
-> WorkflowExecutionFailedEventAttributes
forall x.
WorkflowExecutionFailedEventAttributes
-> Rep WorkflowExecutionFailedEventAttributes x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep WorkflowExecutionFailedEventAttributes x
-> WorkflowExecutionFailedEventAttributes
$cfrom :: forall x.
WorkflowExecutionFailedEventAttributes
-> Rep WorkflowExecutionFailedEventAttributes x
Prelude.Generic)
newWorkflowExecutionFailedEventAttributes ::
Prelude.Integer ->
WorkflowExecutionFailedEventAttributes
newWorkflowExecutionFailedEventAttributes :: Integer -> WorkflowExecutionFailedEventAttributes
newWorkflowExecutionFailedEventAttributes
Integer
pDecisionTaskCompletedEventId_ =
WorkflowExecutionFailedEventAttributes'
{ $sel:details:WorkflowExecutionFailedEventAttributes' :: Maybe Text
details =
forall a. Maybe a
Prelude.Nothing,
$sel:reason:WorkflowExecutionFailedEventAttributes' :: Maybe Text
reason = forall a. Maybe a
Prelude.Nothing,
$sel:decisionTaskCompletedEventId:WorkflowExecutionFailedEventAttributes' :: Integer
decisionTaskCompletedEventId =
Integer
pDecisionTaskCompletedEventId_
}
workflowExecutionFailedEventAttributes_details :: Lens.Lens' WorkflowExecutionFailedEventAttributes (Prelude.Maybe Prelude.Text)
workflowExecutionFailedEventAttributes_details :: Lens' WorkflowExecutionFailedEventAttributes (Maybe Text)
workflowExecutionFailedEventAttributes_details = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\WorkflowExecutionFailedEventAttributes' {Maybe Text
details :: Maybe Text
$sel:details:WorkflowExecutionFailedEventAttributes' :: WorkflowExecutionFailedEventAttributes -> Maybe Text
details} -> Maybe Text
details) (\s :: WorkflowExecutionFailedEventAttributes
s@WorkflowExecutionFailedEventAttributes' {} Maybe Text
a -> WorkflowExecutionFailedEventAttributes
s {$sel:details:WorkflowExecutionFailedEventAttributes' :: Maybe Text
details = Maybe Text
a} :: WorkflowExecutionFailedEventAttributes)
workflowExecutionFailedEventAttributes_reason :: Lens.Lens' WorkflowExecutionFailedEventAttributes (Prelude.Maybe Prelude.Text)
workflowExecutionFailedEventAttributes_reason :: Lens' WorkflowExecutionFailedEventAttributes (Maybe Text)
workflowExecutionFailedEventAttributes_reason = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\WorkflowExecutionFailedEventAttributes' {Maybe Text
reason :: Maybe Text
$sel:reason:WorkflowExecutionFailedEventAttributes' :: WorkflowExecutionFailedEventAttributes -> Maybe Text
reason} -> Maybe Text
reason) (\s :: WorkflowExecutionFailedEventAttributes
s@WorkflowExecutionFailedEventAttributes' {} Maybe Text
a -> WorkflowExecutionFailedEventAttributes
s {$sel:reason:WorkflowExecutionFailedEventAttributes' :: Maybe Text
reason = Maybe Text
a} :: WorkflowExecutionFailedEventAttributes)
workflowExecutionFailedEventAttributes_decisionTaskCompletedEventId :: Lens.Lens' WorkflowExecutionFailedEventAttributes Prelude.Integer
workflowExecutionFailedEventAttributes_decisionTaskCompletedEventId :: Lens' WorkflowExecutionFailedEventAttributes Integer
workflowExecutionFailedEventAttributes_decisionTaskCompletedEventId = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\WorkflowExecutionFailedEventAttributes' {Integer
decisionTaskCompletedEventId :: Integer
$sel:decisionTaskCompletedEventId:WorkflowExecutionFailedEventAttributes' :: WorkflowExecutionFailedEventAttributes -> Integer
decisionTaskCompletedEventId} -> Integer
decisionTaskCompletedEventId) (\s :: WorkflowExecutionFailedEventAttributes
s@WorkflowExecutionFailedEventAttributes' {} Integer
a -> WorkflowExecutionFailedEventAttributes
s {$sel:decisionTaskCompletedEventId:WorkflowExecutionFailedEventAttributes' :: Integer
decisionTaskCompletedEventId = Integer
a} :: WorkflowExecutionFailedEventAttributes)
instance
Data.FromJSON
WorkflowExecutionFailedEventAttributes
where
parseJSON :: Value -> Parser WorkflowExecutionFailedEventAttributes
parseJSON =
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.withObject
String
"WorkflowExecutionFailedEventAttributes"
( \Object
x ->
Maybe Text
-> Maybe Text -> Integer -> WorkflowExecutionFailedEventAttributes
WorkflowExecutionFailedEventAttributes'
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
"details")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"reason")
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
"decisionTaskCompletedEventId")
)
instance
Prelude.Hashable
WorkflowExecutionFailedEventAttributes
where
hashWithSalt :: Int -> WorkflowExecutionFailedEventAttributes -> Int
hashWithSalt
Int
_salt
WorkflowExecutionFailedEventAttributes' {Integer
Maybe Text
decisionTaskCompletedEventId :: Integer
reason :: Maybe Text
details :: Maybe Text
$sel:decisionTaskCompletedEventId:WorkflowExecutionFailedEventAttributes' :: WorkflowExecutionFailedEventAttributes -> Integer
$sel:reason:WorkflowExecutionFailedEventAttributes' :: WorkflowExecutionFailedEventAttributes -> Maybe Text
$sel:details:WorkflowExecutionFailedEventAttributes' :: WorkflowExecutionFailedEventAttributes -> Maybe Text
..} =
Int
_salt
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
details
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
reason
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Integer
decisionTaskCompletedEventId
instance
Prelude.NFData
WorkflowExecutionFailedEventAttributes
where
rnf :: WorkflowExecutionFailedEventAttributes -> ()
rnf WorkflowExecutionFailedEventAttributes' {Integer
Maybe Text
decisionTaskCompletedEventId :: Integer
reason :: Maybe Text
details :: Maybe Text
$sel:decisionTaskCompletedEventId:WorkflowExecutionFailedEventAttributes' :: WorkflowExecutionFailedEventAttributes -> Integer
$sel:reason:WorkflowExecutionFailedEventAttributes' :: WorkflowExecutionFailedEventAttributes -> Maybe Text
$sel:details:WorkflowExecutionFailedEventAttributes' :: WorkflowExecutionFailedEventAttributes -> Maybe Text
..} =
forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
details
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
reason
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Integer
decisionTaskCompletedEventId