{-# 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.ResourceGroupsTagging.Types.ResourceErrorCode
-- 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.ResourceGroupsTagging.Types.ResourceErrorCode
  ( ResourceErrorCode
      ( ..,
        ResourceErrorCode_InternalServiceException,
        ResourceErrorCode_InvalidParameterException
      ),
  )
where

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

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

pattern ResourceErrorCode_InternalServiceException :: ResourceErrorCode
pattern $bResourceErrorCode_InternalServiceException :: ResourceErrorCode
$mResourceErrorCode_InternalServiceException :: forall r. ResourceErrorCode -> (Void# -> r) -> (Void# -> r) -> r
ResourceErrorCode_InternalServiceException = ResourceErrorCode' "InternalServiceException"

pattern ResourceErrorCode_InvalidParameterException :: ResourceErrorCode
pattern $bResourceErrorCode_InvalidParameterException :: ResourceErrorCode
$mResourceErrorCode_InvalidParameterException :: forall r. ResourceErrorCode -> (Void# -> r) -> (Void# -> r) -> r
ResourceErrorCode_InvalidParameterException = ResourceErrorCode' "InvalidParameterException"

{-# COMPLETE
  ResourceErrorCode_InternalServiceException,
  ResourceErrorCode_InvalidParameterException,
  ResourceErrorCode'
  #-}