{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DerivingStrategies #-}
{-# LANGUAGE GeneralizedNewtypeDeriving #-}
{-# LANGUAGE LambdaCase #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE PatternSynonyms #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}

-- Derived from AWS service descriptions, licensed under Apache 2.0.

-- |
-- Module      : Amazonka.SWF.Types.DecisionType
-- Copyright   : (c) 2013-2021 Brendan Hay
-- License     : Mozilla Public License, v. 2.0.
-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>
-- Stability   : auto-generated
-- Portability : non-portable (GHC extensions)
module Amazonka.SWF.Types.DecisionType
  ( DecisionType
      ( ..,
        DecisionType_CancelTimer,
        DecisionType_CancelWorkflowExecution,
        DecisionType_CompleteWorkflowExecution,
        DecisionType_ContinueAsNewWorkflowExecution,
        DecisionType_FailWorkflowExecution,
        DecisionType_RecordMarker,
        DecisionType_RequestCancelActivityTask,
        DecisionType_RequestCancelExternalWorkflowExecution,
        DecisionType_ScheduleActivityTask,
        DecisionType_ScheduleLambdaFunction,
        DecisionType_SignalExternalWorkflowExecution,
        DecisionType_StartChildWorkflowExecution,
        DecisionType_StartTimer
      ),
  )
where

import qualified Amazonka.Core as Core
import qualified Amazonka.Prelude as Prelude

newtype DecisionType = DecisionType'
  { DecisionType -> Text
fromDecisionType ::
      Core.Text
  }
  deriving stock
    ( Int -> DecisionType -> ShowS
[DecisionType] -> ShowS
DecisionType -> String
(Int -> DecisionType -> ShowS)
-> (DecisionType -> String)
-> ([DecisionType] -> ShowS)
-> Show DecisionType
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DecisionType] -> ShowS
$cshowList :: [DecisionType] -> ShowS
show :: DecisionType -> String
$cshow :: DecisionType -> String
showsPrec :: Int -> DecisionType -> ShowS
$cshowsPrec :: Int -> DecisionType -> ShowS
Prelude.Show,
      ReadPrec [DecisionType]
ReadPrec DecisionType
Int -> ReadS DecisionType
ReadS [DecisionType]
(Int -> ReadS DecisionType)
-> ReadS [DecisionType]
-> ReadPrec DecisionType
-> ReadPrec [DecisionType]
-> Read DecisionType
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DecisionType]
$creadListPrec :: ReadPrec [DecisionType]
readPrec :: ReadPrec DecisionType
$creadPrec :: ReadPrec DecisionType
readList :: ReadS [DecisionType]
$creadList :: ReadS [DecisionType]
readsPrec :: Int -> ReadS DecisionType
$creadsPrec :: Int -> ReadS DecisionType
Prelude.Read,
      DecisionType -> DecisionType -> Bool
(DecisionType -> DecisionType -> Bool)
-> (DecisionType -> DecisionType -> Bool) -> Eq DecisionType
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DecisionType -> DecisionType -> Bool
$c/= :: DecisionType -> DecisionType -> Bool
== :: DecisionType -> DecisionType -> Bool
$c== :: DecisionType -> DecisionType -> Bool
Prelude.Eq,
      Eq DecisionType
Eq DecisionType
-> (DecisionType -> DecisionType -> Ordering)
-> (DecisionType -> DecisionType -> Bool)
-> (DecisionType -> DecisionType -> Bool)
-> (DecisionType -> DecisionType -> Bool)
-> (DecisionType -> DecisionType -> Bool)
-> (DecisionType -> DecisionType -> DecisionType)
-> (DecisionType -> DecisionType -> DecisionType)
-> Ord DecisionType
DecisionType -> DecisionType -> Bool
DecisionType -> DecisionType -> Ordering
DecisionType -> DecisionType -> DecisionType
forall a.
Eq a
-> (a -> a -> Ordering)
-> (a -> a -> Bool)
-> (a -> a -> Bool)
-> (a -> a -> Bool)
-> (a -> a -> Bool)
-> (a -> a -> a)
-> (a -> a -> a)
-> Ord a
min :: DecisionType -> DecisionType -> DecisionType
$cmin :: DecisionType -> DecisionType -> DecisionType
max :: DecisionType -> DecisionType -> DecisionType
$cmax :: DecisionType -> DecisionType -> DecisionType
>= :: DecisionType -> DecisionType -> Bool
$c>= :: DecisionType -> DecisionType -> Bool
> :: DecisionType -> DecisionType -> Bool
$c> :: DecisionType -> DecisionType -> Bool
<= :: DecisionType -> DecisionType -> Bool
$c<= :: DecisionType -> DecisionType -> Bool
< :: DecisionType -> DecisionType -> Bool
$c< :: DecisionType -> DecisionType -> Bool
compare :: DecisionType -> DecisionType -> Ordering
$ccompare :: DecisionType -> DecisionType -> Ordering
$cp1Ord :: Eq DecisionType
Prelude.Ord,
      (forall x. DecisionType -> Rep DecisionType x)
-> (forall x. Rep DecisionType x -> DecisionType)
-> Generic DecisionType
forall x. Rep DecisionType x -> DecisionType
forall x. DecisionType -> Rep DecisionType x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep DecisionType x -> DecisionType
$cfrom :: forall x. DecisionType -> Rep DecisionType x
Prelude.Generic
    )
  deriving newtype
    ( Int -> DecisionType -> Int
DecisionType -> Int
(Int -> DecisionType -> Int)
-> (DecisionType -> Int) -> Hashable DecisionType
forall a. (Int -> a -> Int) -> (a -> Int) -> Hashable a
hash :: DecisionType -> Int
$chash :: DecisionType -> Int
hashWithSalt :: Int -> DecisionType -> Int
$chashWithSalt :: Int -> DecisionType -> Int
Prelude.Hashable,
      DecisionType -> ()
(DecisionType -> ()) -> NFData DecisionType
forall a. (a -> ()) -> NFData a
rnf :: DecisionType -> ()
$crnf :: DecisionType -> ()
Prelude.NFData,
      Text -> Either String DecisionType
(Text -> Either String DecisionType) -> FromText DecisionType
forall a. (Text -> Either String a) -> FromText a
fromText :: Text -> Either String DecisionType
$cfromText :: Text -> Either String DecisionType
Core.FromText,
      DecisionType -> Text
(DecisionType -> Text) -> ToText DecisionType
forall a. (a -> Text) -> ToText a
toText :: DecisionType -> Text
$ctoText :: DecisionType -> Text
Core.ToText,
      DecisionType -> ByteString
(DecisionType -> ByteString) -> ToByteString DecisionType
forall a. (a -> ByteString) -> ToByteString a
toBS :: DecisionType -> ByteString
$ctoBS :: DecisionType -> ByteString
Core.ToByteString,
      DecisionType -> ByteStringBuilder
(DecisionType -> ByteStringBuilder) -> ToLog DecisionType
forall a. (a -> ByteStringBuilder) -> ToLog a
build :: DecisionType -> ByteStringBuilder
$cbuild :: DecisionType -> ByteStringBuilder
Core.ToLog,
      HeaderName -> DecisionType -> [Header]
(HeaderName -> DecisionType -> [Header]) -> ToHeader DecisionType
forall a. (HeaderName -> a -> [Header]) -> ToHeader a
toHeader :: HeaderName -> DecisionType -> [Header]
$ctoHeader :: HeaderName -> DecisionType -> [Header]
Core.ToHeader,
      DecisionType -> QueryString
(DecisionType -> QueryString) -> ToQuery DecisionType
forall a. (a -> QueryString) -> ToQuery a
toQuery :: DecisionType -> QueryString
$ctoQuery :: DecisionType -> QueryString
Core.ToQuery,
      Value -> Parser [DecisionType]
Value -> Parser DecisionType
(Value -> Parser DecisionType)
-> (Value -> Parser [DecisionType]) -> FromJSON DecisionType
forall a.
(Value -> Parser a) -> (Value -> Parser [a]) -> FromJSON a
parseJSONList :: Value -> Parser [DecisionType]
$cparseJSONList :: Value -> Parser [DecisionType]
parseJSON :: Value -> Parser DecisionType
$cparseJSON :: Value -> Parser DecisionType
Core.FromJSON,
      FromJSONKeyFunction [DecisionType]
FromJSONKeyFunction DecisionType
FromJSONKeyFunction DecisionType
-> FromJSONKeyFunction [DecisionType] -> FromJSONKey DecisionType
forall a.
FromJSONKeyFunction a -> FromJSONKeyFunction [a] -> FromJSONKey a
fromJSONKeyList :: FromJSONKeyFunction [DecisionType]
$cfromJSONKeyList :: FromJSONKeyFunction [DecisionType]
fromJSONKey :: FromJSONKeyFunction DecisionType
$cfromJSONKey :: FromJSONKeyFunction DecisionType
Core.FromJSONKey,
      [DecisionType] -> Encoding
[DecisionType] -> Value
DecisionType -> Encoding
DecisionType -> Value
(DecisionType -> Value)
-> (DecisionType -> Encoding)
-> ([DecisionType] -> Value)
-> ([DecisionType] -> Encoding)
-> ToJSON DecisionType
forall a.
(a -> Value)
-> (a -> Encoding)
-> ([a] -> Value)
-> ([a] -> Encoding)
-> ToJSON a
toEncodingList :: [DecisionType] -> Encoding
$ctoEncodingList :: [DecisionType] -> Encoding
toJSONList :: [DecisionType] -> Value
$ctoJSONList :: [DecisionType] -> Value
toEncoding :: DecisionType -> Encoding
$ctoEncoding :: DecisionType -> Encoding
toJSON :: DecisionType -> Value
$ctoJSON :: DecisionType -> Value
Core.ToJSON,
      ToJSONKeyFunction [DecisionType]
ToJSONKeyFunction DecisionType
ToJSONKeyFunction DecisionType
-> ToJSONKeyFunction [DecisionType] -> ToJSONKey DecisionType
forall a.
ToJSONKeyFunction a -> ToJSONKeyFunction [a] -> ToJSONKey a
toJSONKeyList :: ToJSONKeyFunction [DecisionType]
$ctoJSONKeyList :: ToJSONKeyFunction [DecisionType]
toJSONKey :: ToJSONKeyFunction DecisionType
$ctoJSONKey :: ToJSONKeyFunction DecisionType
Core.ToJSONKey,
      [Node] -> Either String DecisionType
([Node] -> Either String DecisionType) -> FromXML DecisionType
forall a. ([Node] -> Either String a) -> FromXML a
parseXML :: [Node] -> Either String DecisionType
$cparseXML :: [Node] -> Either String DecisionType
Core.FromXML,
      DecisionType -> XML
(DecisionType -> XML) -> ToXML DecisionType
forall a. (a -> XML) -> ToXML a
toXML :: DecisionType -> XML
$ctoXML :: DecisionType -> XML
Core.ToXML
    )

pattern DecisionType_CancelTimer :: DecisionType
pattern $bDecisionType_CancelTimer :: DecisionType
$mDecisionType_CancelTimer :: forall r. DecisionType -> (Void# -> r) -> (Void# -> r) -> r
DecisionType_CancelTimer = DecisionType' "CancelTimer"

pattern DecisionType_CancelWorkflowExecution :: DecisionType
pattern $bDecisionType_CancelWorkflowExecution :: DecisionType
$mDecisionType_CancelWorkflowExecution :: forall r. DecisionType -> (Void# -> r) -> (Void# -> r) -> r
DecisionType_CancelWorkflowExecution = DecisionType' "CancelWorkflowExecution"

pattern DecisionType_CompleteWorkflowExecution :: DecisionType
pattern $bDecisionType_CompleteWorkflowExecution :: DecisionType
$mDecisionType_CompleteWorkflowExecution :: forall r. DecisionType -> (Void# -> r) -> (Void# -> r) -> r
DecisionType_CompleteWorkflowExecution = DecisionType' "CompleteWorkflowExecution"

pattern DecisionType_ContinueAsNewWorkflowExecution :: DecisionType
pattern $bDecisionType_ContinueAsNewWorkflowExecution :: DecisionType
$mDecisionType_ContinueAsNewWorkflowExecution :: forall r. DecisionType -> (Void# -> r) -> (Void# -> r) -> r
DecisionType_ContinueAsNewWorkflowExecution = DecisionType' "ContinueAsNewWorkflowExecution"

pattern DecisionType_FailWorkflowExecution :: DecisionType
pattern $bDecisionType_FailWorkflowExecution :: DecisionType
$mDecisionType_FailWorkflowExecution :: forall r. DecisionType -> (Void# -> r) -> (Void# -> r) -> r
DecisionType_FailWorkflowExecution = DecisionType' "FailWorkflowExecution"

pattern DecisionType_RecordMarker :: DecisionType
pattern $bDecisionType_RecordMarker :: DecisionType
$mDecisionType_RecordMarker :: forall r. DecisionType -> (Void# -> r) -> (Void# -> r) -> r
DecisionType_RecordMarker = DecisionType' "RecordMarker"

pattern DecisionType_RequestCancelActivityTask :: DecisionType
pattern $bDecisionType_RequestCancelActivityTask :: DecisionType
$mDecisionType_RequestCancelActivityTask :: forall r. DecisionType -> (Void# -> r) -> (Void# -> r) -> r
DecisionType_RequestCancelActivityTask = DecisionType' "RequestCancelActivityTask"

pattern DecisionType_RequestCancelExternalWorkflowExecution :: DecisionType
pattern $bDecisionType_RequestCancelExternalWorkflowExecution :: DecisionType
$mDecisionType_RequestCancelExternalWorkflowExecution :: forall r. DecisionType -> (Void# -> r) -> (Void# -> r) -> r
DecisionType_RequestCancelExternalWorkflowExecution = DecisionType' "RequestCancelExternalWorkflowExecution"

pattern DecisionType_ScheduleActivityTask :: DecisionType
pattern $bDecisionType_ScheduleActivityTask :: DecisionType
$mDecisionType_ScheduleActivityTask :: forall r. DecisionType -> (Void# -> r) -> (Void# -> r) -> r
DecisionType_ScheduleActivityTask = DecisionType' "ScheduleActivityTask"

pattern DecisionType_ScheduleLambdaFunction :: DecisionType
pattern $bDecisionType_ScheduleLambdaFunction :: DecisionType
$mDecisionType_ScheduleLambdaFunction :: forall r. DecisionType -> (Void# -> r) -> (Void# -> r) -> r
DecisionType_ScheduleLambdaFunction = DecisionType' "ScheduleLambdaFunction"

pattern DecisionType_SignalExternalWorkflowExecution :: DecisionType
pattern $bDecisionType_SignalExternalWorkflowExecution :: DecisionType
$mDecisionType_SignalExternalWorkflowExecution :: forall r. DecisionType -> (Void# -> r) -> (Void# -> r) -> r
DecisionType_SignalExternalWorkflowExecution = DecisionType' "SignalExternalWorkflowExecution"

pattern DecisionType_StartChildWorkflowExecution :: DecisionType
pattern $bDecisionType_StartChildWorkflowExecution :: DecisionType
$mDecisionType_StartChildWorkflowExecution :: forall r. DecisionType -> (Void# -> r) -> (Void# -> r) -> r
DecisionType_StartChildWorkflowExecution = DecisionType' "StartChildWorkflowExecution"

pattern DecisionType_StartTimer :: DecisionType
pattern $bDecisionType_StartTimer :: DecisionType
$mDecisionType_StartTimer :: forall r. DecisionType -> (Void# -> r) -> (Void# -> r) -> r
DecisionType_StartTimer = DecisionType' "StartTimer"

{-# COMPLETE
  DecisionType_CancelTimer,
  DecisionType_CancelWorkflowExecution,
  DecisionType_CompleteWorkflowExecution,
  DecisionType_ContinueAsNewWorkflowExecution,
  DecisionType_FailWorkflowExecution,
  DecisionType_RecordMarker,
  DecisionType_RequestCancelActivityTask,
  DecisionType_RequestCancelExternalWorkflowExecution,
  DecisionType_ScheduleActivityTask,
  DecisionType_ScheduleLambdaFunction,
  DecisionType_SignalExternalWorkflowExecution,
  DecisionType_StartChildWorkflowExecution,
  DecisionType_StartTimer,
  DecisionType'
  #-}