{-# 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.ECRPublic.Types.LayerFailureCode
-- 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.ECRPublic.Types.LayerFailureCode
  ( LayerFailureCode
      ( ..,
        LayerFailureCode_InvalidLayerDigest,
        LayerFailureCode_MissingLayerDigest
      ),
  )
where

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

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

pattern LayerFailureCode_InvalidLayerDigest :: LayerFailureCode
pattern $bLayerFailureCode_InvalidLayerDigest :: LayerFailureCode
$mLayerFailureCode_InvalidLayerDigest :: forall r. LayerFailureCode -> (Void# -> r) -> (Void# -> r) -> r
LayerFailureCode_InvalidLayerDigest = LayerFailureCode' "InvalidLayerDigest"

pattern LayerFailureCode_MissingLayerDigest :: LayerFailureCode
pattern $bLayerFailureCode_MissingLayerDigest :: LayerFailureCode
$mLayerFailureCode_MissingLayerDigest :: forall r. LayerFailureCode -> (Void# -> r) -> (Void# -> r) -> r
LayerFailureCode_MissingLayerDigest = LayerFailureCode' "MissingLayerDigest"

{-# COMPLETE
  LayerFailureCode_InvalidLayerDigest,
  LayerFailureCode_MissingLayerDigest,
  LayerFailureCode'
  #-}