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