{-# 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.IoTEventsData.Types.AlarmStateName
-- 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.IoTEventsData.Types.AlarmStateName
  ( AlarmStateName
      ( ..,
        AlarmStateName_ACKNOWLEDGED,
        AlarmStateName_ACTIVE,
        AlarmStateName_DISABLED,
        AlarmStateName_LATCHED,
        AlarmStateName_NORMAL,
        AlarmStateName_SNOOZE_DISABLED
      ),
  )
where

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

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

pattern AlarmStateName_ACKNOWLEDGED :: AlarmStateName
pattern $bAlarmStateName_ACKNOWLEDGED :: AlarmStateName
$mAlarmStateName_ACKNOWLEDGED :: forall r. AlarmStateName -> (Void# -> r) -> (Void# -> r) -> r
AlarmStateName_ACKNOWLEDGED = AlarmStateName' "ACKNOWLEDGED"

pattern AlarmStateName_ACTIVE :: AlarmStateName
pattern $bAlarmStateName_ACTIVE :: AlarmStateName
$mAlarmStateName_ACTIVE :: forall r. AlarmStateName -> (Void# -> r) -> (Void# -> r) -> r
AlarmStateName_ACTIVE = AlarmStateName' "ACTIVE"

pattern AlarmStateName_DISABLED :: AlarmStateName
pattern $bAlarmStateName_DISABLED :: AlarmStateName
$mAlarmStateName_DISABLED :: forall r. AlarmStateName -> (Void# -> r) -> (Void# -> r) -> r
AlarmStateName_DISABLED = AlarmStateName' "DISABLED"

pattern AlarmStateName_LATCHED :: AlarmStateName
pattern $bAlarmStateName_LATCHED :: AlarmStateName
$mAlarmStateName_LATCHED :: forall r. AlarmStateName -> (Void# -> r) -> (Void# -> r) -> r
AlarmStateName_LATCHED = AlarmStateName' "LATCHED"

pattern AlarmStateName_NORMAL :: AlarmStateName
pattern $bAlarmStateName_NORMAL :: AlarmStateName
$mAlarmStateName_NORMAL :: forall r. AlarmStateName -> (Void# -> r) -> (Void# -> r) -> r
AlarmStateName_NORMAL = AlarmStateName' "NORMAL"

pattern AlarmStateName_SNOOZE_DISABLED :: AlarmStateName
pattern $bAlarmStateName_SNOOZE_DISABLED :: AlarmStateName
$mAlarmStateName_SNOOZE_DISABLED :: forall r. AlarmStateName -> (Void# -> r) -> (Void# -> r) -> r
AlarmStateName_SNOOZE_DISABLED = AlarmStateName' "SNOOZE_DISABLED"

{-# COMPLETE
  AlarmStateName_ACKNOWLEDGED,
  AlarmStateName_ACTIVE,
  AlarmStateName_DISABLED,
  AlarmStateName_LATCHED,
  AlarmStateName_NORMAL,
  AlarmStateName_SNOOZE_DISABLED,
  AlarmStateName'
  #-}