{-# 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.Scte35ArchiveAllowedFlag
-- Copyright   : (c) 2013-2023 Brendan Hay
-- License     : Mozilla Public License, v. 2.0.
-- Maintainer  : Brendan Hay
-- Stability   : auto-generated
-- Portability : non-portable (GHC extensions)
module Amazonka.MediaLive.Types.Scte35ArchiveAllowedFlag
  ( Scte35ArchiveAllowedFlag
      ( ..,
        Scte35ArchiveAllowedFlag_ARCHIVE_ALLOWED,
        Scte35ArchiveAllowedFlag_ARCHIVE_NOT_ALLOWED
      ),
  )
where

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

-- | Corresponds to the archive_allowed parameter. A value of
-- ARCHIVE_NOT_ALLOWED corresponds to 0 (false) in the SCTE-35
-- specification. If you include one of the \"restriction\" flags then you
-- must include all four of them.
newtype Scte35ArchiveAllowedFlag = Scte35ArchiveAllowedFlag'
  { Scte35ArchiveAllowedFlag -> Text
fromScte35ArchiveAllowedFlag ::
      Data.Text
  }
  deriving stock
    ( Int -> Scte35ArchiveAllowedFlag -> ShowS
[Scte35ArchiveAllowedFlag] -> ShowS
Scte35ArchiveAllowedFlag -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [Scte35ArchiveAllowedFlag] -> ShowS
$cshowList :: [Scte35ArchiveAllowedFlag] -> ShowS
show :: Scte35ArchiveAllowedFlag -> String
$cshow :: Scte35ArchiveAllowedFlag -> String
showsPrec :: Int -> Scte35ArchiveAllowedFlag -> ShowS
$cshowsPrec :: Int -> Scte35ArchiveAllowedFlag -> ShowS
Prelude.Show,
      ReadPrec [Scte35ArchiveAllowedFlag]
ReadPrec Scte35ArchiveAllowedFlag
Int -> ReadS Scte35ArchiveAllowedFlag
ReadS [Scte35ArchiveAllowedFlag]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [Scte35ArchiveAllowedFlag]
$creadListPrec :: ReadPrec [Scte35ArchiveAllowedFlag]
readPrec :: ReadPrec Scte35ArchiveAllowedFlag
$creadPrec :: ReadPrec Scte35ArchiveAllowedFlag
readList :: ReadS [Scte35ArchiveAllowedFlag]
$creadList :: ReadS [Scte35ArchiveAllowedFlag]
readsPrec :: Int -> ReadS Scte35ArchiveAllowedFlag
$creadsPrec :: Int -> ReadS Scte35ArchiveAllowedFlag
Prelude.Read,
      Scte35ArchiveAllowedFlag -> Scte35ArchiveAllowedFlag -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: Scte35ArchiveAllowedFlag -> Scte35ArchiveAllowedFlag -> Bool
$c/= :: Scte35ArchiveAllowedFlag -> Scte35ArchiveAllowedFlag -> Bool
== :: Scte35ArchiveAllowedFlag -> Scte35ArchiveAllowedFlag -> Bool
$c== :: Scte35ArchiveAllowedFlag -> Scte35ArchiveAllowedFlag -> Bool
Prelude.Eq,
      Eq Scte35ArchiveAllowedFlag
Scte35ArchiveAllowedFlag -> Scte35ArchiveAllowedFlag -> Bool
Scte35ArchiveAllowedFlag -> Scte35ArchiveAllowedFlag -> Ordering
Scte35ArchiveAllowedFlag
-> Scte35ArchiveAllowedFlag -> Scte35ArchiveAllowedFlag
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 :: Scte35ArchiveAllowedFlag
-> Scte35ArchiveAllowedFlag -> Scte35ArchiveAllowedFlag
$cmin :: Scte35ArchiveAllowedFlag
-> Scte35ArchiveAllowedFlag -> Scte35ArchiveAllowedFlag
max :: Scte35ArchiveAllowedFlag
-> Scte35ArchiveAllowedFlag -> Scte35ArchiveAllowedFlag
$cmax :: Scte35ArchiveAllowedFlag
-> Scte35ArchiveAllowedFlag -> Scte35ArchiveAllowedFlag
>= :: Scte35ArchiveAllowedFlag -> Scte35ArchiveAllowedFlag -> Bool
$c>= :: Scte35ArchiveAllowedFlag -> Scte35ArchiveAllowedFlag -> Bool
> :: Scte35ArchiveAllowedFlag -> Scte35ArchiveAllowedFlag -> Bool
$c> :: Scte35ArchiveAllowedFlag -> Scte35ArchiveAllowedFlag -> Bool
<= :: Scte35ArchiveAllowedFlag -> Scte35ArchiveAllowedFlag -> Bool
$c<= :: Scte35ArchiveAllowedFlag -> Scte35ArchiveAllowedFlag -> Bool
< :: Scte35ArchiveAllowedFlag -> Scte35ArchiveAllowedFlag -> Bool
$c< :: Scte35ArchiveAllowedFlag -> Scte35ArchiveAllowedFlag -> Bool
compare :: Scte35ArchiveAllowedFlag -> Scte35ArchiveAllowedFlag -> Ordering
$ccompare :: Scte35ArchiveAllowedFlag -> Scte35ArchiveAllowedFlag -> Ordering
Prelude.Ord,
      forall x.
Rep Scte35ArchiveAllowedFlag x -> Scte35ArchiveAllowedFlag
forall x.
Scte35ArchiveAllowedFlag -> Rep Scte35ArchiveAllowedFlag x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep Scte35ArchiveAllowedFlag x -> Scte35ArchiveAllowedFlag
$cfrom :: forall x.
Scte35ArchiveAllowedFlag -> Rep Scte35ArchiveAllowedFlag x
Prelude.Generic
    )
  deriving newtype
    ( Eq Scte35ArchiveAllowedFlag
Int -> Scte35ArchiveAllowedFlag -> Int
Scte35ArchiveAllowedFlag -> Int
forall a. Eq a -> (Int -> a -> Int) -> (a -> Int) -> Hashable a
hash :: Scte35ArchiveAllowedFlag -> Int
$chash :: Scte35ArchiveAllowedFlag -> Int
hashWithSalt :: Int -> Scte35ArchiveAllowedFlag -> Int
$chashWithSalt :: Int -> Scte35ArchiveAllowedFlag -> Int
Prelude.Hashable,
      Scte35ArchiveAllowedFlag -> ()
forall a. (a -> ()) -> NFData a
rnf :: Scte35ArchiveAllowedFlag -> ()
$crnf :: Scte35ArchiveAllowedFlag -> ()
Prelude.NFData,
      Text -> Either String Scte35ArchiveAllowedFlag
forall a. (Text -> Either String a) -> FromText a
fromText :: Text -> Either String Scte35ArchiveAllowedFlag
$cfromText :: Text -> Either String Scte35ArchiveAllowedFlag
Data.FromText,
      Scte35ArchiveAllowedFlag -> Text
forall a. (a -> Text) -> ToText a
toText :: Scte35ArchiveAllowedFlag -> Text
$ctoText :: Scte35ArchiveAllowedFlag -> Text
Data.ToText,
      Scte35ArchiveAllowedFlag -> ByteString
forall a. (a -> ByteString) -> ToByteString a
toBS :: Scte35ArchiveAllowedFlag -> ByteString
$ctoBS :: Scte35ArchiveAllowedFlag -> ByteString
Data.ToByteString,
      Scte35ArchiveAllowedFlag -> ByteStringBuilder
forall a. (a -> ByteStringBuilder) -> ToLog a
build :: Scte35ArchiveAllowedFlag -> ByteStringBuilder
$cbuild :: Scte35ArchiveAllowedFlag -> ByteStringBuilder
Data.ToLog,
      HeaderName -> Scte35ArchiveAllowedFlag -> [Header]
forall a. (HeaderName -> a -> [Header]) -> ToHeader a
toHeader :: HeaderName -> Scte35ArchiveAllowedFlag -> [Header]
$ctoHeader :: HeaderName -> Scte35ArchiveAllowedFlag -> [Header]
Data.ToHeader,
      Scte35ArchiveAllowedFlag -> QueryString
forall a. (a -> QueryString) -> ToQuery a
toQuery :: Scte35ArchiveAllowedFlag -> QueryString
$ctoQuery :: Scte35ArchiveAllowedFlag -> QueryString
Data.ToQuery,
      Value -> Parser [Scte35ArchiveAllowedFlag]
Value -> Parser Scte35ArchiveAllowedFlag
forall a.
(Value -> Parser a) -> (Value -> Parser [a]) -> FromJSON a
parseJSONList :: Value -> Parser [Scte35ArchiveAllowedFlag]
$cparseJSONList :: Value -> Parser [Scte35ArchiveAllowedFlag]
parseJSON :: Value -> Parser Scte35ArchiveAllowedFlag
$cparseJSON :: Value -> Parser Scte35ArchiveAllowedFlag
Data.FromJSON,
      FromJSONKeyFunction [Scte35ArchiveAllowedFlag]
FromJSONKeyFunction Scte35ArchiveAllowedFlag
forall a.
FromJSONKeyFunction a -> FromJSONKeyFunction [a] -> FromJSONKey a
fromJSONKeyList :: FromJSONKeyFunction [Scte35ArchiveAllowedFlag]
$cfromJSONKeyList :: FromJSONKeyFunction [Scte35ArchiveAllowedFlag]
fromJSONKey :: FromJSONKeyFunction Scte35ArchiveAllowedFlag
$cfromJSONKey :: FromJSONKeyFunction Scte35ArchiveAllowedFlag
Data.FromJSONKey,
      [Scte35ArchiveAllowedFlag] -> Encoding
[Scte35ArchiveAllowedFlag] -> Value
Scte35ArchiveAllowedFlag -> Encoding
Scte35ArchiveAllowedFlag -> Value
forall a.
(a -> Value)
-> (a -> Encoding)
-> ([a] -> Value)
-> ([a] -> Encoding)
-> ToJSON a
toEncodingList :: [Scte35ArchiveAllowedFlag] -> Encoding
$ctoEncodingList :: [Scte35ArchiveAllowedFlag] -> Encoding
toJSONList :: [Scte35ArchiveAllowedFlag] -> Value
$ctoJSONList :: [Scte35ArchiveAllowedFlag] -> Value
toEncoding :: Scte35ArchiveAllowedFlag -> Encoding
$ctoEncoding :: Scte35ArchiveAllowedFlag -> Encoding
toJSON :: Scte35ArchiveAllowedFlag -> Value
$ctoJSON :: Scte35ArchiveAllowedFlag -> Value
Data.ToJSON,
      ToJSONKeyFunction [Scte35ArchiveAllowedFlag]
ToJSONKeyFunction Scte35ArchiveAllowedFlag
forall a.
ToJSONKeyFunction a -> ToJSONKeyFunction [a] -> ToJSONKey a
toJSONKeyList :: ToJSONKeyFunction [Scte35ArchiveAllowedFlag]
$ctoJSONKeyList :: ToJSONKeyFunction [Scte35ArchiveAllowedFlag]
toJSONKey :: ToJSONKeyFunction Scte35ArchiveAllowedFlag
$ctoJSONKey :: ToJSONKeyFunction Scte35ArchiveAllowedFlag
Data.ToJSONKey,
      [Node] -> Either String Scte35ArchiveAllowedFlag
forall a. ([Node] -> Either String a) -> FromXML a
parseXML :: [Node] -> Either String Scte35ArchiveAllowedFlag
$cparseXML :: [Node] -> Either String Scte35ArchiveAllowedFlag
Data.FromXML,
      Scte35ArchiveAllowedFlag -> XML
forall a. (a -> XML) -> ToXML a
toXML :: Scte35ArchiveAllowedFlag -> XML
$ctoXML :: Scte35ArchiveAllowedFlag -> XML
Data.ToXML
    )

pattern Scte35ArchiveAllowedFlag_ARCHIVE_ALLOWED :: Scte35ArchiveAllowedFlag
pattern $bScte35ArchiveAllowedFlag_ARCHIVE_ALLOWED :: Scte35ArchiveAllowedFlag
$mScte35ArchiveAllowedFlag_ARCHIVE_ALLOWED :: forall {r}.
Scte35ArchiveAllowedFlag -> ((# #) -> r) -> ((# #) -> r) -> r
Scte35ArchiveAllowedFlag_ARCHIVE_ALLOWED = Scte35ArchiveAllowedFlag' "ARCHIVE_ALLOWED"

pattern Scte35ArchiveAllowedFlag_ARCHIVE_NOT_ALLOWED :: Scte35ArchiveAllowedFlag
pattern $bScte35ArchiveAllowedFlag_ARCHIVE_NOT_ALLOWED :: Scte35ArchiveAllowedFlag
$mScte35ArchiveAllowedFlag_ARCHIVE_NOT_ALLOWED :: forall {r}.
Scte35ArchiveAllowedFlag -> ((# #) -> r) -> ((# #) -> r) -> r
Scte35ArchiveAllowedFlag_ARCHIVE_NOT_ALLOWED = Scte35ArchiveAllowedFlag' "ARCHIVE_NOT_ALLOWED"

{-# COMPLETE
  Scte35ArchiveAllowedFlag_ARCHIVE_ALLOWED,
  Scte35ArchiveAllowedFlag_ARCHIVE_NOT_ALLOWED,
  Scte35ArchiveAllowedFlag'
  #-}