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