{-# 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.MediaLive.Types.HlsEncryptionType
-- 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.MediaLive.Types.HlsEncryptionType
  ( HlsEncryptionType
      ( ..,
        HlsEncryptionType_AES128,
        HlsEncryptionType_SAMPLE_AES
      ),
  )
where

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

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

pattern HlsEncryptionType_AES128 :: HlsEncryptionType
pattern $bHlsEncryptionType_AES128 :: HlsEncryptionType
$mHlsEncryptionType_AES128 :: forall r. HlsEncryptionType -> (Void# -> r) -> (Void# -> r) -> r
HlsEncryptionType_AES128 = HlsEncryptionType' "AES128"

pattern HlsEncryptionType_SAMPLE_AES :: HlsEncryptionType
pattern $bHlsEncryptionType_SAMPLE_AES :: HlsEncryptionType
$mHlsEncryptionType_SAMPLE_AES :: forall r. HlsEncryptionType -> (Void# -> r) -> (Void# -> r) -> r
HlsEncryptionType_SAMPLE_AES = HlsEncryptionType' "SAMPLE_AES"

{-# COMPLETE
  HlsEncryptionType_AES128,
  HlsEncryptionType_SAMPLE_AES,
  HlsEncryptionType'
  #-}