{-# 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.ReservedNodeOfferingType
-- 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.ReservedNodeOfferingType
  ( ReservedNodeOfferingType
      ( ..,
        ReservedNodeOfferingType_Regular,
        ReservedNodeOfferingType_Upgradable
      ),
  )
where

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

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

pattern ReservedNodeOfferingType_Regular :: ReservedNodeOfferingType
pattern $bReservedNodeOfferingType_Regular :: ReservedNodeOfferingType
$mReservedNodeOfferingType_Regular :: forall r.
ReservedNodeOfferingType -> (Void# -> r) -> (Void# -> r) -> r
ReservedNodeOfferingType_Regular = ReservedNodeOfferingType' "Regular"

pattern ReservedNodeOfferingType_Upgradable :: ReservedNodeOfferingType
pattern $bReservedNodeOfferingType_Upgradable :: ReservedNodeOfferingType
$mReservedNodeOfferingType_Upgradable :: forall r.
ReservedNodeOfferingType -> (Void# -> r) -> (Void# -> r) -> r
ReservedNodeOfferingType_Upgradable = ReservedNodeOfferingType' "Upgradable"

{-# COMPLETE
  ReservedNodeOfferingType_Regular,
  ReservedNodeOfferingType_Upgradable,
  ReservedNodeOfferingType'
  #-}