{-# 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.M2tsPcrControl
-- 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.M2tsPcrControl
  ( M2tsPcrControl
      ( ..,
        M2tsPcrControl_CONFIGURED_PCR_PERIOD,
        M2tsPcrControl_PCR_EVERY_PES_PACKET
      ),
  )
where

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

-- | When set to PCR_EVERY_PES_PACKET, a Program Clock Reference value is
-- inserted for every Packetized Elementary Stream (PES) header. This is
-- effective only when the PCR PID is the same as the video or audio
-- elementary stream.
newtype M2tsPcrControl = M2tsPcrControl'
  { M2tsPcrControl -> Text
fromM2tsPcrControl ::
      Core.Text
  }
  deriving stock
    ( Int -> M2tsPcrControl -> ShowS
[M2tsPcrControl] -> ShowS
M2tsPcrControl -> String
(Int -> M2tsPcrControl -> ShowS)
-> (M2tsPcrControl -> String)
-> ([M2tsPcrControl] -> ShowS)
-> Show M2tsPcrControl
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [M2tsPcrControl] -> ShowS
$cshowList :: [M2tsPcrControl] -> ShowS
show :: M2tsPcrControl -> String
$cshow :: M2tsPcrControl -> String
showsPrec :: Int -> M2tsPcrControl -> ShowS
$cshowsPrec :: Int -> M2tsPcrControl -> ShowS
Prelude.Show,
      ReadPrec [M2tsPcrControl]
ReadPrec M2tsPcrControl
Int -> ReadS M2tsPcrControl
ReadS [M2tsPcrControl]
(Int -> ReadS M2tsPcrControl)
-> ReadS [M2tsPcrControl]
-> ReadPrec M2tsPcrControl
-> ReadPrec [M2tsPcrControl]
-> Read M2tsPcrControl
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [M2tsPcrControl]
$creadListPrec :: ReadPrec [M2tsPcrControl]
readPrec :: ReadPrec M2tsPcrControl
$creadPrec :: ReadPrec M2tsPcrControl
readList :: ReadS [M2tsPcrControl]
$creadList :: ReadS [M2tsPcrControl]
readsPrec :: Int -> ReadS M2tsPcrControl
$creadsPrec :: Int -> ReadS M2tsPcrControl
Prelude.Read,
      M2tsPcrControl -> M2tsPcrControl -> Bool
(M2tsPcrControl -> M2tsPcrControl -> Bool)
-> (M2tsPcrControl -> M2tsPcrControl -> Bool) -> Eq M2tsPcrControl
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: M2tsPcrControl -> M2tsPcrControl -> Bool
$c/= :: M2tsPcrControl -> M2tsPcrControl -> Bool
== :: M2tsPcrControl -> M2tsPcrControl -> Bool
$c== :: M2tsPcrControl -> M2tsPcrControl -> Bool
Prelude.Eq,
      Eq M2tsPcrControl
Eq M2tsPcrControl
-> (M2tsPcrControl -> M2tsPcrControl -> Ordering)
-> (M2tsPcrControl -> M2tsPcrControl -> Bool)
-> (M2tsPcrControl -> M2tsPcrControl -> Bool)
-> (M2tsPcrControl -> M2tsPcrControl -> Bool)
-> (M2tsPcrControl -> M2tsPcrControl -> Bool)
-> (M2tsPcrControl -> M2tsPcrControl -> M2tsPcrControl)
-> (M2tsPcrControl -> M2tsPcrControl -> M2tsPcrControl)
-> Ord M2tsPcrControl
M2tsPcrControl -> M2tsPcrControl -> Bool
M2tsPcrControl -> M2tsPcrControl -> Ordering
M2tsPcrControl -> M2tsPcrControl -> M2tsPcrControl
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 :: M2tsPcrControl -> M2tsPcrControl -> M2tsPcrControl
$cmin :: M2tsPcrControl -> M2tsPcrControl -> M2tsPcrControl
max :: M2tsPcrControl -> M2tsPcrControl -> M2tsPcrControl
$cmax :: M2tsPcrControl -> M2tsPcrControl -> M2tsPcrControl
>= :: M2tsPcrControl -> M2tsPcrControl -> Bool
$c>= :: M2tsPcrControl -> M2tsPcrControl -> Bool
> :: M2tsPcrControl -> M2tsPcrControl -> Bool
$c> :: M2tsPcrControl -> M2tsPcrControl -> Bool
<= :: M2tsPcrControl -> M2tsPcrControl -> Bool
$c<= :: M2tsPcrControl -> M2tsPcrControl -> Bool
< :: M2tsPcrControl -> M2tsPcrControl -> Bool
$c< :: M2tsPcrControl -> M2tsPcrControl -> Bool
compare :: M2tsPcrControl -> M2tsPcrControl -> Ordering
$ccompare :: M2tsPcrControl -> M2tsPcrControl -> Ordering
$cp1Ord :: Eq M2tsPcrControl
Prelude.Ord,
      (forall x. M2tsPcrControl -> Rep M2tsPcrControl x)
-> (forall x. Rep M2tsPcrControl x -> M2tsPcrControl)
-> Generic M2tsPcrControl
forall x. Rep M2tsPcrControl x -> M2tsPcrControl
forall x. M2tsPcrControl -> Rep M2tsPcrControl x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep M2tsPcrControl x -> M2tsPcrControl
$cfrom :: forall x. M2tsPcrControl -> Rep M2tsPcrControl x
Prelude.Generic
    )
  deriving newtype
    ( Int -> M2tsPcrControl -> Int
M2tsPcrControl -> Int
(Int -> M2tsPcrControl -> Int)
-> (M2tsPcrControl -> Int) -> Hashable M2tsPcrControl
forall a. (Int -> a -> Int) -> (a -> Int) -> Hashable a
hash :: M2tsPcrControl -> Int
$chash :: M2tsPcrControl -> Int
hashWithSalt :: Int -> M2tsPcrControl -> Int
$chashWithSalt :: Int -> M2tsPcrControl -> Int
Prelude.Hashable,
      M2tsPcrControl -> ()
(M2tsPcrControl -> ()) -> NFData M2tsPcrControl
forall a. (a -> ()) -> NFData a
rnf :: M2tsPcrControl -> ()
$crnf :: M2tsPcrControl -> ()
Prelude.NFData,
      Text -> Either String M2tsPcrControl
(Text -> Either String M2tsPcrControl) -> FromText M2tsPcrControl
forall a. (Text -> Either String a) -> FromText a
fromText :: Text -> Either String M2tsPcrControl
$cfromText :: Text -> Either String M2tsPcrControl
Core.FromText,
      M2tsPcrControl -> Text
(M2tsPcrControl -> Text) -> ToText M2tsPcrControl
forall a. (a -> Text) -> ToText a
toText :: M2tsPcrControl -> Text
$ctoText :: M2tsPcrControl -> Text
Core.ToText,
      M2tsPcrControl -> ByteString
(M2tsPcrControl -> ByteString) -> ToByteString M2tsPcrControl
forall a. (a -> ByteString) -> ToByteString a
toBS :: M2tsPcrControl -> ByteString
$ctoBS :: M2tsPcrControl -> ByteString
Core.ToByteString,
      M2tsPcrControl -> ByteStringBuilder
(M2tsPcrControl -> ByteStringBuilder) -> ToLog M2tsPcrControl
forall a. (a -> ByteStringBuilder) -> ToLog a
build :: M2tsPcrControl -> ByteStringBuilder
$cbuild :: M2tsPcrControl -> ByteStringBuilder
Core.ToLog,
      HeaderName -> M2tsPcrControl -> [Header]
(HeaderName -> M2tsPcrControl -> [Header])
-> ToHeader M2tsPcrControl
forall a. (HeaderName -> a -> [Header]) -> ToHeader a
toHeader :: HeaderName -> M2tsPcrControl -> [Header]
$ctoHeader :: HeaderName -> M2tsPcrControl -> [Header]
Core.ToHeader,
      M2tsPcrControl -> QueryString
(M2tsPcrControl -> QueryString) -> ToQuery M2tsPcrControl
forall a. (a -> QueryString) -> ToQuery a
toQuery :: M2tsPcrControl -> QueryString
$ctoQuery :: M2tsPcrControl -> QueryString
Core.ToQuery,
      Value -> Parser [M2tsPcrControl]
Value -> Parser M2tsPcrControl
(Value -> Parser M2tsPcrControl)
-> (Value -> Parser [M2tsPcrControl]) -> FromJSON M2tsPcrControl
forall a.
(Value -> Parser a) -> (Value -> Parser [a]) -> FromJSON a
parseJSONList :: Value -> Parser [M2tsPcrControl]
$cparseJSONList :: Value -> Parser [M2tsPcrControl]
parseJSON :: Value -> Parser M2tsPcrControl
$cparseJSON :: Value -> Parser M2tsPcrControl
Core.FromJSON,
      FromJSONKeyFunction [M2tsPcrControl]
FromJSONKeyFunction M2tsPcrControl
FromJSONKeyFunction M2tsPcrControl
-> FromJSONKeyFunction [M2tsPcrControl]
-> FromJSONKey M2tsPcrControl
forall a.
FromJSONKeyFunction a -> FromJSONKeyFunction [a] -> FromJSONKey a
fromJSONKeyList :: FromJSONKeyFunction [M2tsPcrControl]
$cfromJSONKeyList :: FromJSONKeyFunction [M2tsPcrControl]
fromJSONKey :: FromJSONKeyFunction M2tsPcrControl
$cfromJSONKey :: FromJSONKeyFunction M2tsPcrControl
Core.FromJSONKey,
      [M2tsPcrControl] -> Encoding
[M2tsPcrControl] -> Value
M2tsPcrControl -> Encoding
M2tsPcrControl -> Value
(M2tsPcrControl -> Value)
-> (M2tsPcrControl -> Encoding)
-> ([M2tsPcrControl] -> Value)
-> ([M2tsPcrControl] -> Encoding)
-> ToJSON M2tsPcrControl
forall a.
(a -> Value)
-> (a -> Encoding)
-> ([a] -> Value)
-> ([a] -> Encoding)
-> ToJSON a
toEncodingList :: [M2tsPcrControl] -> Encoding
$ctoEncodingList :: [M2tsPcrControl] -> Encoding
toJSONList :: [M2tsPcrControl] -> Value
$ctoJSONList :: [M2tsPcrControl] -> Value
toEncoding :: M2tsPcrControl -> Encoding
$ctoEncoding :: M2tsPcrControl -> Encoding
toJSON :: M2tsPcrControl -> Value
$ctoJSON :: M2tsPcrControl -> Value
Core.ToJSON,
      ToJSONKeyFunction [M2tsPcrControl]
ToJSONKeyFunction M2tsPcrControl
ToJSONKeyFunction M2tsPcrControl
-> ToJSONKeyFunction [M2tsPcrControl] -> ToJSONKey M2tsPcrControl
forall a.
ToJSONKeyFunction a -> ToJSONKeyFunction [a] -> ToJSONKey a
toJSONKeyList :: ToJSONKeyFunction [M2tsPcrControl]
$ctoJSONKeyList :: ToJSONKeyFunction [M2tsPcrControl]
toJSONKey :: ToJSONKeyFunction M2tsPcrControl
$ctoJSONKey :: ToJSONKeyFunction M2tsPcrControl
Core.ToJSONKey,
      [Node] -> Either String M2tsPcrControl
([Node] -> Either String M2tsPcrControl) -> FromXML M2tsPcrControl
forall a. ([Node] -> Either String a) -> FromXML a
parseXML :: [Node] -> Either String M2tsPcrControl
$cparseXML :: [Node] -> Either String M2tsPcrControl
Core.FromXML,
      M2tsPcrControl -> XML
(M2tsPcrControl -> XML) -> ToXML M2tsPcrControl
forall a. (a -> XML) -> ToXML a
toXML :: M2tsPcrControl -> XML
$ctoXML :: M2tsPcrControl -> XML
Core.ToXML
    )

pattern M2tsPcrControl_CONFIGURED_PCR_PERIOD :: M2tsPcrControl
pattern $bM2tsPcrControl_CONFIGURED_PCR_PERIOD :: M2tsPcrControl
$mM2tsPcrControl_CONFIGURED_PCR_PERIOD :: forall r. M2tsPcrControl -> (Void# -> r) -> (Void# -> r) -> r
M2tsPcrControl_CONFIGURED_PCR_PERIOD = M2tsPcrControl' "CONFIGURED_PCR_PERIOD"

pattern M2tsPcrControl_PCR_EVERY_PES_PACKET :: M2tsPcrControl
pattern $bM2tsPcrControl_PCR_EVERY_PES_PACKET :: M2tsPcrControl
$mM2tsPcrControl_PCR_EVERY_PES_PACKET :: forall r. M2tsPcrControl -> (Void# -> r) -> (Void# -> r) -> r
M2tsPcrControl_PCR_EVERY_PES_PACKET = M2tsPcrControl' "PCR_EVERY_PES_PACKET"

{-# COMPLETE
  M2tsPcrControl_CONFIGURED_PCR_PERIOD,
  M2tsPcrControl_PCR_EVERY_PES_PACKET,
  M2tsPcrControl'
  #-}