{-# 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.MediaConvert.Types.HlsCodecSpecification
-- 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.MediaConvert.Types.HlsCodecSpecification
  ( HlsCodecSpecification
      ( ..,
        HlsCodecSpecification_RFC_4281,
        HlsCodecSpecification_RFC_6381
      ),
  )
where

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

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

pattern HlsCodecSpecification_RFC_4281 :: HlsCodecSpecification
pattern $bHlsCodecSpecification_RFC_4281 :: HlsCodecSpecification
$mHlsCodecSpecification_RFC_4281 :: forall r.
HlsCodecSpecification -> (Void# -> r) -> (Void# -> r) -> r
HlsCodecSpecification_RFC_4281 = HlsCodecSpecification' "RFC_4281"

pattern HlsCodecSpecification_RFC_6381 :: HlsCodecSpecification
pattern $bHlsCodecSpecification_RFC_6381 :: HlsCodecSpecification
$mHlsCodecSpecification_RFC_6381 :: forall r.
HlsCodecSpecification -> (Void# -> r) -> (Void# -> r) -> r
HlsCodecSpecification_RFC_6381 = HlsCodecSpecification' "RFC_6381"

{-# COMPLETE
  HlsCodecSpecification_RFC_4281,
  HlsCodecSpecification_RFC_6381,
  HlsCodecSpecification'
  #-}