{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}
module Amazonka.MediaLive.Types.EbuTtDDestinationSettings where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import Amazonka.MediaLive.Types.EbuTtDDestinationStyleControl
import Amazonka.MediaLive.Types.EbuTtDFillLineGapControl
import qualified Amazonka.Prelude as Prelude
data EbuTtDDestinationSettings = EbuTtDDestinationSettings'
{
EbuTtDDestinationSettings -> Maybe EbuTtDFillLineGapControl
fillLineGap :: Prelude.Maybe EbuTtDFillLineGapControl,
EbuTtDDestinationSettings -> Maybe Text
copyrightHolder :: Prelude.Maybe Prelude.Text,
EbuTtDDestinationSettings -> Maybe Text
fontFamily :: Prelude.Maybe Prelude.Text,
EbuTtDDestinationSettings -> Maybe EbuTtDDestinationStyleControl
styleControl :: Prelude.Maybe EbuTtDDestinationStyleControl
}
deriving (EbuTtDDestinationSettings -> EbuTtDDestinationSettings -> Bool
(EbuTtDDestinationSettings -> EbuTtDDestinationSettings -> Bool)
-> (EbuTtDDestinationSettings -> EbuTtDDestinationSettings -> Bool)
-> Eq EbuTtDDestinationSettings
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: EbuTtDDestinationSettings -> EbuTtDDestinationSettings -> Bool
$c/= :: EbuTtDDestinationSettings -> EbuTtDDestinationSettings -> Bool
== :: EbuTtDDestinationSettings -> EbuTtDDestinationSettings -> Bool
$c== :: EbuTtDDestinationSettings -> EbuTtDDestinationSettings -> Bool
Prelude.Eq, ReadPrec [EbuTtDDestinationSettings]
ReadPrec EbuTtDDestinationSettings
Int -> ReadS EbuTtDDestinationSettings
ReadS [EbuTtDDestinationSettings]
(Int -> ReadS EbuTtDDestinationSettings)
-> ReadS [EbuTtDDestinationSettings]
-> ReadPrec EbuTtDDestinationSettings
-> ReadPrec [EbuTtDDestinationSettings]
-> Read EbuTtDDestinationSettings
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [EbuTtDDestinationSettings]
$creadListPrec :: ReadPrec [EbuTtDDestinationSettings]
readPrec :: ReadPrec EbuTtDDestinationSettings
$creadPrec :: ReadPrec EbuTtDDestinationSettings
readList :: ReadS [EbuTtDDestinationSettings]
$creadList :: ReadS [EbuTtDDestinationSettings]
readsPrec :: Int -> ReadS EbuTtDDestinationSettings
$creadsPrec :: Int -> ReadS EbuTtDDestinationSettings
Prelude.Read, Int -> EbuTtDDestinationSettings -> ShowS
[EbuTtDDestinationSettings] -> ShowS
EbuTtDDestinationSettings -> String
(Int -> EbuTtDDestinationSettings -> ShowS)
-> (EbuTtDDestinationSettings -> String)
-> ([EbuTtDDestinationSettings] -> ShowS)
-> Show EbuTtDDestinationSettings
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [EbuTtDDestinationSettings] -> ShowS
$cshowList :: [EbuTtDDestinationSettings] -> ShowS
show :: EbuTtDDestinationSettings -> String
$cshow :: EbuTtDDestinationSettings -> String
showsPrec :: Int -> EbuTtDDestinationSettings -> ShowS
$cshowsPrec :: Int -> EbuTtDDestinationSettings -> ShowS
Prelude.Show, (forall x.
EbuTtDDestinationSettings -> Rep EbuTtDDestinationSettings x)
-> (forall x.
Rep EbuTtDDestinationSettings x -> EbuTtDDestinationSettings)
-> Generic EbuTtDDestinationSettings
forall x.
Rep EbuTtDDestinationSettings x -> EbuTtDDestinationSettings
forall x.
EbuTtDDestinationSettings -> Rep EbuTtDDestinationSettings x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep EbuTtDDestinationSettings x -> EbuTtDDestinationSettings
$cfrom :: forall x.
EbuTtDDestinationSettings -> Rep EbuTtDDestinationSettings x
Prelude.Generic)
newEbuTtDDestinationSettings ::
EbuTtDDestinationSettings
newEbuTtDDestinationSettings :: EbuTtDDestinationSettings
newEbuTtDDestinationSettings =
EbuTtDDestinationSettings' :: Maybe EbuTtDFillLineGapControl
-> Maybe Text
-> Maybe Text
-> Maybe EbuTtDDestinationStyleControl
-> EbuTtDDestinationSettings
EbuTtDDestinationSettings'
{ $sel:fillLineGap:EbuTtDDestinationSettings' :: Maybe EbuTtDFillLineGapControl
fillLineGap =
Maybe EbuTtDFillLineGapControl
forall a. Maybe a
Prelude.Nothing,
$sel:copyrightHolder:EbuTtDDestinationSettings' :: Maybe Text
copyrightHolder = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:fontFamily:EbuTtDDestinationSettings' :: Maybe Text
fontFamily = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:styleControl:EbuTtDDestinationSettings' :: Maybe EbuTtDDestinationStyleControl
styleControl = Maybe EbuTtDDestinationStyleControl
forall a. Maybe a
Prelude.Nothing
}
ebuTtDDestinationSettings_fillLineGap :: Lens.Lens' EbuTtDDestinationSettings (Prelude.Maybe EbuTtDFillLineGapControl)
ebuTtDDestinationSettings_fillLineGap :: (Maybe EbuTtDFillLineGapControl
-> f (Maybe EbuTtDFillLineGapControl))
-> EbuTtDDestinationSettings -> f EbuTtDDestinationSettings
ebuTtDDestinationSettings_fillLineGap = (EbuTtDDestinationSettings -> Maybe EbuTtDFillLineGapControl)
-> (EbuTtDDestinationSettings
-> Maybe EbuTtDFillLineGapControl -> EbuTtDDestinationSettings)
-> Lens
EbuTtDDestinationSettings
EbuTtDDestinationSettings
(Maybe EbuTtDFillLineGapControl)
(Maybe EbuTtDFillLineGapControl)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\EbuTtDDestinationSettings' {Maybe EbuTtDFillLineGapControl
fillLineGap :: Maybe EbuTtDFillLineGapControl
$sel:fillLineGap:EbuTtDDestinationSettings' :: EbuTtDDestinationSettings -> Maybe EbuTtDFillLineGapControl
fillLineGap} -> Maybe EbuTtDFillLineGapControl
fillLineGap) (\s :: EbuTtDDestinationSettings
s@EbuTtDDestinationSettings' {} Maybe EbuTtDFillLineGapControl
a -> EbuTtDDestinationSettings
s {$sel:fillLineGap:EbuTtDDestinationSettings' :: Maybe EbuTtDFillLineGapControl
fillLineGap = Maybe EbuTtDFillLineGapControl
a} :: EbuTtDDestinationSettings)
ebuTtDDestinationSettings_copyrightHolder :: Lens.Lens' EbuTtDDestinationSettings (Prelude.Maybe Prelude.Text)
ebuTtDDestinationSettings_copyrightHolder :: (Maybe Text -> f (Maybe Text))
-> EbuTtDDestinationSettings -> f EbuTtDDestinationSettings
ebuTtDDestinationSettings_copyrightHolder = (EbuTtDDestinationSettings -> Maybe Text)
-> (EbuTtDDestinationSettings
-> Maybe Text -> EbuTtDDestinationSettings)
-> Lens
EbuTtDDestinationSettings
EbuTtDDestinationSettings
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\EbuTtDDestinationSettings' {Maybe Text
copyrightHolder :: Maybe Text
$sel:copyrightHolder:EbuTtDDestinationSettings' :: EbuTtDDestinationSettings -> Maybe Text
copyrightHolder} -> Maybe Text
copyrightHolder) (\s :: EbuTtDDestinationSettings
s@EbuTtDDestinationSettings' {} Maybe Text
a -> EbuTtDDestinationSettings
s {$sel:copyrightHolder:EbuTtDDestinationSettings' :: Maybe Text
copyrightHolder = Maybe Text
a} :: EbuTtDDestinationSettings)
ebuTtDDestinationSettings_fontFamily :: Lens.Lens' EbuTtDDestinationSettings (Prelude.Maybe Prelude.Text)
ebuTtDDestinationSettings_fontFamily :: (Maybe Text -> f (Maybe Text))
-> EbuTtDDestinationSettings -> f EbuTtDDestinationSettings
ebuTtDDestinationSettings_fontFamily = (EbuTtDDestinationSettings -> Maybe Text)
-> (EbuTtDDestinationSettings
-> Maybe Text -> EbuTtDDestinationSettings)
-> Lens
EbuTtDDestinationSettings
EbuTtDDestinationSettings
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\EbuTtDDestinationSettings' {Maybe Text
fontFamily :: Maybe Text
$sel:fontFamily:EbuTtDDestinationSettings' :: EbuTtDDestinationSettings -> Maybe Text
fontFamily} -> Maybe Text
fontFamily) (\s :: EbuTtDDestinationSettings
s@EbuTtDDestinationSettings' {} Maybe Text
a -> EbuTtDDestinationSettings
s {$sel:fontFamily:EbuTtDDestinationSettings' :: Maybe Text
fontFamily = Maybe Text
a} :: EbuTtDDestinationSettings)
ebuTtDDestinationSettings_styleControl :: Lens.Lens' EbuTtDDestinationSettings (Prelude.Maybe EbuTtDDestinationStyleControl)
ebuTtDDestinationSettings_styleControl :: (Maybe EbuTtDDestinationStyleControl
-> f (Maybe EbuTtDDestinationStyleControl))
-> EbuTtDDestinationSettings -> f EbuTtDDestinationSettings
ebuTtDDestinationSettings_styleControl = (EbuTtDDestinationSettings -> Maybe EbuTtDDestinationStyleControl)
-> (EbuTtDDestinationSettings
-> Maybe EbuTtDDestinationStyleControl
-> EbuTtDDestinationSettings)
-> Lens
EbuTtDDestinationSettings
EbuTtDDestinationSettings
(Maybe EbuTtDDestinationStyleControl)
(Maybe EbuTtDDestinationStyleControl)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\EbuTtDDestinationSettings' {Maybe EbuTtDDestinationStyleControl
styleControl :: Maybe EbuTtDDestinationStyleControl
$sel:styleControl:EbuTtDDestinationSettings' :: EbuTtDDestinationSettings -> Maybe EbuTtDDestinationStyleControl
styleControl} -> Maybe EbuTtDDestinationStyleControl
styleControl) (\s :: EbuTtDDestinationSettings
s@EbuTtDDestinationSettings' {} Maybe EbuTtDDestinationStyleControl
a -> EbuTtDDestinationSettings
s {$sel:styleControl:EbuTtDDestinationSettings' :: Maybe EbuTtDDestinationStyleControl
styleControl = Maybe EbuTtDDestinationStyleControl
a} :: EbuTtDDestinationSettings)
instance Core.FromJSON EbuTtDDestinationSettings where
parseJSON :: Value -> Parser EbuTtDDestinationSettings
parseJSON =
String
-> (Object -> Parser EbuTtDDestinationSettings)
-> Value
-> Parser EbuTtDDestinationSettings
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
String
"EbuTtDDestinationSettings"
( \Object
x ->
Maybe EbuTtDFillLineGapControl
-> Maybe Text
-> Maybe Text
-> Maybe EbuTtDDestinationStyleControl
-> EbuTtDDestinationSettings
EbuTtDDestinationSettings'
(Maybe EbuTtDFillLineGapControl
-> Maybe Text
-> Maybe Text
-> Maybe EbuTtDDestinationStyleControl
-> EbuTtDDestinationSettings)
-> Parser (Maybe EbuTtDFillLineGapControl)
-> Parser
(Maybe Text
-> Maybe Text
-> Maybe EbuTtDDestinationStyleControl
-> EbuTtDDestinationSettings)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Parser (Maybe EbuTtDFillLineGapControl)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"fillLineGap")
Parser
(Maybe Text
-> Maybe Text
-> Maybe EbuTtDDestinationStyleControl
-> EbuTtDDestinationSettings)
-> Parser (Maybe Text)
-> Parser
(Maybe Text
-> Maybe EbuTtDDestinationStyleControl
-> EbuTtDDestinationSettings)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"copyrightHolder")
Parser
(Maybe Text
-> Maybe EbuTtDDestinationStyleControl
-> EbuTtDDestinationSettings)
-> Parser (Maybe Text)
-> Parser
(Maybe EbuTtDDestinationStyleControl -> EbuTtDDestinationSettings)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"fontFamily")
Parser
(Maybe EbuTtDDestinationStyleControl -> EbuTtDDestinationSettings)
-> Parser (Maybe EbuTtDDestinationStyleControl)
-> Parser EbuTtDDestinationSettings
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe EbuTtDDestinationStyleControl)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"styleControl")
)
instance Prelude.Hashable EbuTtDDestinationSettings
instance Prelude.NFData EbuTtDDestinationSettings
instance Core.ToJSON EbuTtDDestinationSettings where
toJSON :: EbuTtDDestinationSettings -> Value
toJSON EbuTtDDestinationSettings' {Maybe Text
Maybe EbuTtDDestinationStyleControl
Maybe EbuTtDFillLineGapControl
styleControl :: Maybe EbuTtDDestinationStyleControl
fontFamily :: Maybe Text
copyrightHolder :: Maybe Text
fillLineGap :: Maybe EbuTtDFillLineGapControl
$sel:styleControl:EbuTtDDestinationSettings' :: EbuTtDDestinationSettings -> Maybe EbuTtDDestinationStyleControl
$sel:fontFamily:EbuTtDDestinationSettings' :: EbuTtDDestinationSettings -> Maybe Text
$sel:copyrightHolder:EbuTtDDestinationSettings' :: EbuTtDDestinationSettings -> Maybe Text
$sel:fillLineGap:EbuTtDDestinationSettings' :: EbuTtDDestinationSettings -> Maybe EbuTtDFillLineGapControl
..} =
[Pair] -> Value
Core.object
( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[ (Text
"fillLineGap" Text -> EbuTtDFillLineGapControl -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (EbuTtDFillLineGapControl -> Pair)
-> Maybe EbuTtDFillLineGapControl -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe EbuTtDFillLineGapControl
fillLineGap,
(Text
"copyrightHolder" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
(Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
copyrightHolder,
(Text
"fontFamily" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
fontFamily,
(Text
"styleControl" Text -> EbuTtDDestinationStyleControl -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (EbuTtDDestinationStyleControl -> Pair)
-> Maybe EbuTtDDestinationStyleControl -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe EbuTtDDestinationStyleControl
styleControl
]
)