{-# 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.DynamoDBStreams.Types.ShardIteratorType
-- 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.DynamoDBStreams.Types.ShardIteratorType
  ( ShardIteratorType
      ( ..,
        ShardIteratorType_AFTER_SEQUENCE_NUMBER,
        ShardIteratorType_AT_SEQUENCE_NUMBER,
        ShardIteratorType_LATEST,
        ShardIteratorType_TRIM_HORIZON
      ),
  )
where

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

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

pattern ShardIteratorType_AFTER_SEQUENCE_NUMBER :: ShardIteratorType
pattern $bShardIteratorType_AFTER_SEQUENCE_NUMBER :: ShardIteratorType
$mShardIteratorType_AFTER_SEQUENCE_NUMBER :: forall {r}. ShardIteratorType -> ((# #) -> r) -> ((# #) -> r) -> r
ShardIteratorType_AFTER_SEQUENCE_NUMBER = ShardIteratorType' "AFTER_SEQUENCE_NUMBER"

pattern ShardIteratorType_AT_SEQUENCE_NUMBER :: ShardIteratorType
pattern $bShardIteratorType_AT_SEQUENCE_NUMBER :: ShardIteratorType
$mShardIteratorType_AT_SEQUENCE_NUMBER :: forall {r}. ShardIteratorType -> ((# #) -> r) -> ((# #) -> r) -> r
ShardIteratorType_AT_SEQUENCE_NUMBER = ShardIteratorType' "AT_SEQUENCE_NUMBER"

pattern ShardIteratorType_LATEST :: ShardIteratorType
pattern $bShardIteratorType_LATEST :: ShardIteratorType
$mShardIteratorType_LATEST :: forall {r}. ShardIteratorType -> ((# #) -> r) -> ((# #) -> r) -> r
ShardIteratorType_LATEST = ShardIteratorType' "LATEST"

pattern ShardIteratorType_TRIM_HORIZON :: ShardIteratorType
pattern $bShardIteratorType_TRIM_HORIZON :: ShardIteratorType
$mShardIteratorType_TRIM_HORIZON :: forall {r}. ShardIteratorType -> ((# #) -> r) -> ((# #) -> r) -> r
ShardIteratorType_TRIM_HORIZON = ShardIteratorType' "TRIM_HORIZON"

{-# COMPLETE
  ShardIteratorType_AFTER_SEQUENCE_NUMBER,
  ShardIteratorType_AT_SEQUENCE_NUMBER,
  ShardIteratorType_LATEST,
  ShardIteratorType_TRIM_HORIZON,
  ShardIteratorType'
  #-}