{-# 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.GamesParks.Types.ResultCode
-- 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.GamesParks.Types.ResultCode
  ( ResultCode
      ( ..,
        ResultCode_INVALID_ROLE_FAILURE,
        ResultCode_SUCCESS,
        ResultCode_UNSPECIFIED_FAILURE
      ),
  )
where

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

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

pattern ResultCode_INVALID_ROLE_FAILURE :: ResultCode
pattern $bResultCode_INVALID_ROLE_FAILURE :: ResultCode
$mResultCode_INVALID_ROLE_FAILURE :: forall {r}. ResultCode -> ((# #) -> r) -> ((# #) -> r) -> r
ResultCode_INVALID_ROLE_FAILURE = ResultCode' "INVALID_ROLE_FAILURE"

pattern ResultCode_SUCCESS :: ResultCode
pattern $bResultCode_SUCCESS :: ResultCode
$mResultCode_SUCCESS :: forall {r}. ResultCode -> ((# #) -> r) -> ((# #) -> r) -> r
ResultCode_SUCCESS = ResultCode' "SUCCESS"

pattern ResultCode_UNSPECIFIED_FAILURE :: ResultCode
pattern $bResultCode_UNSPECIFIED_FAILURE :: ResultCode
$mResultCode_UNSPECIFIED_FAILURE :: forall {r}. ResultCode -> ((# #) -> r) -> ((# #) -> r) -> r
ResultCode_UNSPECIFIED_FAILURE = ResultCode' "UNSPECIFIED_FAILURE"

{-# COMPLETE
  ResultCode_INVALID_ROLE_FAILURE,
  ResultCode_SUCCESS,
  ResultCode_UNSPECIFIED_FAILURE,
  ResultCode'
  #-}