{-# 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.MediaConnect.Types.PriceUnits
-- 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.MediaConnect.Types.PriceUnits
  ( PriceUnits
      ( ..,
        PriceUnits_HOURLY
      ),
  )
where

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

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

pattern PriceUnits_HOURLY :: PriceUnits
pattern $bPriceUnits_HOURLY :: PriceUnits
$mPriceUnits_HOURLY :: forall r. PriceUnits -> (Void# -> r) -> (Void# -> r) -> r
PriceUnits_HOURLY = PriceUnits' "HOURLY"

{-# COMPLETE
  PriceUnits_HOURLY,
  PriceUnits'
  #-}