{-# 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.AppSync.Types.FieldLogLevel
-- 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.AppSync.Types.FieldLogLevel
  ( FieldLogLevel
      ( ..,
        FieldLogLevel_ALL,
        FieldLogLevel_ERROR,
        FieldLogLevel_NONE
      ),
  )
where

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

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

pattern FieldLogLevel_ALL :: FieldLogLevel
pattern $bFieldLogLevel_ALL :: FieldLogLevel
$mFieldLogLevel_ALL :: forall r. FieldLogLevel -> (Void# -> r) -> (Void# -> r) -> r
FieldLogLevel_ALL = FieldLogLevel' "ALL"

pattern FieldLogLevel_ERROR :: FieldLogLevel
pattern $bFieldLogLevel_ERROR :: FieldLogLevel
$mFieldLogLevel_ERROR :: forall r. FieldLogLevel -> (Void# -> r) -> (Void# -> r) -> r
FieldLogLevel_ERROR = FieldLogLevel' "ERROR"

pattern FieldLogLevel_NONE :: FieldLogLevel
pattern $bFieldLogLevel_NONE :: FieldLogLevel
$mFieldLogLevel_NONE :: forall r. FieldLogLevel -> (Void# -> r) -> (Void# -> r) -> r
FieldLogLevel_NONE = FieldLogLevel' "NONE"

{-# COMPLETE
  FieldLogLevel_ALL,
  FieldLogLevel_ERROR,
  FieldLogLevel_NONE,
  FieldLogLevel'
  #-}