{-# 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.MediaLive.Types.ReservationMaximumBitrate
-- 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.MediaLive.Types.ReservationMaximumBitrate
  ( ReservationMaximumBitrate
      ( ..,
        ReservationMaximumBitrate_MAX_10_MBPS,
        ReservationMaximumBitrate_MAX_20_MBPS,
        ReservationMaximumBitrate_MAX_50_MBPS
      ),
  )
where

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

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

pattern ReservationMaximumBitrate_MAX_10_MBPS :: ReservationMaximumBitrate
pattern $bReservationMaximumBitrate_MAX_10_MBPS :: ReservationMaximumBitrate
$mReservationMaximumBitrate_MAX_10_MBPS :: forall r.
ReservationMaximumBitrate -> (Void# -> r) -> (Void# -> r) -> r
ReservationMaximumBitrate_MAX_10_MBPS = ReservationMaximumBitrate' "MAX_10_MBPS"

pattern ReservationMaximumBitrate_MAX_20_MBPS :: ReservationMaximumBitrate
pattern $bReservationMaximumBitrate_MAX_20_MBPS :: ReservationMaximumBitrate
$mReservationMaximumBitrate_MAX_20_MBPS :: forall r.
ReservationMaximumBitrate -> (Void# -> r) -> (Void# -> r) -> r
ReservationMaximumBitrate_MAX_20_MBPS = ReservationMaximumBitrate' "MAX_20_MBPS"

pattern ReservationMaximumBitrate_MAX_50_MBPS :: ReservationMaximumBitrate
pattern $bReservationMaximumBitrate_MAX_50_MBPS :: ReservationMaximumBitrate
$mReservationMaximumBitrate_MAX_50_MBPS :: forall r.
ReservationMaximumBitrate -> (Void# -> r) -> (Void# -> r) -> r
ReservationMaximumBitrate_MAX_50_MBPS = ReservationMaximumBitrate' "MAX_50_MBPS"

{-# COMPLETE
  ReservationMaximumBitrate_MAX_10_MBPS,
  ReservationMaximumBitrate_MAX_20_MBPS,
  ReservationMaximumBitrate_MAX_50_MBPS,
  ReservationMaximumBitrate'
  #-}