{-# 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.CognitoIdentityProvider.Types.RiskDecisionType
-- 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.CognitoIdentityProvider.Types.RiskDecisionType
  ( RiskDecisionType
      ( ..,
        RiskDecisionType_AccountTakeover,
        RiskDecisionType_Block,
        RiskDecisionType_NoRisk
      ),
  )
where

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

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

pattern RiskDecisionType_AccountTakeover :: RiskDecisionType
pattern $bRiskDecisionType_AccountTakeover :: RiskDecisionType
$mRiskDecisionType_AccountTakeover :: forall r. RiskDecisionType -> (Void# -> r) -> (Void# -> r) -> r
RiskDecisionType_AccountTakeover = RiskDecisionType' "AccountTakeover"

pattern RiskDecisionType_Block :: RiskDecisionType
pattern $bRiskDecisionType_Block :: RiskDecisionType
$mRiskDecisionType_Block :: forall r. RiskDecisionType -> (Void# -> r) -> (Void# -> r) -> r
RiskDecisionType_Block = RiskDecisionType' "Block"

pattern RiskDecisionType_NoRisk :: RiskDecisionType
pattern $bRiskDecisionType_NoRisk :: RiskDecisionType
$mRiskDecisionType_NoRisk :: forall r. RiskDecisionType -> (Void# -> r) -> (Void# -> r) -> r
RiskDecisionType_NoRisk = RiskDecisionType' "NoRisk"

{-# COMPLETE
  RiskDecisionType_AccountTakeover,
  RiskDecisionType_Block,
  RiskDecisionType_NoRisk,
  RiskDecisionType'
  #-}