{-# 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.MediaPackage.Types.StreamOrder
-- 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.MediaPackage.Types.StreamOrder
  ( StreamOrder
      ( ..,
        StreamOrder_ORIGINAL,
        StreamOrder_VIDEO_BITRATE_ASCENDING,
        StreamOrder_VIDEO_BITRATE_DESCENDING
      ),
  )
where

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

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

pattern StreamOrder_ORIGINAL :: StreamOrder
pattern $bStreamOrder_ORIGINAL :: StreamOrder
$mStreamOrder_ORIGINAL :: forall r. StreamOrder -> (Void# -> r) -> (Void# -> r) -> r
StreamOrder_ORIGINAL = StreamOrder' "ORIGINAL"

pattern StreamOrder_VIDEO_BITRATE_ASCENDING :: StreamOrder
pattern $bStreamOrder_VIDEO_BITRATE_ASCENDING :: StreamOrder
$mStreamOrder_VIDEO_BITRATE_ASCENDING :: forall r. StreamOrder -> (Void# -> r) -> (Void# -> r) -> r
StreamOrder_VIDEO_BITRATE_ASCENDING = StreamOrder' "VIDEO_BITRATE_ASCENDING"

pattern StreamOrder_VIDEO_BITRATE_DESCENDING :: StreamOrder
pattern $bStreamOrder_VIDEO_BITRATE_DESCENDING :: StreamOrder
$mStreamOrder_VIDEO_BITRATE_DESCENDING :: forall r. StreamOrder -> (Void# -> r) -> (Void# -> r) -> r
StreamOrder_VIDEO_BITRATE_DESCENDING = StreamOrder' "VIDEO_BITRATE_DESCENDING"

{-# COMPLETE
  StreamOrder_ORIGINAL,
  StreamOrder_VIDEO_BITRATE_ASCENDING,
  StreamOrder_VIDEO_BITRATE_DESCENDING,
  StreamOrder'
  #-}