{-# 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.NielsenWatermarksSettings where
import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import Amazonka.MediaLive.Types.NielsenCBET
import Amazonka.MediaLive.Types.NielsenNaesIiNw
import Amazonka.MediaLive.Types.NielsenWatermarksDistributionTypes
import qualified Amazonka.Prelude as Prelude
data NielsenWatermarksSettings = NielsenWatermarksSettings'
{
NielsenWatermarksSettings -> Maybe NielsenCBET
nielsenCbetSettings :: Prelude.Maybe NielsenCBET,
NielsenWatermarksSettings
-> Maybe NielsenWatermarksDistributionTypes
nielsenDistributionType :: Prelude.Maybe NielsenWatermarksDistributionTypes,
NielsenWatermarksSettings -> Maybe NielsenNaesIiNw
nielsenNaesIiNwSettings :: Prelude.Maybe NielsenNaesIiNw
}
deriving (NielsenWatermarksSettings -> NielsenWatermarksSettings -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: NielsenWatermarksSettings -> NielsenWatermarksSettings -> Bool
$c/= :: NielsenWatermarksSettings -> NielsenWatermarksSettings -> Bool
== :: NielsenWatermarksSettings -> NielsenWatermarksSettings -> Bool
$c== :: NielsenWatermarksSettings -> NielsenWatermarksSettings -> Bool
Prelude.Eq, ReadPrec [NielsenWatermarksSettings]
ReadPrec NielsenWatermarksSettings
Int -> ReadS NielsenWatermarksSettings
ReadS [NielsenWatermarksSettings]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [NielsenWatermarksSettings]
$creadListPrec :: ReadPrec [NielsenWatermarksSettings]
readPrec :: ReadPrec NielsenWatermarksSettings
$creadPrec :: ReadPrec NielsenWatermarksSettings
readList :: ReadS [NielsenWatermarksSettings]
$creadList :: ReadS [NielsenWatermarksSettings]
readsPrec :: Int -> ReadS NielsenWatermarksSettings
$creadsPrec :: Int -> ReadS NielsenWatermarksSettings
Prelude.Read, Int -> NielsenWatermarksSettings -> ShowS
[NielsenWatermarksSettings] -> ShowS
NielsenWatermarksSettings -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [NielsenWatermarksSettings] -> ShowS
$cshowList :: [NielsenWatermarksSettings] -> ShowS
show :: NielsenWatermarksSettings -> String
$cshow :: NielsenWatermarksSettings -> String
showsPrec :: Int -> NielsenWatermarksSettings -> ShowS
$cshowsPrec :: Int -> NielsenWatermarksSettings -> ShowS
Prelude.Show, forall x.
Rep NielsenWatermarksSettings x -> NielsenWatermarksSettings
forall x.
NielsenWatermarksSettings -> Rep NielsenWatermarksSettings x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep NielsenWatermarksSettings x -> NielsenWatermarksSettings
$cfrom :: forall x.
NielsenWatermarksSettings -> Rep NielsenWatermarksSettings x
Prelude.Generic)
newNielsenWatermarksSettings ::
NielsenWatermarksSettings
newNielsenWatermarksSettings :: NielsenWatermarksSettings
newNielsenWatermarksSettings =
NielsenWatermarksSettings'
{ $sel:nielsenCbetSettings:NielsenWatermarksSettings' :: Maybe NielsenCBET
nielsenCbetSettings =
forall a. Maybe a
Prelude.Nothing,
$sel:nielsenDistributionType:NielsenWatermarksSettings' :: Maybe NielsenWatermarksDistributionTypes
nielsenDistributionType = forall a. Maybe a
Prelude.Nothing,
$sel:nielsenNaesIiNwSettings:NielsenWatermarksSettings' :: Maybe NielsenNaesIiNw
nielsenNaesIiNwSettings = forall a. Maybe a
Prelude.Nothing
}
nielsenWatermarksSettings_nielsenCbetSettings :: Lens.Lens' NielsenWatermarksSettings (Prelude.Maybe NielsenCBET)
nielsenWatermarksSettings_nielsenCbetSettings :: Lens' NielsenWatermarksSettings (Maybe NielsenCBET)
nielsenWatermarksSettings_nielsenCbetSettings = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\NielsenWatermarksSettings' {Maybe NielsenCBET
nielsenCbetSettings :: Maybe NielsenCBET
$sel:nielsenCbetSettings:NielsenWatermarksSettings' :: NielsenWatermarksSettings -> Maybe NielsenCBET
nielsenCbetSettings} -> Maybe NielsenCBET
nielsenCbetSettings) (\s :: NielsenWatermarksSettings
s@NielsenWatermarksSettings' {} Maybe NielsenCBET
a -> NielsenWatermarksSettings
s {$sel:nielsenCbetSettings:NielsenWatermarksSettings' :: Maybe NielsenCBET
nielsenCbetSettings = Maybe NielsenCBET
a} :: NielsenWatermarksSettings)
nielsenWatermarksSettings_nielsenDistributionType :: Lens.Lens' NielsenWatermarksSettings (Prelude.Maybe NielsenWatermarksDistributionTypes)
nielsenWatermarksSettings_nielsenDistributionType :: Lens'
NielsenWatermarksSettings
(Maybe NielsenWatermarksDistributionTypes)
nielsenWatermarksSettings_nielsenDistributionType = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\NielsenWatermarksSettings' {Maybe NielsenWatermarksDistributionTypes
nielsenDistributionType :: Maybe NielsenWatermarksDistributionTypes
$sel:nielsenDistributionType:NielsenWatermarksSettings' :: NielsenWatermarksSettings
-> Maybe NielsenWatermarksDistributionTypes
nielsenDistributionType} -> Maybe NielsenWatermarksDistributionTypes
nielsenDistributionType) (\s :: NielsenWatermarksSettings
s@NielsenWatermarksSettings' {} Maybe NielsenWatermarksDistributionTypes
a -> NielsenWatermarksSettings
s {$sel:nielsenDistributionType:NielsenWatermarksSettings' :: Maybe NielsenWatermarksDistributionTypes
nielsenDistributionType = Maybe NielsenWatermarksDistributionTypes
a} :: NielsenWatermarksSettings)
nielsenWatermarksSettings_nielsenNaesIiNwSettings :: Lens.Lens' NielsenWatermarksSettings (Prelude.Maybe NielsenNaesIiNw)
nielsenWatermarksSettings_nielsenNaesIiNwSettings :: Lens' NielsenWatermarksSettings (Maybe NielsenNaesIiNw)
nielsenWatermarksSettings_nielsenNaesIiNwSettings = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\NielsenWatermarksSettings' {Maybe NielsenNaesIiNw
nielsenNaesIiNwSettings :: Maybe NielsenNaesIiNw
$sel:nielsenNaesIiNwSettings:NielsenWatermarksSettings' :: NielsenWatermarksSettings -> Maybe NielsenNaesIiNw
nielsenNaesIiNwSettings} -> Maybe NielsenNaesIiNw
nielsenNaesIiNwSettings) (\s :: NielsenWatermarksSettings
s@NielsenWatermarksSettings' {} Maybe NielsenNaesIiNw
a -> NielsenWatermarksSettings
s {$sel:nielsenNaesIiNwSettings:NielsenWatermarksSettings' :: Maybe NielsenNaesIiNw
nielsenNaesIiNwSettings = Maybe NielsenNaesIiNw
a} :: NielsenWatermarksSettings)
instance Data.FromJSON NielsenWatermarksSettings where
parseJSON :: Value -> Parser NielsenWatermarksSettings
parseJSON =
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.withObject
String
"NielsenWatermarksSettings"
( \Object
x ->
Maybe NielsenCBET
-> Maybe NielsenWatermarksDistributionTypes
-> Maybe NielsenNaesIiNw
-> NielsenWatermarksSettings
NielsenWatermarksSettings'
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"nielsenCbetSettings")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"nielsenDistributionType")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"nielsenNaesIiNwSettings")
)
instance Prelude.Hashable NielsenWatermarksSettings where
hashWithSalt :: Int -> NielsenWatermarksSettings -> Int
hashWithSalt Int
_salt NielsenWatermarksSettings' {Maybe NielsenNaesIiNw
Maybe NielsenCBET
Maybe NielsenWatermarksDistributionTypes
nielsenNaesIiNwSettings :: Maybe NielsenNaesIiNw
nielsenDistributionType :: Maybe NielsenWatermarksDistributionTypes
nielsenCbetSettings :: Maybe NielsenCBET
$sel:nielsenNaesIiNwSettings:NielsenWatermarksSettings' :: NielsenWatermarksSettings -> Maybe NielsenNaesIiNw
$sel:nielsenDistributionType:NielsenWatermarksSettings' :: NielsenWatermarksSettings
-> Maybe NielsenWatermarksDistributionTypes
$sel:nielsenCbetSettings:NielsenWatermarksSettings' :: NielsenWatermarksSettings -> Maybe NielsenCBET
..} =
Int
_salt
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe NielsenCBET
nielsenCbetSettings
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe NielsenWatermarksDistributionTypes
nielsenDistributionType
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe NielsenNaesIiNw
nielsenNaesIiNwSettings
instance Prelude.NFData NielsenWatermarksSettings where
rnf :: NielsenWatermarksSettings -> ()
rnf NielsenWatermarksSettings' {Maybe NielsenNaesIiNw
Maybe NielsenCBET
Maybe NielsenWatermarksDistributionTypes
nielsenNaesIiNwSettings :: Maybe NielsenNaesIiNw
nielsenDistributionType :: Maybe NielsenWatermarksDistributionTypes
nielsenCbetSettings :: Maybe NielsenCBET
$sel:nielsenNaesIiNwSettings:NielsenWatermarksSettings' :: NielsenWatermarksSettings -> Maybe NielsenNaesIiNw
$sel:nielsenDistributionType:NielsenWatermarksSettings' :: NielsenWatermarksSettings
-> Maybe NielsenWatermarksDistributionTypes
$sel:nielsenCbetSettings:NielsenWatermarksSettings' :: NielsenWatermarksSettings -> Maybe NielsenCBET
..} =
forall a. NFData a => a -> ()
Prelude.rnf Maybe NielsenCBET
nielsenCbetSettings
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe NielsenWatermarksDistributionTypes
nielsenDistributionType
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe NielsenNaesIiNw
nielsenNaesIiNwSettings
instance Data.ToJSON NielsenWatermarksSettings where
toJSON :: NielsenWatermarksSettings -> Value
toJSON NielsenWatermarksSettings' {Maybe NielsenNaesIiNw
Maybe NielsenCBET
Maybe NielsenWatermarksDistributionTypes
nielsenNaesIiNwSettings :: Maybe NielsenNaesIiNw
nielsenDistributionType :: Maybe NielsenWatermarksDistributionTypes
nielsenCbetSettings :: Maybe NielsenCBET
$sel:nielsenNaesIiNwSettings:NielsenWatermarksSettings' :: NielsenWatermarksSettings -> Maybe NielsenNaesIiNw
$sel:nielsenDistributionType:NielsenWatermarksSettings' :: NielsenWatermarksSettings
-> Maybe NielsenWatermarksDistributionTypes
$sel:nielsenCbetSettings:NielsenWatermarksSettings' :: NielsenWatermarksSettings -> Maybe NielsenCBET
..} =
[Pair] -> Value
Data.object
( forall a. [Maybe a] -> [a]
Prelude.catMaybes
[ (Key
"nielsenCbetSettings" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe NielsenCBET
nielsenCbetSettings,
(Key
"nielsenDistributionType" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe NielsenWatermarksDistributionTypes
nielsenDistributionType,
(Key
"nielsenNaesIiNwSettings" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe NielsenNaesIiNw
nielsenNaesIiNwSettings
]
)