{-# 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.DynamoDB.Types.ConditionalOperator
-- 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.DynamoDB.Types.ConditionalOperator
  ( ConditionalOperator
      ( ..,
        ConditionalOperator_AND,
        ConditionalOperator_OR
      ),
  )
where

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

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

pattern ConditionalOperator_AND :: ConditionalOperator
pattern $bConditionalOperator_AND :: ConditionalOperator
$mConditionalOperator_AND :: forall r. ConditionalOperator -> (Void# -> r) -> (Void# -> r) -> r
ConditionalOperator_AND = ConditionalOperator' "AND"

pattern ConditionalOperator_OR :: ConditionalOperator
pattern $bConditionalOperator_OR :: ConditionalOperator
$mConditionalOperator_OR :: forall r. ConditionalOperator -> (Void# -> r) -> (Void# -> r) -> r
ConditionalOperator_OR = ConditionalOperator' "OR"

{-# COMPLETE
  ConditionalOperator_AND,
  ConditionalOperator_OR,
  ConditionalOperator'
  #-}