{-# 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.HlsIntervalCadence
-- 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.HlsIntervalCadence
  ( HlsIntervalCadence
      ( ..,
        HlsIntervalCadence_FOLLOW_CUSTOM,
        HlsIntervalCadence_FOLLOW_IFRAME
      ),
  )
where

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

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

pattern HlsIntervalCadence_FOLLOW_CUSTOM :: HlsIntervalCadence
pattern $bHlsIntervalCadence_FOLLOW_CUSTOM :: HlsIntervalCadence
$mHlsIntervalCadence_FOLLOW_CUSTOM :: forall r. HlsIntervalCadence -> (Void# -> r) -> (Void# -> r) -> r
HlsIntervalCadence_FOLLOW_CUSTOM = HlsIntervalCadence' "FOLLOW_CUSTOM"

pattern HlsIntervalCadence_FOLLOW_IFRAME :: HlsIntervalCadence
pattern $bHlsIntervalCadence_FOLLOW_IFRAME :: HlsIntervalCadence
$mHlsIntervalCadence_FOLLOW_IFRAME :: forall r. HlsIntervalCadence -> (Void# -> r) -> (Void# -> r) -> r
HlsIntervalCadence_FOLLOW_IFRAME = HlsIntervalCadence' "FOLLOW_IFRAME"

{-# COMPLETE
  HlsIntervalCadence_FOLLOW_CUSTOM,
  HlsIntervalCadence_FOLLOW_IFRAME,
  HlsIntervalCadence'
  #-}