{-# 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.QuickSight.Types.RelativeDateType
-- 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.QuickSight.Types.RelativeDateType
  ( RelativeDateType
      ( ..,
        RelativeDateType_LAST,
        RelativeDateType_NEXT,
        RelativeDateType_NOW,
        RelativeDateType_PREVIOUS,
        RelativeDateType_THIS
      ),
  )
where

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

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

pattern RelativeDateType_LAST :: RelativeDateType
pattern $bRelativeDateType_LAST :: RelativeDateType
$mRelativeDateType_LAST :: forall {r}. RelativeDateType -> ((# #) -> r) -> ((# #) -> r) -> r
RelativeDateType_LAST = RelativeDateType' "LAST"

pattern RelativeDateType_NEXT :: RelativeDateType
pattern $bRelativeDateType_NEXT :: RelativeDateType
$mRelativeDateType_NEXT :: forall {r}. RelativeDateType -> ((# #) -> r) -> ((# #) -> r) -> r
RelativeDateType_NEXT = RelativeDateType' "NEXT"

pattern RelativeDateType_NOW :: RelativeDateType
pattern $bRelativeDateType_NOW :: RelativeDateType
$mRelativeDateType_NOW :: forall {r}. RelativeDateType -> ((# #) -> r) -> ((# #) -> r) -> r
RelativeDateType_NOW = RelativeDateType' "NOW"

pattern RelativeDateType_PREVIOUS :: RelativeDateType
pattern $bRelativeDateType_PREVIOUS :: RelativeDateType
$mRelativeDateType_PREVIOUS :: forall {r}. RelativeDateType -> ((# #) -> r) -> ((# #) -> r) -> r
RelativeDateType_PREVIOUS = RelativeDateType' "PREVIOUS"

pattern RelativeDateType_THIS :: RelativeDateType
pattern $bRelativeDateType_THIS :: RelativeDateType
$mRelativeDateType_THIS :: forall {r}. RelativeDateType -> ((# #) -> r) -> ((# #) -> r) -> r
RelativeDateType_THIS = RelativeDateType' "THIS"

{-# COMPLETE
  RelativeDateType_LAST,
  RelativeDateType_NEXT,
  RelativeDateType_NOW,
  RelativeDateType_PREVIOUS,
  RelativeDateType_THIS,
  RelativeDateType'
  #-}