{-# 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.ConnectCampaigns.Types.GetCampaignStateBatchFailureCode
-- Copyright   : (c) 2013-2023 Brendan Hay
-- License     : Mozilla Public License, v. 2.0.
-- Maintainer  : Brendan Hay
-- Stability   : auto-generated
-- Portability : non-portable (GHC extensions)
module Amazonka.ConnectCampaigns.Types.GetCampaignStateBatchFailureCode
  ( GetCampaignStateBatchFailureCode
      ( ..,
        GetCampaignStateBatchFailureCode_ResourceNotFound,
        GetCampaignStateBatchFailureCode_UnknownError
      ),
  )
where

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

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

pattern GetCampaignStateBatchFailureCode_ResourceNotFound :: GetCampaignStateBatchFailureCode
pattern $bGetCampaignStateBatchFailureCode_ResourceNotFound :: GetCampaignStateBatchFailureCode
$mGetCampaignStateBatchFailureCode_ResourceNotFound :: forall {r}.
GetCampaignStateBatchFailureCode
-> ((# #) -> r) -> ((# #) -> r) -> r
GetCampaignStateBatchFailureCode_ResourceNotFound = GetCampaignStateBatchFailureCode' "ResourceNotFound"

pattern GetCampaignStateBatchFailureCode_UnknownError :: GetCampaignStateBatchFailureCode
pattern $bGetCampaignStateBatchFailureCode_UnknownError :: GetCampaignStateBatchFailureCode
$mGetCampaignStateBatchFailureCode_UnknownError :: forall {r}.
GetCampaignStateBatchFailureCode
-> ((# #) -> r) -> ((# #) -> r) -> r
GetCampaignStateBatchFailureCode_UnknownError = GetCampaignStateBatchFailureCode' "UnknownError"

{-# COMPLETE
  GetCampaignStateBatchFailureCode_ResourceNotFound,
  GetCampaignStateBatchFailureCode_UnknownError,
  GetCampaignStateBatchFailureCode'
  #-}