{-# 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.DMS.Types.AuthTypeValue
-- 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.DMS.Types.AuthTypeValue
  ( AuthTypeValue
      ( ..,
        AuthTypeValue_No,
        AuthTypeValue_Password
      ),
  )
where

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

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

pattern AuthTypeValue_No :: AuthTypeValue
pattern $bAuthTypeValue_No :: AuthTypeValue
$mAuthTypeValue_No :: forall r. AuthTypeValue -> (Void# -> r) -> (Void# -> r) -> r
AuthTypeValue_No = AuthTypeValue' "no"

pattern AuthTypeValue_Password :: AuthTypeValue
pattern $bAuthTypeValue_Password :: AuthTypeValue
$mAuthTypeValue_Password :: forall r. AuthTypeValue -> (Void# -> r) -> (Void# -> r) -> r
AuthTypeValue_Password = AuthTypeValue' "password"

{-# COMPLETE
  AuthTypeValue_No,
  AuthTypeValue_Password,
  AuthTypeValue'
  #-}