{-# 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.ElasticSearch.Types.TLSSecurityPolicy
-- 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.ElasticSearch.Types.TLSSecurityPolicy
  ( TLSSecurityPolicy
      ( ..,
        TLSSecurityPolicy_Policy_Min_TLS_1_0_2019_07,
        TLSSecurityPolicy_Policy_Min_TLS_1_2_2019_07
      ),
  )
where

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

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

pattern TLSSecurityPolicy_Policy_Min_TLS_1_0_2019_07 :: TLSSecurityPolicy
pattern $bTLSSecurityPolicy_Policy_Min_TLS_1_0_2019_07 :: TLSSecurityPolicy
$mTLSSecurityPolicy_Policy_Min_TLS_1_0_2019_07 :: forall r. TLSSecurityPolicy -> (Void# -> r) -> (Void# -> r) -> r
TLSSecurityPolicy_Policy_Min_TLS_1_0_2019_07 = TLSSecurityPolicy' "Policy-Min-TLS-1-0-2019-07"

pattern TLSSecurityPolicy_Policy_Min_TLS_1_2_2019_07 :: TLSSecurityPolicy
pattern $bTLSSecurityPolicy_Policy_Min_TLS_1_2_2019_07 :: TLSSecurityPolicy
$mTLSSecurityPolicy_Policy_Min_TLS_1_2_2019_07 :: forall r. TLSSecurityPolicy -> (Void# -> r) -> (Void# -> r) -> r
TLSSecurityPolicy_Policy_Min_TLS_1_2_2019_07 = TLSSecurityPolicy' "Policy-Min-TLS-1-2-2019-07"

{-# COMPLETE
  TLSSecurityPolicy_Policy_Min_TLS_1_0_2019_07,
  TLSSecurityPolicy_Policy_Min_TLS_1_2_2019_07,
  TLSSecurityPolicy'
  #-}