{-# 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.MediaConnect.Types.MediaStreamType
-- 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.MediaConnect.Types.MediaStreamType
  ( MediaStreamType
      ( ..,
        MediaStreamType_Ancillary_data,
        MediaStreamType_Audio,
        MediaStreamType_Video
      ),
  )
where

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

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

pattern MediaStreamType_Ancillary_data :: MediaStreamType
pattern $bMediaStreamType_Ancillary_data :: MediaStreamType
$mMediaStreamType_Ancillary_data :: forall r. MediaStreamType -> (Void# -> r) -> (Void# -> r) -> r
MediaStreamType_Ancillary_data = MediaStreamType' "ancillary-data"

pattern MediaStreamType_Audio :: MediaStreamType
pattern $bMediaStreamType_Audio :: MediaStreamType
$mMediaStreamType_Audio :: forall r. MediaStreamType -> (Void# -> r) -> (Void# -> r) -> r
MediaStreamType_Audio = MediaStreamType' "audio"

pattern MediaStreamType_Video :: MediaStreamType
pattern $bMediaStreamType_Video :: MediaStreamType
$mMediaStreamType_Video :: forall r. MediaStreamType -> (Void# -> r) -> (Void# -> r) -> r
MediaStreamType_Video = MediaStreamType' "video"

{-# COMPLETE
  MediaStreamType_Ancillary_data,
  MediaStreamType_Audio,
  MediaStreamType_Video,
  MediaStreamType'
  #-}