{-# 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.Lightsail.Types.ContainerServiceState
-- 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.Lightsail.Types.ContainerServiceState
  ( ContainerServiceState
      ( ..,
        ContainerServiceState_DELETING,
        ContainerServiceState_DEPLOYING,
        ContainerServiceState_DISABLED,
        ContainerServiceState_PENDING,
        ContainerServiceState_READY,
        ContainerServiceState_RUNNING,
        ContainerServiceState_UPDATING
      ),
  )
where

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

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

pattern ContainerServiceState_DELETING :: ContainerServiceState
pattern $bContainerServiceState_DELETING :: ContainerServiceState
$mContainerServiceState_DELETING :: forall r.
ContainerServiceState -> (Void# -> r) -> (Void# -> r) -> r
ContainerServiceState_DELETING = ContainerServiceState' "DELETING"

pattern ContainerServiceState_DEPLOYING :: ContainerServiceState
pattern $bContainerServiceState_DEPLOYING :: ContainerServiceState
$mContainerServiceState_DEPLOYING :: forall r.
ContainerServiceState -> (Void# -> r) -> (Void# -> r) -> r
ContainerServiceState_DEPLOYING = ContainerServiceState' "DEPLOYING"

pattern ContainerServiceState_DISABLED :: ContainerServiceState
pattern $bContainerServiceState_DISABLED :: ContainerServiceState
$mContainerServiceState_DISABLED :: forall r.
ContainerServiceState -> (Void# -> r) -> (Void# -> r) -> r
ContainerServiceState_DISABLED = ContainerServiceState' "DISABLED"

pattern ContainerServiceState_PENDING :: ContainerServiceState
pattern $bContainerServiceState_PENDING :: ContainerServiceState
$mContainerServiceState_PENDING :: forall r.
ContainerServiceState -> (Void# -> r) -> (Void# -> r) -> r
ContainerServiceState_PENDING = ContainerServiceState' "PENDING"

pattern ContainerServiceState_READY :: ContainerServiceState
pattern $bContainerServiceState_READY :: ContainerServiceState
$mContainerServiceState_READY :: forall r.
ContainerServiceState -> (Void# -> r) -> (Void# -> r) -> r
ContainerServiceState_READY = ContainerServiceState' "READY"

pattern ContainerServiceState_RUNNING :: ContainerServiceState
pattern $bContainerServiceState_RUNNING :: ContainerServiceState
$mContainerServiceState_RUNNING :: forall r.
ContainerServiceState -> (Void# -> r) -> (Void# -> r) -> r
ContainerServiceState_RUNNING = ContainerServiceState' "RUNNING"

pattern ContainerServiceState_UPDATING :: ContainerServiceState
pattern $bContainerServiceState_UPDATING :: ContainerServiceState
$mContainerServiceState_UPDATING :: forall r.
ContainerServiceState -> (Void# -> r) -> (Void# -> r) -> r
ContainerServiceState_UPDATING = ContainerServiceState' "UPDATING"

{-# COMPLETE
  ContainerServiceState_DELETING,
  ContainerServiceState_DEPLOYING,
  ContainerServiceState_DISABLED,
  ContainerServiceState_PENDING,
  ContainerServiceState_READY,
  ContainerServiceState_RUNNING,
  ContainerServiceState_UPDATING,
  ContainerServiceState'
  #-}