{-# 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.Translate.Types.EncryptionKeyType
-- 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.Translate.Types.EncryptionKeyType
  ( EncryptionKeyType
      ( ..,
        EncryptionKeyType_KMS
      ),
  )
where

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

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

pattern EncryptionKeyType_KMS :: EncryptionKeyType
pattern $bEncryptionKeyType_KMS :: EncryptionKeyType
$mEncryptionKeyType_KMS :: forall r. EncryptionKeyType -> (Void# -> r) -> (Void# -> r) -> r
EncryptionKeyType_KMS = EncryptionKeyType' "KMS"

{-# COMPLETE
  EncryptionKeyType_KMS,
  EncryptionKeyType'
  #-}