{-# 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.SMS.Types.OutputFormat
-- 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.SMS.Types.OutputFormat
  ( OutputFormat
      ( ..,
        OutputFormat_JSON,
        OutputFormat_YAML
      ),
  )
where

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

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

pattern OutputFormat_JSON :: OutputFormat
pattern $bOutputFormat_JSON :: OutputFormat
$mOutputFormat_JSON :: forall r. OutputFormat -> (Void# -> r) -> (Void# -> r) -> r
OutputFormat_JSON = OutputFormat' "JSON"

pattern OutputFormat_YAML :: OutputFormat
pattern $bOutputFormat_YAML :: OutputFormat
$mOutputFormat_YAML :: forall r. OutputFormat -> (Void# -> r) -> (Void# -> r) -> r
OutputFormat_YAML = OutputFormat' "YAML"

{-# COMPLETE
  OutputFormat_JSON,
  OutputFormat_YAML,
  OutputFormat'
  #-}