{-# 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.AWSHealth.Types.EventStatusCode
-- 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.AWSHealth.Types.EventStatusCode
  ( EventStatusCode
      ( ..,
        EventStatusCode_Closed,
        EventStatusCode_Open,
        EventStatusCode_Upcoming
      ),
  )
where

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

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

pattern EventStatusCode_Closed :: EventStatusCode
pattern $bEventStatusCode_Closed :: EventStatusCode
$mEventStatusCode_Closed :: forall r. EventStatusCode -> (Void# -> r) -> (Void# -> r) -> r
EventStatusCode_Closed = EventStatusCode' "closed"

pattern EventStatusCode_Open :: EventStatusCode
pattern $bEventStatusCode_Open :: EventStatusCode
$mEventStatusCode_Open :: forall r. EventStatusCode -> (Void# -> r) -> (Void# -> r) -> r
EventStatusCode_Open = EventStatusCode' "open"

pattern EventStatusCode_Upcoming :: EventStatusCode
pattern $bEventStatusCode_Upcoming :: EventStatusCode
$mEventStatusCode_Upcoming :: forall r. EventStatusCode -> (Void# -> r) -> (Void# -> r) -> r
EventStatusCode_Upcoming = EventStatusCode' "upcoming"

{-# COMPLETE
  EventStatusCode_Closed,
  EventStatusCode_Open,
  EventStatusCode_Upcoming,
  EventStatusCode'
  #-}