{-# 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.FraudDetector.Types.DataType
-- 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.FraudDetector.Types.DataType
  ( DataType
      ( ..,
        DataType_BOOLEAN,
        DataType_FLOAT,
        DataType_INTEGER,
        DataType_STRING
      ),
  )
where

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

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

pattern DataType_BOOLEAN :: DataType
pattern $bDataType_BOOLEAN :: DataType
$mDataType_BOOLEAN :: forall r. DataType -> (Void# -> r) -> (Void# -> r) -> r
DataType_BOOLEAN = DataType' "BOOLEAN"

pattern DataType_FLOAT :: DataType
pattern $bDataType_FLOAT :: DataType
$mDataType_FLOAT :: forall r. DataType -> (Void# -> r) -> (Void# -> r) -> r
DataType_FLOAT = DataType' "FLOAT"

pattern DataType_INTEGER :: DataType
pattern $bDataType_INTEGER :: DataType
$mDataType_INTEGER :: forall r. DataType -> (Void# -> r) -> (Void# -> r) -> r
DataType_INTEGER = DataType' "INTEGER"

pattern DataType_STRING :: DataType
pattern $bDataType_STRING :: DataType
$mDataType_STRING :: forall r. DataType -> (Void# -> r) -> (Void# -> r) -> r
DataType_STRING = DataType' "STRING"

{-# COMPLETE
  DataType_BOOLEAN,
  DataType_FLOAT,
  DataType_INTEGER,
  DataType_STRING,
  DataType'
  #-}