{-# 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.KinesisAnalyticsV2.Types.CodeContentType
-- 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.KinesisAnalyticsV2.Types.CodeContentType
  ( CodeContentType
      ( ..,
        CodeContentType_PLAINTEXT,
        CodeContentType_ZIPFILE
      ),
  )
where

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

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

pattern CodeContentType_PLAINTEXT :: CodeContentType
pattern $bCodeContentType_PLAINTEXT :: CodeContentType
$mCodeContentType_PLAINTEXT :: forall r. CodeContentType -> (Void# -> r) -> (Void# -> r) -> r
CodeContentType_PLAINTEXT = CodeContentType' "PLAINTEXT"

pattern CodeContentType_ZIPFILE :: CodeContentType
pattern $bCodeContentType_ZIPFILE :: CodeContentType
$mCodeContentType_ZIPFILE :: forall r. CodeContentType -> (Void# -> r) -> (Void# -> r) -> r
CodeContentType_ZIPFILE = CodeContentType' "ZIPFILE"

{-# COMPLETE
  CodeContentType_PLAINTEXT,
  CodeContentType_ZIPFILE,
  CodeContentType'
  #-}