{-# 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.MediaConvert.Types.EmbeddedDestinationSettings where
import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import qualified Amazonka.Prelude as Prelude
data EmbeddedDestinationSettings = EmbeddedDestinationSettings'
{
EmbeddedDestinationSettings -> Maybe Natural
destination608ChannelNumber :: Prelude.Maybe Prelude.Natural,
EmbeddedDestinationSettings -> Maybe Natural
destination708ServiceNumber :: Prelude.Maybe Prelude.Natural
}
deriving (EmbeddedDestinationSettings -> EmbeddedDestinationSettings -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: EmbeddedDestinationSettings -> EmbeddedDestinationSettings -> Bool
$c/= :: EmbeddedDestinationSettings -> EmbeddedDestinationSettings -> Bool
== :: EmbeddedDestinationSettings -> EmbeddedDestinationSettings -> Bool
$c== :: EmbeddedDestinationSettings -> EmbeddedDestinationSettings -> Bool
Prelude.Eq, ReadPrec [EmbeddedDestinationSettings]
ReadPrec EmbeddedDestinationSettings
Int -> ReadS EmbeddedDestinationSettings
ReadS [EmbeddedDestinationSettings]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [EmbeddedDestinationSettings]
$creadListPrec :: ReadPrec [EmbeddedDestinationSettings]
readPrec :: ReadPrec EmbeddedDestinationSettings
$creadPrec :: ReadPrec EmbeddedDestinationSettings
readList :: ReadS [EmbeddedDestinationSettings]
$creadList :: ReadS [EmbeddedDestinationSettings]
readsPrec :: Int -> ReadS EmbeddedDestinationSettings
$creadsPrec :: Int -> ReadS EmbeddedDestinationSettings
Prelude.Read, Int -> EmbeddedDestinationSettings -> ShowS
[EmbeddedDestinationSettings] -> ShowS
EmbeddedDestinationSettings -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [EmbeddedDestinationSettings] -> ShowS
$cshowList :: [EmbeddedDestinationSettings] -> ShowS
show :: EmbeddedDestinationSettings -> String
$cshow :: EmbeddedDestinationSettings -> String
showsPrec :: Int -> EmbeddedDestinationSettings -> ShowS
$cshowsPrec :: Int -> EmbeddedDestinationSettings -> ShowS
Prelude.Show, forall x.
Rep EmbeddedDestinationSettings x -> EmbeddedDestinationSettings
forall x.
EmbeddedDestinationSettings -> Rep EmbeddedDestinationSettings x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep EmbeddedDestinationSettings x -> EmbeddedDestinationSettings
$cfrom :: forall x.
EmbeddedDestinationSettings -> Rep EmbeddedDestinationSettings x
Prelude.Generic)
newEmbeddedDestinationSettings ::
EmbeddedDestinationSettings
newEmbeddedDestinationSettings :: EmbeddedDestinationSettings
newEmbeddedDestinationSettings =
EmbeddedDestinationSettings'
{ $sel:destination608ChannelNumber:EmbeddedDestinationSettings' :: Maybe Natural
destination608ChannelNumber =
forall a. Maybe a
Prelude.Nothing,
$sel:destination708ServiceNumber:EmbeddedDestinationSettings' :: Maybe Natural
destination708ServiceNumber = forall a. Maybe a
Prelude.Nothing
}
embeddedDestinationSettings_destination608ChannelNumber :: Lens.Lens' EmbeddedDestinationSettings (Prelude.Maybe Prelude.Natural)
embeddedDestinationSettings_destination608ChannelNumber :: Lens' EmbeddedDestinationSettings (Maybe Natural)
embeddedDestinationSettings_destination608ChannelNumber = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\EmbeddedDestinationSettings' {Maybe Natural
destination608ChannelNumber :: Maybe Natural
$sel:destination608ChannelNumber:EmbeddedDestinationSettings' :: EmbeddedDestinationSettings -> Maybe Natural
destination608ChannelNumber} -> Maybe Natural
destination608ChannelNumber) (\s :: EmbeddedDestinationSettings
s@EmbeddedDestinationSettings' {} Maybe Natural
a -> EmbeddedDestinationSettings
s {$sel:destination608ChannelNumber:EmbeddedDestinationSettings' :: Maybe Natural
destination608ChannelNumber = Maybe Natural
a} :: EmbeddedDestinationSettings)
embeddedDestinationSettings_destination708ServiceNumber :: Lens.Lens' EmbeddedDestinationSettings (Prelude.Maybe Prelude.Natural)
embeddedDestinationSettings_destination708ServiceNumber :: Lens' EmbeddedDestinationSettings (Maybe Natural)
embeddedDestinationSettings_destination708ServiceNumber = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\EmbeddedDestinationSettings' {Maybe Natural
destination708ServiceNumber :: Maybe Natural
$sel:destination708ServiceNumber:EmbeddedDestinationSettings' :: EmbeddedDestinationSettings -> Maybe Natural
destination708ServiceNumber} -> Maybe Natural
destination708ServiceNumber) (\s :: EmbeddedDestinationSettings
s@EmbeddedDestinationSettings' {} Maybe Natural
a -> EmbeddedDestinationSettings
s {$sel:destination708ServiceNumber:EmbeddedDestinationSettings' :: Maybe Natural
destination708ServiceNumber = Maybe Natural
a} :: EmbeddedDestinationSettings)
instance Data.FromJSON EmbeddedDestinationSettings where
parseJSON :: Value -> Parser EmbeddedDestinationSettings
parseJSON =
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.withObject
String
"EmbeddedDestinationSettings"
( \Object
x ->
Maybe Natural -> Maybe Natural -> EmbeddedDestinationSettings
EmbeddedDestinationSettings'
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
"destination608ChannelNumber")
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
"destination708ServiceNumber")
)
instance Prelude.Hashable EmbeddedDestinationSettings where
hashWithSalt :: Int -> EmbeddedDestinationSettings -> Int
hashWithSalt Int
_salt EmbeddedDestinationSettings' {Maybe Natural
destination708ServiceNumber :: Maybe Natural
destination608ChannelNumber :: Maybe Natural
$sel:destination708ServiceNumber:EmbeddedDestinationSettings' :: EmbeddedDestinationSettings -> Maybe Natural
$sel:destination608ChannelNumber:EmbeddedDestinationSettings' :: EmbeddedDestinationSettings -> Maybe Natural
..} =
Int
_salt
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Natural
destination608ChannelNumber
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Natural
destination708ServiceNumber
instance Prelude.NFData EmbeddedDestinationSettings where
rnf :: EmbeddedDestinationSettings -> ()
rnf EmbeddedDestinationSettings' {Maybe Natural
destination708ServiceNumber :: Maybe Natural
destination608ChannelNumber :: Maybe Natural
$sel:destination708ServiceNumber:EmbeddedDestinationSettings' :: EmbeddedDestinationSettings -> Maybe Natural
$sel:destination608ChannelNumber:EmbeddedDestinationSettings' :: EmbeddedDestinationSettings -> Maybe Natural
..} =
forall a. NFData a => a -> ()
Prelude.rnf Maybe Natural
destination608ChannelNumber
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Natural
destination708ServiceNumber
instance Data.ToJSON EmbeddedDestinationSettings where
toJSON :: EmbeddedDestinationSettings -> Value
toJSON EmbeddedDestinationSettings' {Maybe Natural
destination708ServiceNumber :: Maybe Natural
destination608ChannelNumber :: Maybe Natural
$sel:destination708ServiceNumber:EmbeddedDestinationSettings' :: EmbeddedDestinationSettings -> Maybe Natural
$sel:destination608ChannelNumber:EmbeddedDestinationSettings' :: EmbeddedDestinationSettings -> Maybe Natural
..} =
[Pair] -> Value
Data.object
( forall a. [Maybe a] -> [a]
Prelude.catMaybes
[ (Key
"destination608ChannelNumber" 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 Natural
destination608ChannelNumber,
(Key
"destination708ServiceNumber" 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 Natural
destination708ServiceNumber
]
)