{-# 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.Synthetics.Types.CanaryState
-- 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.Synthetics.Types.CanaryState
  ( CanaryState
      ( ..,
        CanaryState_CREATING,
        CanaryState_DELETING,
        CanaryState_ERROR,
        CanaryState_READY,
        CanaryState_RUNNING,
        CanaryState_STARTING,
        CanaryState_STOPPED,
        CanaryState_STOPPING,
        CanaryState_UPDATING
      ),
  )
where

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

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

pattern CanaryState_CREATING :: CanaryState
pattern $bCanaryState_CREATING :: CanaryState
$mCanaryState_CREATING :: forall r. CanaryState -> (Void# -> r) -> (Void# -> r) -> r
CanaryState_CREATING = CanaryState' "CREATING"

pattern CanaryState_DELETING :: CanaryState
pattern $bCanaryState_DELETING :: CanaryState
$mCanaryState_DELETING :: forall r. CanaryState -> (Void# -> r) -> (Void# -> r) -> r
CanaryState_DELETING = CanaryState' "DELETING"

pattern CanaryState_ERROR :: CanaryState
pattern $bCanaryState_ERROR :: CanaryState
$mCanaryState_ERROR :: forall r. CanaryState -> (Void# -> r) -> (Void# -> r) -> r
CanaryState_ERROR = CanaryState' "ERROR"

pattern CanaryState_READY :: CanaryState
pattern $bCanaryState_READY :: CanaryState
$mCanaryState_READY :: forall r. CanaryState -> (Void# -> r) -> (Void# -> r) -> r
CanaryState_READY = CanaryState' "READY"

pattern CanaryState_RUNNING :: CanaryState
pattern $bCanaryState_RUNNING :: CanaryState
$mCanaryState_RUNNING :: forall r. CanaryState -> (Void# -> r) -> (Void# -> r) -> r
CanaryState_RUNNING = CanaryState' "RUNNING"

pattern CanaryState_STARTING :: CanaryState
pattern $bCanaryState_STARTING :: CanaryState
$mCanaryState_STARTING :: forall r. CanaryState -> (Void# -> r) -> (Void# -> r) -> r
CanaryState_STARTING = CanaryState' "STARTING"

pattern CanaryState_STOPPED :: CanaryState
pattern $bCanaryState_STOPPED :: CanaryState
$mCanaryState_STOPPED :: forall r. CanaryState -> (Void# -> r) -> (Void# -> r) -> r
CanaryState_STOPPED = CanaryState' "STOPPED"

pattern CanaryState_STOPPING :: CanaryState
pattern $bCanaryState_STOPPING :: CanaryState
$mCanaryState_STOPPING :: forall r. CanaryState -> (Void# -> r) -> (Void# -> r) -> r
CanaryState_STOPPING = CanaryState' "STOPPING"

pattern CanaryState_UPDATING :: CanaryState
pattern $bCanaryState_UPDATING :: CanaryState
$mCanaryState_UPDATING :: forall r. CanaryState -> (Void# -> r) -> (Void# -> r) -> r
CanaryState_UPDATING = CanaryState' "UPDATING"

{-# COMPLETE
  CanaryState_CREATING,
  CanaryState_DELETING,
  CanaryState_ERROR,
  CanaryState_READY,
  CanaryState_RUNNING,
  CanaryState_STARTING,
  CanaryState_STOPPED,
  CanaryState_STOPPING,
  CanaryState_UPDATING,
  CanaryState'
  #-}