{-# 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.Lambda.Types.SourceAccessType
-- Copyright   : (c) 2013-2023 Brendan Hay
-- License     : Mozilla Public License, v. 2.0.
-- Maintainer  : Brendan Hay
-- Stability   : auto-generated
-- Portability : non-portable (GHC extensions)
module Amazonka.Lambda.Types.SourceAccessType
  ( SourceAccessType
      ( ..,
        SourceAccessType_BASIC_AUTH,
        SourceAccessType_CLIENT_CERTIFICATE_TLS_AUTH,
        SourceAccessType_SASL_SCRAM_256_AUTH,
        SourceAccessType_SASL_SCRAM_512_AUTH,
        SourceAccessType_SERVER_ROOT_CA_CERTIFICATE,
        SourceAccessType_VIRTUAL_HOST,
        SourceAccessType_VPC_SECURITY_GROUP,
        SourceAccessType_VPC_SUBNET
      ),
  )
where

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

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

pattern SourceAccessType_BASIC_AUTH :: SourceAccessType
pattern $bSourceAccessType_BASIC_AUTH :: SourceAccessType
$mSourceAccessType_BASIC_AUTH :: forall {r}. SourceAccessType -> ((# #) -> r) -> ((# #) -> r) -> r
SourceAccessType_BASIC_AUTH = SourceAccessType' "BASIC_AUTH"

pattern SourceAccessType_CLIENT_CERTIFICATE_TLS_AUTH :: SourceAccessType
pattern $bSourceAccessType_CLIENT_CERTIFICATE_TLS_AUTH :: SourceAccessType
$mSourceAccessType_CLIENT_CERTIFICATE_TLS_AUTH :: forall {r}. SourceAccessType -> ((# #) -> r) -> ((# #) -> r) -> r
SourceAccessType_CLIENT_CERTIFICATE_TLS_AUTH = SourceAccessType' "CLIENT_CERTIFICATE_TLS_AUTH"

pattern SourceAccessType_SASL_SCRAM_256_AUTH :: SourceAccessType
pattern $bSourceAccessType_SASL_SCRAM_256_AUTH :: SourceAccessType
$mSourceAccessType_SASL_SCRAM_256_AUTH :: forall {r}. SourceAccessType -> ((# #) -> r) -> ((# #) -> r) -> r
SourceAccessType_SASL_SCRAM_256_AUTH = SourceAccessType' "SASL_SCRAM_256_AUTH"

pattern SourceAccessType_SASL_SCRAM_512_AUTH :: SourceAccessType
pattern $bSourceAccessType_SASL_SCRAM_512_AUTH :: SourceAccessType
$mSourceAccessType_SASL_SCRAM_512_AUTH :: forall {r}. SourceAccessType -> ((# #) -> r) -> ((# #) -> r) -> r
SourceAccessType_SASL_SCRAM_512_AUTH = SourceAccessType' "SASL_SCRAM_512_AUTH"

pattern SourceAccessType_SERVER_ROOT_CA_CERTIFICATE :: SourceAccessType
pattern $bSourceAccessType_SERVER_ROOT_CA_CERTIFICATE :: SourceAccessType
$mSourceAccessType_SERVER_ROOT_CA_CERTIFICATE :: forall {r}. SourceAccessType -> ((# #) -> r) -> ((# #) -> r) -> r
SourceAccessType_SERVER_ROOT_CA_CERTIFICATE = SourceAccessType' "SERVER_ROOT_CA_CERTIFICATE"

pattern SourceAccessType_VIRTUAL_HOST :: SourceAccessType
pattern $bSourceAccessType_VIRTUAL_HOST :: SourceAccessType
$mSourceAccessType_VIRTUAL_HOST :: forall {r}. SourceAccessType -> ((# #) -> r) -> ((# #) -> r) -> r
SourceAccessType_VIRTUAL_HOST = SourceAccessType' "VIRTUAL_HOST"

pattern SourceAccessType_VPC_SECURITY_GROUP :: SourceAccessType
pattern $bSourceAccessType_VPC_SECURITY_GROUP :: SourceAccessType
$mSourceAccessType_VPC_SECURITY_GROUP :: forall {r}. SourceAccessType -> ((# #) -> r) -> ((# #) -> r) -> r
SourceAccessType_VPC_SECURITY_GROUP = SourceAccessType' "VPC_SECURITY_GROUP"

pattern SourceAccessType_VPC_SUBNET :: SourceAccessType
pattern $bSourceAccessType_VPC_SUBNET :: SourceAccessType
$mSourceAccessType_VPC_SUBNET :: forall {r}. SourceAccessType -> ((# #) -> r) -> ((# #) -> r) -> r
SourceAccessType_VPC_SUBNET = SourceAccessType' "VPC_SUBNET"

{-# COMPLETE
  SourceAccessType_BASIC_AUTH,
  SourceAccessType_CLIENT_CERTIFICATE_TLS_AUTH,
  SourceAccessType_SASL_SCRAM_256_AUTH,
  SourceAccessType_SASL_SCRAM_512_AUTH,
  SourceAccessType_SERVER_ROOT_CA_CERTIFICATE,
  SourceAccessType_VIRTUAL_HOST,
  SourceAccessType_VPC_SECURITY_GROUP,
  SourceAccessType_VPC_SUBNET,
  SourceAccessType'
  #-}