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