{-# 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.H264GopSizeUnits
-- 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.H264GopSizeUnits
  ( H264GopSizeUnits
      ( ..,
        H264GopSizeUnits_FRAMES,
        H264GopSizeUnits_SECONDS
      ),
  )
where

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

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

pattern H264GopSizeUnits_FRAMES :: H264GopSizeUnits
pattern $bH264GopSizeUnits_FRAMES :: H264GopSizeUnits
$mH264GopSizeUnits_FRAMES :: forall r. H264GopSizeUnits -> (Void# -> r) -> (Void# -> r) -> r
H264GopSizeUnits_FRAMES = H264GopSizeUnits' "FRAMES"

pattern H264GopSizeUnits_SECONDS :: H264GopSizeUnits
pattern $bH264GopSizeUnits_SECONDS :: H264GopSizeUnits
$mH264GopSizeUnits_SECONDS :: forall r. H264GopSizeUnits -> (Void# -> r) -> (Void# -> r) -> r
H264GopSizeUnits_SECONDS = H264GopSizeUnits' "SECONDS"

{-# COMPLETE
  H264GopSizeUnits_FRAMES,
  H264GopSizeUnits_SECONDS,
  H264GopSizeUnits'
  #-}