{-# 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.Glacier.Types.StatusCode
-- Copyright   : (c) 2013-2023 Brendan Hay
-- License     : Mozilla Public License, v. 2.0.
-- Maintainer  : Brendan Hay
-- Stability   : auto-generated
-- Portability : non-portable (GHC extensions)
module Amazonka.Glacier.Types.StatusCode
  ( StatusCode
      ( ..,
        StatusCode_Failed,
        StatusCode_InProgress,
        StatusCode_Succeeded
      ),
  )
where

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

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

pattern StatusCode_Failed :: StatusCode
pattern $bStatusCode_Failed :: StatusCode
$mStatusCode_Failed :: forall {r}. StatusCode -> ((# #) -> r) -> ((# #) -> r) -> r
StatusCode_Failed = StatusCode' "Failed"

pattern StatusCode_InProgress :: StatusCode
pattern $bStatusCode_InProgress :: StatusCode
$mStatusCode_InProgress :: forall {r}. StatusCode -> ((# #) -> r) -> ((# #) -> r) -> r
StatusCode_InProgress = StatusCode' "InProgress"

pattern StatusCode_Succeeded :: StatusCode
pattern $bStatusCode_Succeeded :: StatusCode
$mStatusCode_Succeeded :: forall {r}. StatusCode -> ((# #) -> r) -> ((# #) -> r) -> r
StatusCode_Succeeded = StatusCode' "Succeeded"

{-# COMPLETE
  StatusCode_Failed,
  StatusCode_InProgress,
  StatusCode_Succeeded,
  StatusCode'
  #-}