{-# 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.MacieV2.Types.DayOfWeek
-- 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.MacieV2.Types.DayOfWeek
  ( DayOfWeek
      ( ..,
        DayOfWeek_FRIDAY,
        DayOfWeek_MONDAY,
        DayOfWeek_SATURDAY,
        DayOfWeek_SUNDAY,
        DayOfWeek_THURSDAY,
        DayOfWeek_TUESDAY,
        DayOfWeek_WEDNESDAY
      ),
  )
where

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

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

pattern DayOfWeek_FRIDAY :: DayOfWeek
pattern $bDayOfWeek_FRIDAY :: DayOfWeek
$mDayOfWeek_FRIDAY :: forall r. DayOfWeek -> (Void# -> r) -> (Void# -> r) -> r
DayOfWeek_FRIDAY = DayOfWeek' "FRIDAY"

pattern DayOfWeek_MONDAY :: DayOfWeek
pattern $bDayOfWeek_MONDAY :: DayOfWeek
$mDayOfWeek_MONDAY :: forall r. DayOfWeek -> (Void# -> r) -> (Void# -> r) -> r
DayOfWeek_MONDAY = DayOfWeek' "MONDAY"

pattern DayOfWeek_SATURDAY :: DayOfWeek
pattern $bDayOfWeek_SATURDAY :: DayOfWeek
$mDayOfWeek_SATURDAY :: forall r. DayOfWeek -> (Void# -> r) -> (Void# -> r) -> r
DayOfWeek_SATURDAY = DayOfWeek' "SATURDAY"

pattern DayOfWeek_SUNDAY :: DayOfWeek
pattern $bDayOfWeek_SUNDAY :: DayOfWeek
$mDayOfWeek_SUNDAY :: forall r. DayOfWeek -> (Void# -> r) -> (Void# -> r) -> r
DayOfWeek_SUNDAY = DayOfWeek' "SUNDAY"

pattern DayOfWeek_THURSDAY :: DayOfWeek
pattern $bDayOfWeek_THURSDAY :: DayOfWeek
$mDayOfWeek_THURSDAY :: forall r. DayOfWeek -> (Void# -> r) -> (Void# -> r) -> r
DayOfWeek_THURSDAY = DayOfWeek' "THURSDAY"

pattern DayOfWeek_TUESDAY :: DayOfWeek
pattern $bDayOfWeek_TUESDAY :: DayOfWeek
$mDayOfWeek_TUESDAY :: forall r. DayOfWeek -> (Void# -> r) -> (Void# -> r) -> r
DayOfWeek_TUESDAY = DayOfWeek' "TUESDAY"

pattern DayOfWeek_WEDNESDAY :: DayOfWeek
pattern $bDayOfWeek_WEDNESDAY :: DayOfWeek
$mDayOfWeek_WEDNESDAY :: forall r. DayOfWeek -> (Void# -> r) -> (Void# -> r) -> r
DayOfWeek_WEDNESDAY = DayOfWeek' "WEDNESDAY"

{-# COMPLETE
  DayOfWeek_FRIDAY,
  DayOfWeek_MONDAY,
  DayOfWeek_SATURDAY,
  DayOfWeek_SUNDAY,
  DayOfWeek_THURSDAY,
  DayOfWeek_TUESDAY,
  DayOfWeek_WEDNESDAY,
  DayOfWeek'
  #-}