{-# 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.Route53RecoveryReadiness.Types.Readiness
-- 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.Route53RecoveryReadiness.Types.Readiness
  ( Readiness
      ( ..,
        Readiness_NOT_AUTHORIZED,
        Readiness_NOT_READY,
        Readiness_READY,
        Readiness_UNKNOWN
      ),
  )
where

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

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

pattern Readiness_NOT_AUTHORIZED :: Readiness
pattern $bReadiness_NOT_AUTHORIZED :: Readiness
$mReadiness_NOT_AUTHORIZED :: forall r. Readiness -> (Void# -> r) -> (Void# -> r) -> r
Readiness_NOT_AUTHORIZED = Readiness' "NOT_AUTHORIZED"

pattern Readiness_NOT_READY :: Readiness
pattern $bReadiness_NOT_READY :: Readiness
$mReadiness_NOT_READY :: forall r. Readiness -> (Void# -> r) -> (Void# -> r) -> r
Readiness_NOT_READY = Readiness' "NOT_READY"

pattern Readiness_READY :: Readiness
pattern $bReadiness_READY :: Readiness
$mReadiness_READY :: forall r. Readiness -> (Void# -> r) -> (Void# -> r) -> r
Readiness_READY = Readiness' "READY"

pattern Readiness_UNKNOWN :: Readiness
pattern $bReadiness_UNKNOWN :: Readiness
$mReadiness_UNKNOWN :: forall r. Readiness -> (Void# -> r) -> (Void# -> r) -> r
Readiness_UNKNOWN = Readiness' "UNKNOWN"

{-# COMPLETE
  Readiness_NOT_AUTHORIZED,
  Readiness_NOT_READY,
  Readiness_READY,
  Readiness_UNKNOWN,
  Readiness'
  #-}