{-# 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.Scte35SegmentationCancelIndicator
-- 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.Scte35SegmentationCancelIndicator
  ( Scte35SegmentationCancelIndicator
      ( ..,
        Scte35SegmentationCancelIndicator_SEGMENTATION_EVENT_CANCELED,
        Scte35SegmentationCancelIndicator_SEGMENTATION_EVENT_NOT_CANCELED
      ),
  )
where

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

-- | Corresponds to SCTE-35 segmentation_event_cancel_indicator.
-- SEGMENTATION_EVENT_NOT_CANCELED corresponds to 0 in the SCTE-35
-- specification and indicates that this is an insertion request.
-- SEGMENTATION_EVENT_CANCELED corresponds to 1 in the SCTE-35
-- specification and indicates that this is a cancelation request, in which
-- case complete this field and the existing event ID to cancel.
newtype Scte35SegmentationCancelIndicator = Scte35SegmentationCancelIndicator'
  { Scte35SegmentationCancelIndicator -> Text
fromScte35SegmentationCancelIndicator ::
      Data.Text
  }
  deriving stock
    ( Int -> Scte35SegmentationCancelIndicator -> ShowS
[Scte35SegmentationCancelIndicator] -> ShowS
Scte35SegmentationCancelIndicator -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [Scte35SegmentationCancelIndicator] -> ShowS
$cshowList :: [Scte35SegmentationCancelIndicator] -> ShowS
show :: Scte35SegmentationCancelIndicator -> String
$cshow :: Scte35SegmentationCancelIndicator -> String
showsPrec :: Int -> Scte35SegmentationCancelIndicator -> ShowS
$cshowsPrec :: Int -> Scte35SegmentationCancelIndicator -> ShowS
Prelude.Show,
      ReadPrec [Scte35SegmentationCancelIndicator]
ReadPrec Scte35SegmentationCancelIndicator
Int -> ReadS Scte35SegmentationCancelIndicator
ReadS [Scte35SegmentationCancelIndicator]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [Scte35SegmentationCancelIndicator]
$creadListPrec :: ReadPrec [Scte35SegmentationCancelIndicator]
readPrec :: ReadPrec Scte35SegmentationCancelIndicator
$creadPrec :: ReadPrec Scte35SegmentationCancelIndicator
readList :: ReadS [Scte35SegmentationCancelIndicator]
$creadList :: ReadS [Scte35SegmentationCancelIndicator]
readsPrec :: Int -> ReadS Scte35SegmentationCancelIndicator
$creadsPrec :: Int -> ReadS Scte35SegmentationCancelIndicator
Prelude.Read,
      Scte35SegmentationCancelIndicator
-> Scte35SegmentationCancelIndicator -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: Scte35SegmentationCancelIndicator
-> Scte35SegmentationCancelIndicator -> Bool
$c/= :: Scte35SegmentationCancelIndicator
-> Scte35SegmentationCancelIndicator -> Bool
== :: Scte35SegmentationCancelIndicator
-> Scte35SegmentationCancelIndicator -> Bool
$c== :: Scte35SegmentationCancelIndicator
-> Scte35SegmentationCancelIndicator -> Bool
Prelude.Eq,
      Eq Scte35SegmentationCancelIndicator
Scte35SegmentationCancelIndicator
-> Scte35SegmentationCancelIndicator -> Bool
Scte35SegmentationCancelIndicator
-> Scte35SegmentationCancelIndicator -> Ordering
Scte35SegmentationCancelIndicator
-> Scte35SegmentationCancelIndicator
-> Scte35SegmentationCancelIndicator
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 :: Scte35SegmentationCancelIndicator
-> Scte35SegmentationCancelIndicator
-> Scte35SegmentationCancelIndicator
$cmin :: Scte35SegmentationCancelIndicator
-> Scte35SegmentationCancelIndicator
-> Scte35SegmentationCancelIndicator
max :: Scte35SegmentationCancelIndicator
-> Scte35SegmentationCancelIndicator
-> Scte35SegmentationCancelIndicator
$cmax :: Scte35SegmentationCancelIndicator
-> Scte35SegmentationCancelIndicator
-> Scte35SegmentationCancelIndicator
>= :: Scte35SegmentationCancelIndicator
-> Scte35SegmentationCancelIndicator -> Bool
$c>= :: Scte35SegmentationCancelIndicator
-> Scte35SegmentationCancelIndicator -> Bool
> :: Scte35SegmentationCancelIndicator
-> Scte35SegmentationCancelIndicator -> Bool
$c> :: Scte35SegmentationCancelIndicator
-> Scte35SegmentationCancelIndicator -> Bool
<= :: Scte35SegmentationCancelIndicator
-> Scte35SegmentationCancelIndicator -> Bool
$c<= :: Scte35SegmentationCancelIndicator
-> Scte35SegmentationCancelIndicator -> Bool
< :: Scte35SegmentationCancelIndicator
-> Scte35SegmentationCancelIndicator -> Bool
$c< :: Scte35SegmentationCancelIndicator
-> Scte35SegmentationCancelIndicator -> Bool
compare :: Scte35SegmentationCancelIndicator
-> Scte35SegmentationCancelIndicator -> Ordering
$ccompare :: Scte35SegmentationCancelIndicator
-> Scte35SegmentationCancelIndicator -> Ordering
Prelude.Ord,
      forall x.
Rep Scte35SegmentationCancelIndicator x
-> Scte35SegmentationCancelIndicator
forall x.
Scte35SegmentationCancelIndicator
-> Rep Scte35SegmentationCancelIndicator x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep Scte35SegmentationCancelIndicator x
-> Scte35SegmentationCancelIndicator
$cfrom :: forall x.
Scte35SegmentationCancelIndicator
-> Rep Scte35SegmentationCancelIndicator x
Prelude.Generic
    )
  deriving newtype
    ( Eq Scte35SegmentationCancelIndicator
Int -> Scte35SegmentationCancelIndicator -> Int
Scte35SegmentationCancelIndicator -> Int
forall a. Eq a -> (Int -> a -> Int) -> (a -> Int) -> Hashable a
hash :: Scte35SegmentationCancelIndicator -> Int
$chash :: Scte35SegmentationCancelIndicator -> Int
hashWithSalt :: Int -> Scte35SegmentationCancelIndicator -> Int
$chashWithSalt :: Int -> Scte35SegmentationCancelIndicator -> Int
Prelude.Hashable,
      Scte35SegmentationCancelIndicator -> ()
forall a. (a -> ()) -> NFData a
rnf :: Scte35SegmentationCancelIndicator -> ()
$crnf :: Scte35SegmentationCancelIndicator -> ()
Prelude.NFData,
      Text -> Either String Scte35SegmentationCancelIndicator
forall a. (Text -> Either String a) -> FromText a
fromText :: Text -> Either String Scte35SegmentationCancelIndicator
$cfromText :: Text -> Either String Scte35SegmentationCancelIndicator
Data.FromText,
      Scte35SegmentationCancelIndicator -> Text
forall a. (a -> Text) -> ToText a
toText :: Scte35SegmentationCancelIndicator -> Text
$ctoText :: Scte35SegmentationCancelIndicator -> Text
Data.ToText,
      Scte35SegmentationCancelIndicator -> ByteString
forall a. (a -> ByteString) -> ToByteString a
toBS :: Scte35SegmentationCancelIndicator -> ByteString
$ctoBS :: Scte35SegmentationCancelIndicator -> ByteString
Data.ToByteString,
      Scte35SegmentationCancelIndicator -> ByteStringBuilder
forall a. (a -> ByteStringBuilder) -> ToLog a
build :: Scte35SegmentationCancelIndicator -> ByteStringBuilder
$cbuild :: Scte35SegmentationCancelIndicator -> ByteStringBuilder
Data.ToLog,
      HeaderName -> Scte35SegmentationCancelIndicator -> [Header]
forall a. (HeaderName -> a -> [Header]) -> ToHeader a
toHeader :: HeaderName -> Scte35SegmentationCancelIndicator -> [Header]
$ctoHeader :: HeaderName -> Scte35SegmentationCancelIndicator -> [Header]
Data.ToHeader,
      Scte35SegmentationCancelIndicator -> QueryString
forall a. (a -> QueryString) -> ToQuery a
toQuery :: Scte35SegmentationCancelIndicator -> QueryString
$ctoQuery :: Scte35SegmentationCancelIndicator -> QueryString
Data.ToQuery,
      Value -> Parser [Scte35SegmentationCancelIndicator]
Value -> Parser Scte35SegmentationCancelIndicator
forall a.
(Value -> Parser a) -> (Value -> Parser [a]) -> FromJSON a
parseJSONList :: Value -> Parser [Scte35SegmentationCancelIndicator]
$cparseJSONList :: Value -> Parser [Scte35SegmentationCancelIndicator]
parseJSON :: Value -> Parser Scte35SegmentationCancelIndicator
$cparseJSON :: Value -> Parser Scte35SegmentationCancelIndicator
Data.FromJSON,
      FromJSONKeyFunction [Scte35SegmentationCancelIndicator]
FromJSONKeyFunction Scte35SegmentationCancelIndicator
forall a.
FromJSONKeyFunction a -> FromJSONKeyFunction [a] -> FromJSONKey a
fromJSONKeyList :: FromJSONKeyFunction [Scte35SegmentationCancelIndicator]
$cfromJSONKeyList :: FromJSONKeyFunction [Scte35SegmentationCancelIndicator]
fromJSONKey :: FromJSONKeyFunction Scte35SegmentationCancelIndicator
$cfromJSONKey :: FromJSONKeyFunction Scte35SegmentationCancelIndicator
Data.FromJSONKey,
      [Scte35SegmentationCancelIndicator] -> Encoding
[Scte35SegmentationCancelIndicator] -> Value
Scte35SegmentationCancelIndicator -> Encoding
Scte35SegmentationCancelIndicator -> Value
forall a.
(a -> Value)
-> (a -> Encoding)
-> ([a] -> Value)
-> ([a] -> Encoding)
-> ToJSON a
toEncodingList :: [Scte35SegmentationCancelIndicator] -> Encoding
$ctoEncodingList :: [Scte35SegmentationCancelIndicator] -> Encoding
toJSONList :: [Scte35SegmentationCancelIndicator] -> Value
$ctoJSONList :: [Scte35SegmentationCancelIndicator] -> Value
toEncoding :: Scte35SegmentationCancelIndicator -> Encoding
$ctoEncoding :: Scte35SegmentationCancelIndicator -> Encoding
toJSON :: Scte35SegmentationCancelIndicator -> Value
$ctoJSON :: Scte35SegmentationCancelIndicator -> Value
Data.ToJSON,
      ToJSONKeyFunction [Scte35SegmentationCancelIndicator]
ToJSONKeyFunction Scte35SegmentationCancelIndicator
forall a.
ToJSONKeyFunction a -> ToJSONKeyFunction [a] -> ToJSONKey a
toJSONKeyList :: ToJSONKeyFunction [Scte35SegmentationCancelIndicator]
$ctoJSONKeyList :: ToJSONKeyFunction [Scte35SegmentationCancelIndicator]
toJSONKey :: ToJSONKeyFunction Scte35SegmentationCancelIndicator
$ctoJSONKey :: ToJSONKeyFunction Scte35SegmentationCancelIndicator
Data.ToJSONKey,
      [Node] -> Either String Scte35SegmentationCancelIndicator
forall a. ([Node] -> Either String a) -> FromXML a
parseXML :: [Node] -> Either String Scte35SegmentationCancelIndicator
$cparseXML :: [Node] -> Either String Scte35SegmentationCancelIndicator
Data.FromXML,
      Scte35SegmentationCancelIndicator -> XML
forall a. (a -> XML) -> ToXML a
toXML :: Scte35SegmentationCancelIndicator -> XML
$ctoXML :: Scte35SegmentationCancelIndicator -> XML
Data.ToXML
    )

pattern Scte35SegmentationCancelIndicator_SEGMENTATION_EVENT_CANCELED :: Scte35SegmentationCancelIndicator
pattern $bScte35SegmentationCancelIndicator_SEGMENTATION_EVENT_CANCELED :: Scte35SegmentationCancelIndicator
$mScte35SegmentationCancelIndicator_SEGMENTATION_EVENT_CANCELED :: forall {r}.
Scte35SegmentationCancelIndicator
-> ((# #) -> r) -> ((# #) -> r) -> r
Scte35SegmentationCancelIndicator_SEGMENTATION_EVENT_CANCELED = Scte35SegmentationCancelIndicator' "SEGMENTATION_EVENT_CANCELED"

pattern Scte35SegmentationCancelIndicator_SEGMENTATION_EVENT_NOT_CANCELED :: Scte35SegmentationCancelIndicator
pattern $bScte35SegmentationCancelIndicator_SEGMENTATION_EVENT_NOT_CANCELED :: Scte35SegmentationCancelIndicator
$mScte35SegmentationCancelIndicator_SEGMENTATION_EVENT_NOT_CANCELED :: forall {r}.
Scte35SegmentationCancelIndicator
-> ((# #) -> r) -> ((# #) -> r) -> r
Scte35SegmentationCancelIndicator_SEGMENTATION_EVENT_NOT_CANCELED = Scte35SegmentationCancelIndicator' "SEGMENTATION_EVENT_NOT_CANCELED"

{-# COMPLETE
  Scte35SegmentationCancelIndicator_SEGMENTATION_EVENT_CANCELED,
  Scte35SegmentationCancelIndicator_SEGMENTATION_EVENT_NOT_CANCELED,
  Scte35SegmentationCancelIndicator'
  #-}