{-# 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.Redshift.Types.TableRestoreStatusType
-- 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.Redshift.Types.TableRestoreStatusType
  ( TableRestoreStatusType
      ( ..,
        TableRestoreStatusType_CANCELED,
        TableRestoreStatusType_FAILED,
        TableRestoreStatusType_IN_PROGRESS,
        TableRestoreStatusType_PENDING,
        TableRestoreStatusType_SUCCEEDED
      ),
  )
where

import qualified Amazonka.Core as Core
import qualified Amazonka.Prelude as Prelude
import Amazonka.Redshift.Internal

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

pattern TableRestoreStatusType_CANCELED :: TableRestoreStatusType
pattern $bTableRestoreStatusType_CANCELED :: TableRestoreStatusType
$mTableRestoreStatusType_CANCELED :: forall r.
TableRestoreStatusType -> (Void# -> r) -> (Void# -> r) -> r
TableRestoreStatusType_CANCELED = TableRestoreStatusType' "CANCELED"

pattern TableRestoreStatusType_FAILED :: TableRestoreStatusType
pattern $bTableRestoreStatusType_FAILED :: TableRestoreStatusType
$mTableRestoreStatusType_FAILED :: forall r.
TableRestoreStatusType -> (Void# -> r) -> (Void# -> r) -> r
TableRestoreStatusType_FAILED = TableRestoreStatusType' "FAILED"

pattern TableRestoreStatusType_IN_PROGRESS :: TableRestoreStatusType
pattern $bTableRestoreStatusType_IN_PROGRESS :: TableRestoreStatusType
$mTableRestoreStatusType_IN_PROGRESS :: forall r.
TableRestoreStatusType -> (Void# -> r) -> (Void# -> r) -> r
TableRestoreStatusType_IN_PROGRESS = TableRestoreStatusType' "IN_PROGRESS"

pattern TableRestoreStatusType_PENDING :: TableRestoreStatusType
pattern $bTableRestoreStatusType_PENDING :: TableRestoreStatusType
$mTableRestoreStatusType_PENDING :: forall r.
TableRestoreStatusType -> (Void# -> r) -> (Void# -> r) -> r
TableRestoreStatusType_PENDING = TableRestoreStatusType' "PENDING"

pattern TableRestoreStatusType_SUCCEEDED :: TableRestoreStatusType
pattern $bTableRestoreStatusType_SUCCEEDED :: TableRestoreStatusType
$mTableRestoreStatusType_SUCCEEDED :: forall r.
TableRestoreStatusType -> (Void# -> r) -> (Void# -> r) -> r
TableRestoreStatusType_SUCCEEDED = TableRestoreStatusType' "SUCCEEDED"

{-# COMPLETE
  TableRestoreStatusType_CANCELED,
  TableRestoreStatusType_FAILED,
  TableRestoreStatusType_IN_PROGRESS,
  TableRestoreStatusType_PENDING,
  TableRestoreStatusType_SUCCEEDED,
  TableRestoreStatusType'
  #-}