{-# 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.FinSpaceData.Types.FormatType
-- 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.FinSpaceData.Types.FormatType
  ( FormatType
      ( ..,
        FormatType_CSV,
        FormatType_JSON,
        FormatType_PARQUET,
        FormatType_XML
      ),
  )
where

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

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

pattern FormatType_CSV :: FormatType
pattern $bFormatType_CSV :: FormatType
$mFormatType_CSV :: forall r. FormatType -> (Void# -> r) -> (Void# -> r) -> r
FormatType_CSV = FormatType' "CSV"

pattern FormatType_JSON :: FormatType
pattern $bFormatType_JSON :: FormatType
$mFormatType_JSON :: forall r. FormatType -> (Void# -> r) -> (Void# -> r) -> r
FormatType_JSON = FormatType' "JSON"

pattern FormatType_PARQUET :: FormatType
pattern $bFormatType_PARQUET :: FormatType
$mFormatType_PARQUET :: forall r. FormatType -> (Void# -> r) -> (Void# -> r) -> r
FormatType_PARQUET = FormatType' "PARQUET"

pattern FormatType_XML :: FormatType
pattern $bFormatType_XML :: FormatType
$mFormatType_XML :: forall r. FormatType -> (Void# -> r) -> (Void# -> r) -> r
FormatType_XML = FormatType' "XML"

{-# COMPLETE
  FormatType_CSV,
  FormatType_JSON,
  FormatType_PARQUET,
  FormatType_XML,
  FormatType'
  #-}