{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DerivingStrategies #-}
{-# LANGUAGE GeneralizedNewtypeDeriving #-}
{-# LANGUAGE LambdaCase #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE PatternSynonyms #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
module Amazonka.KMS.Types.DataKeyPairSpec
( DataKeyPairSpec
( ..,
DataKeyPairSpec_ECC_NIST_P256,
DataKeyPairSpec_ECC_NIST_P384,
DataKeyPairSpec_ECC_NIST_P521,
DataKeyPairSpec_ECC_SECG_P256K1,
DataKeyPairSpec_RSA_2048,
DataKeyPairSpec_RSA_3072,
DataKeyPairSpec_RSA_4096
),
)
where
import qualified Amazonka.Core as Core
import qualified Amazonka.Prelude as Prelude
newtype DataKeyPairSpec = DataKeyPairSpec'
{ DataKeyPairSpec -> Text
fromDataKeyPairSpec ::
Core.Text
}
deriving stock
( Int -> DataKeyPairSpec -> ShowS
[DataKeyPairSpec] -> ShowS
DataKeyPairSpec -> String
(Int -> DataKeyPairSpec -> ShowS)
-> (DataKeyPairSpec -> String)
-> ([DataKeyPairSpec] -> ShowS)
-> Show DataKeyPairSpec
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DataKeyPairSpec] -> ShowS
$cshowList :: [DataKeyPairSpec] -> ShowS
show :: DataKeyPairSpec -> String
$cshow :: DataKeyPairSpec -> String
showsPrec :: Int -> DataKeyPairSpec -> ShowS
$cshowsPrec :: Int -> DataKeyPairSpec -> ShowS
Prelude.Show,
ReadPrec [DataKeyPairSpec]
ReadPrec DataKeyPairSpec
Int -> ReadS DataKeyPairSpec
ReadS [DataKeyPairSpec]
(Int -> ReadS DataKeyPairSpec)
-> ReadS [DataKeyPairSpec]
-> ReadPrec DataKeyPairSpec
-> ReadPrec [DataKeyPairSpec]
-> Read DataKeyPairSpec
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DataKeyPairSpec]
$creadListPrec :: ReadPrec [DataKeyPairSpec]
readPrec :: ReadPrec DataKeyPairSpec
$creadPrec :: ReadPrec DataKeyPairSpec
readList :: ReadS [DataKeyPairSpec]
$creadList :: ReadS [DataKeyPairSpec]
readsPrec :: Int -> ReadS DataKeyPairSpec
$creadsPrec :: Int -> ReadS DataKeyPairSpec
Prelude.Read,
DataKeyPairSpec -> DataKeyPairSpec -> Bool
(DataKeyPairSpec -> DataKeyPairSpec -> Bool)
-> (DataKeyPairSpec -> DataKeyPairSpec -> Bool)
-> Eq DataKeyPairSpec
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DataKeyPairSpec -> DataKeyPairSpec -> Bool
$c/= :: DataKeyPairSpec -> DataKeyPairSpec -> Bool
== :: DataKeyPairSpec -> DataKeyPairSpec -> Bool
$c== :: DataKeyPairSpec -> DataKeyPairSpec -> Bool
Prelude.Eq,
Eq DataKeyPairSpec
Eq DataKeyPairSpec
-> (DataKeyPairSpec -> DataKeyPairSpec -> Ordering)
-> (DataKeyPairSpec -> DataKeyPairSpec -> Bool)
-> (DataKeyPairSpec -> DataKeyPairSpec -> Bool)
-> (DataKeyPairSpec -> DataKeyPairSpec -> Bool)
-> (DataKeyPairSpec -> DataKeyPairSpec -> Bool)
-> (DataKeyPairSpec -> DataKeyPairSpec -> DataKeyPairSpec)
-> (DataKeyPairSpec -> DataKeyPairSpec -> DataKeyPairSpec)
-> Ord DataKeyPairSpec
DataKeyPairSpec -> DataKeyPairSpec -> Bool
DataKeyPairSpec -> DataKeyPairSpec -> Ordering
DataKeyPairSpec -> DataKeyPairSpec -> DataKeyPairSpec
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 :: DataKeyPairSpec -> DataKeyPairSpec -> DataKeyPairSpec
$cmin :: DataKeyPairSpec -> DataKeyPairSpec -> DataKeyPairSpec
max :: DataKeyPairSpec -> DataKeyPairSpec -> DataKeyPairSpec
$cmax :: DataKeyPairSpec -> DataKeyPairSpec -> DataKeyPairSpec
>= :: DataKeyPairSpec -> DataKeyPairSpec -> Bool
$c>= :: DataKeyPairSpec -> DataKeyPairSpec -> Bool
> :: DataKeyPairSpec -> DataKeyPairSpec -> Bool
$c> :: DataKeyPairSpec -> DataKeyPairSpec -> Bool
<= :: DataKeyPairSpec -> DataKeyPairSpec -> Bool
$c<= :: DataKeyPairSpec -> DataKeyPairSpec -> Bool
< :: DataKeyPairSpec -> DataKeyPairSpec -> Bool
$c< :: DataKeyPairSpec -> DataKeyPairSpec -> Bool
compare :: DataKeyPairSpec -> DataKeyPairSpec -> Ordering
$ccompare :: DataKeyPairSpec -> DataKeyPairSpec -> Ordering
$cp1Ord :: Eq DataKeyPairSpec
Prelude.Ord,
(forall x. DataKeyPairSpec -> Rep DataKeyPairSpec x)
-> (forall x. Rep DataKeyPairSpec x -> DataKeyPairSpec)
-> Generic DataKeyPairSpec
forall x. Rep DataKeyPairSpec x -> DataKeyPairSpec
forall x. DataKeyPairSpec -> Rep DataKeyPairSpec x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep DataKeyPairSpec x -> DataKeyPairSpec
$cfrom :: forall x. DataKeyPairSpec -> Rep DataKeyPairSpec x
Prelude.Generic
)
deriving newtype
( Int -> DataKeyPairSpec -> Int
DataKeyPairSpec -> Int
(Int -> DataKeyPairSpec -> Int)
-> (DataKeyPairSpec -> Int) -> Hashable DataKeyPairSpec
forall a. (Int -> a -> Int) -> (a -> Int) -> Hashable a
hash :: DataKeyPairSpec -> Int
$chash :: DataKeyPairSpec -> Int
hashWithSalt :: Int -> DataKeyPairSpec -> Int
$chashWithSalt :: Int -> DataKeyPairSpec -> Int
Prelude.Hashable,
DataKeyPairSpec -> ()
(DataKeyPairSpec -> ()) -> NFData DataKeyPairSpec
forall a. (a -> ()) -> NFData a
rnf :: DataKeyPairSpec -> ()
$crnf :: DataKeyPairSpec -> ()
Prelude.NFData,
Text -> Either String DataKeyPairSpec
(Text -> Either String DataKeyPairSpec) -> FromText DataKeyPairSpec
forall a. (Text -> Either String a) -> FromText a
fromText :: Text -> Either String DataKeyPairSpec
$cfromText :: Text -> Either String DataKeyPairSpec
Core.FromText,
DataKeyPairSpec -> Text
(DataKeyPairSpec -> Text) -> ToText DataKeyPairSpec
forall a. (a -> Text) -> ToText a
toText :: DataKeyPairSpec -> Text
$ctoText :: DataKeyPairSpec -> Text
Core.ToText,
DataKeyPairSpec -> ByteString
(DataKeyPairSpec -> ByteString) -> ToByteString DataKeyPairSpec
forall a. (a -> ByteString) -> ToByteString a
toBS :: DataKeyPairSpec -> ByteString
$ctoBS :: DataKeyPairSpec -> ByteString
Core.ToByteString,
DataKeyPairSpec -> ByteStringBuilder
(DataKeyPairSpec -> ByteStringBuilder) -> ToLog DataKeyPairSpec
forall a. (a -> ByteStringBuilder) -> ToLog a
build :: DataKeyPairSpec -> ByteStringBuilder
$cbuild :: DataKeyPairSpec -> ByteStringBuilder
Core.ToLog,
HeaderName -> DataKeyPairSpec -> [Header]
(HeaderName -> DataKeyPairSpec -> [Header])
-> ToHeader DataKeyPairSpec
forall a. (HeaderName -> a -> [Header]) -> ToHeader a
toHeader :: HeaderName -> DataKeyPairSpec -> [Header]
$ctoHeader :: HeaderName -> DataKeyPairSpec -> [Header]
Core.ToHeader,
DataKeyPairSpec -> QueryString
(DataKeyPairSpec -> QueryString) -> ToQuery DataKeyPairSpec
forall a. (a -> QueryString) -> ToQuery a
toQuery :: DataKeyPairSpec -> QueryString
$ctoQuery :: DataKeyPairSpec -> QueryString
Core.ToQuery,
Value -> Parser [DataKeyPairSpec]
Value -> Parser DataKeyPairSpec
(Value -> Parser DataKeyPairSpec)
-> (Value -> Parser [DataKeyPairSpec]) -> FromJSON DataKeyPairSpec
forall a.
(Value -> Parser a) -> (Value -> Parser [a]) -> FromJSON a
parseJSONList :: Value -> Parser [DataKeyPairSpec]
$cparseJSONList :: Value -> Parser [DataKeyPairSpec]
parseJSON :: Value -> Parser DataKeyPairSpec
$cparseJSON :: Value -> Parser DataKeyPairSpec
Core.FromJSON,
FromJSONKeyFunction [DataKeyPairSpec]
FromJSONKeyFunction DataKeyPairSpec
FromJSONKeyFunction DataKeyPairSpec
-> FromJSONKeyFunction [DataKeyPairSpec]
-> FromJSONKey DataKeyPairSpec
forall a.
FromJSONKeyFunction a -> FromJSONKeyFunction [a] -> FromJSONKey a
fromJSONKeyList :: FromJSONKeyFunction [DataKeyPairSpec]
$cfromJSONKeyList :: FromJSONKeyFunction [DataKeyPairSpec]
fromJSONKey :: FromJSONKeyFunction DataKeyPairSpec
$cfromJSONKey :: FromJSONKeyFunction DataKeyPairSpec
Core.FromJSONKey,
[DataKeyPairSpec] -> Encoding
[DataKeyPairSpec] -> Value
DataKeyPairSpec -> Encoding
DataKeyPairSpec -> Value
(DataKeyPairSpec -> Value)
-> (DataKeyPairSpec -> Encoding)
-> ([DataKeyPairSpec] -> Value)
-> ([DataKeyPairSpec] -> Encoding)
-> ToJSON DataKeyPairSpec
forall a.
(a -> Value)
-> (a -> Encoding)
-> ([a] -> Value)
-> ([a] -> Encoding)
-> ToJSON a
toEncodingList :: [DataKeyPairSpec] -> Encoding
$ctoEncodingList :: [DataKeyPairSpec] -> Encoding
toJSONList :: [DataKeyPairSpec] -> Value
$ctoJSONList :: [DataKeyPairSpec] -> Value
toEncoding :: DataKeyPairSpec -> Encoding
$ctoEncoding :: DataKeyPairSpec -> Encoding
toJSON :: DataKeyPairSpec -> Value
$ctoJSON :: DataKeyPairSpec -> Value
Core.ToJSON,
ToJSONKeyFunction [DataKeyPairSpec]
ToJSONKeyFunction DataKeyPairSpec
ToJSONKeyFunction DataKeyPairSpec
-> ToJSONKeyFunction [DataKeyPairSpec] -> ToJSONKey DataKeyPairSpec
forall a.
ToJSONKeyFunction a -> ToJSONKeyFunction [a] -> ToJSONKey a
toJSONKeyList :: ToJSONKeyFunction [DataKeyPairSpec]
$ctoJSONKeyList :: ToJSONKeyFunction [DataKeyPairSpec]
toJSONKey :: ToJSONKeyFunction DataKeyPairSpec
$ctoJSONKey :: ToJSONKeyFunction DataKeyPairSpec
Core.ToJSONKey,
[Node] -> Either String DataKeyPairSpec
([Node] -> Either String DataKeyPairSpec)
-> FromXML DataKeyPairSpec
forall a. ([Node] -> Either String a) -> FromXML a
parseXML :: [Node] -> Either String DataKeyPairSpec
$cparseXML :: [Node] -> Either String DataKeyPairSpec
Core.FromXML,
DataKeyPairSpec -> XML
(DataKeyPairSpec -> XML) -> ToXML DataKeyPairSpec
forall a. (a -> XML) -> ToXML a
toXML :: DataKeyPairSpec -> XML
$ctoXML :: DataKeyPairSpec -> XML
Core.ToXML
)
pattern DataKeyPairSpec_ECC_NIST_P256 :: DataKeyPairSpec
pattern $bDataKeyPairSpec_ECC_NIST_P256 :: DataKeyPairSpec
$mDataKeyPairSpec_ECC_NIST_P256 :: forall r. DataKeyPairSpec -> (Void# -> r) -> (Void# -> r) -> r
DataKeyPairSpec_ECC_NIST_P256 = DataKeyPairSpec' "ECC_NIST_P256"
pattern DataKeyPairSpec_ECC_NIST_P384 :: DataKeyPairSpec
pattern $bDataKeyPairSpec_ECC_NIST_P384 :: DataKeyPairSpec
$mDataKeyPairSpec_ECC_NIST_P384 :: forall r. DataKeyPairSpec -> (Void# -> r) -> (Void# -> r) -> r
DataKeyPairSpec_ECC_NIST_P384 = DataKeyPairSpec' "ECC_NIST_P384"
pattern DataKeyPairSpec_ECC_NIST_P521 :: DataKeyPairSpec
pattern $bDataKeyPairSpec_ECC_NIST_P521 :: DataKeyPairSpec
$mDataKeyPairSpec_ECC_NIST_P521 :: forall r. DataKeyPairSpec -> (Void# -> r) -> (Void# -> r) -> r
DataKeyPairSpec_ECC_NIST_P521 = DataKeyPairSpec' "ECC_NIST_P521"
pattern DataKeyPairSpec_ECC_SECG_P256K1 :: DataKeyPairSpec
pattern $bDataKeyPairSpec_ECC_SECG_P256K1 :: DataKeyPairSpec
$mDataKeyPairSpec_ECC_SECG_P256K1 :: forall r. DataKeyPairSpec -> (Void# -> r) -> (Void# -> r) -> r
DataKeyPairSpec_ECC_SECG_P256K1 = DataKeyPairSpec' "ECC_SECG_P256K1"
pattern DataKeyPairSpec_RSA_2048 :: DataKeyPairSpec
pattern $bDataKeyPairSpec_RSA_2048 :: DataKeyPairSpec
$mDataKeyPairSpec_RSA_2048 :: forall r. DataKeyPairSpec -> (Void# -> r) -> (Void# -> r) -> r
DataKeyPairSpec_RSA_2048 = DataKeyPairSpec' "RSA_2048"
pattern DataKeyPairSpec_RSA_3072 :: DataKeyPairSpec
pattern $bDataKeyPairSpec_RSA_3072 :: DataKeyPairSpec
$mDataKeyPairSpec_RSA_3072 :: forall r. DataKeyPairSpec -> (Void# -> r) -> (Void# -> r) -> r
DataKeyPairSpec_RSA_3072 = DataKeyPairSpec' "RSA_3072"
pattern DataKeyPairSpec_RSA_4096 :: DataKeyPairSpec
pattern $bDataKeyPairSpec_RSA_4096 :: DataKeyPairSpec
$mDataKeyPairSpec_RSA_4096 :: forall r. DataKeyPairSpec -> (Void# -> r) -> (Void# -> r) -> r
DataKeyPairSpec_RSA_4096 = DataKeyPairSpec' "RSA_4096"
{-# COMPLETE
DataKeyPairSpec_ECC_NIST_P256,
DataKeyPairSpec_ECC_NIST_P384,
DataKeyPairSpec_ECC_NIST_P521,
DataKeyPairSpec_ECC_SECG_P256K1,
DataKeyPairSpec_RSA_2048,
DataKeyPairSpec_RSA_3072,
DataKeyPairSpec_RSA_4096,
DataKeyPairSpec'
#-}