{-# 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.ElastiCache.Types.NodeUpdateStatus
-- 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.ElastiCache.Types.NodeUpdateStatus
  ( NodeUpdateStatus
      ( ..,
        NodeUpdateStatus_Complete,
        NodeUpdateStatus_In_progress,
        NodeUpdateStatus_Not_applied,
        NodeUpdateStatus_Stopped,
        NodeUpdateStatus_Stopping,
        NodeUpdateStatus_Waiting_to_start
      ),
  )
where

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

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

pattern NodeUpdateStatus_Complete :: NodeUpdateStatus
pattern $bNodeUpdateStatus_Complete :: NodeUpdateStatus
$mNodeUpdateStatus_Complete :: forall r. NodeUpdateStatus -> (Void# -> r) -> (Void# -> r) -> r
NodeUpdateStatus_Complete = NodeUpdateStatus' "complete"

pattern NodeUpdateStatus_In_progress :: NodeUpdateStatus
pattern $bNodeUpdateStatus_In_progress :: NodeUpdateStatus
$mNodeUpdateStatus_In_progress :: forall r. NodeUpdateStatus -> (Void# -> r) -> (Void# -> r) -> r
NodeUpdateStatus_In_progress = NodeUpdateStatus' "in-progress"

pattern NodeUpdateStatus_Not_applied :: NodeUpdateStatus
pattern $bNodeUpdateStatus_Not_applied :: NodeUpdateStatus
$mNodeUpdateStatus_Not_applied :: forall r. NodeUpdateStatus -> (Void# -> r) -> (Void# -> r) -> r
NodeUpdateStatus_Not_applied = NodeUpdateStatus' "not-applied"

pattern NodeUpdateStatus_Stopped :: NodeUpdateStatus
pattern $bNodeUpdateStatus_Stopped :: NodeUpdateStatus
$mNodeUpdateStatus_Stopped :: forall r. NodeUpdateStatus -> (Void# -> r) -> (Void# -> r) -> r
NodeUpdateStatus_Stopped = NodeUpdateStatus' "stopped"

pattern NodeUpdateStatus_Stopping :: NodeUpdateStatus
pattern $bNodeUpdateStatus_Stopping :: NodeUpdateStatus
$mNodeUpdateStatus_Stopping :: forall r. NodeUpdateStatus -> (Void# -> r) -> (Void# -> r) -> r
NodeUpdateStatus_Stopping = NodeUpdateStatus' "stopping"

pattern NodeUpdateStatus_Waiting_to_start :: NodeUpdateStatus
pattern $bNodeUpdateStatus_Waiting_to_start :: NodeUpdateStatus
$mNodeUpdateStatus_Waiting_to_start :: forall r. NodeUpdateStatus -> (Void# -> r) -> (Void# -> r) -> r
NodeUpdateStatus_Waiting_to_start = NodeUpdateStatus' "waiting-to-start"

{-# COMPLETE
  NodeUpdateStatus_Complete,
  NodeUpdateStatus_In_progress,
  NodeUpdateStatus_Not_applied,
  NodeUpdateStatus_Stopped,
  NodeUpdateStatus_Stopping,
  NodeUpdateStatus_Waiting_to_start,
  NodeUpdateStatus'
  #-}