module Stratosphere.IVS.EncoderConfiguration (
module Exports, EncoderConfiguration(..), mkEncoderConfiguration
) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import {-# SOURCE #-} Stratosphere.IVS.EncoderConfiguration.VideoProperty as Exports
import Stratosphere.ResourceProperties
import Stratosphere.Tag
import Stratosphere.Value
data EncoderConfiguration
=
EncoderConfiguration {EncoderConfiguration -> ()
haddock_workaround_ :: (),
EncoderConfiguration -> Maybe (Value Text)
name :: (Prelude.Maybe (Value Prelude.Text)),
EncoderConfiguration -> Maybe [Tag]
tags :: (Prelude.Maybe [Tag]),
EncoderConfiguration -> Maybe VideoProperty
video :: (Prelude.Maybe VideoProperty)}
deriving stock (EncoderConfiguration -> EncoderConfiguration -> Bool
(EncoderConfiguration -> EncoderConfiguration -> Bool)
-> (EncoderConfiguration -> EncoderConfiguration -> Bool)
-> Eq EncoderConfiguration
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: EncoderConfiguration -> EncoderConfiguration -> Bool
== :: EncoderConfiguration -> EncoderConfiguration -> Bool
$c/= :: EncoderConfiguration -> EncoderConfiguration -> Bool
/= :: EncoderConfiguration -> EncoderConfiguration -> Bool
Prelude.Eq, Int -> EncoderConfiguration -> ShowS
[EncoderConfiguration] -> ShowS
EncoderConfiguration -> String
(Int -> EncoderConfiguration -> ShowS)
-> (EncoderConfiguration -> String)
-> ([EncoderConfiguration] -> ShowS)
-> Show EncoderConfiguration
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> EncoderConfiguration -> ShowS
showsPrec :: Int -> EncoderConfiguration -> ShowS
$cshow :: EncoderConfiguration -> String
show :: EncoderConfiguration -> String
$cshowList :: [EncoderConfiguration] -> ShowS
showList :: [EncoderConfiguration] -> ShowS
Prelude.Show)
mkEncoderConfiguration :: EncoderConfiguration
mkEncoderConfiguration :: EncoderConfiguration
mkEncoderConfiguration
= EncoderConfiguration
{haddock_workaround_ :: ()
haddock_workaround_ = (), name :: Maybe (Value Text)
name = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing,
tags :: Maybe [Tag]
tags = Maybe [Tag]
forall a. Maybe a
Prelude.Nothing, video :: Maybe VideoProperty
video = Maybe VideoProperty
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties EncoderConfiguration where
toResourceProperties :: EncoderConfiguration -> ResourceProperties
toResourceProperties EncoderConfiguration {Maybe [Tag]
Maybe (Value Text)
Maybe VideoProperty
()
haddock_workaround_ :: EncoderConfiguration -> ()
name :: EncoderConfiguration -> Maybe (Value Text)
tags :: EncoderConfiguration -> Maybe [Tag]
video :: EncoderConfiguration -> Maybe VideoProperty
haddock_workaround_ :: ()
name :: Maybe (Value Text)
tags :: Maybe [Tag]
video :: Maybe VideoProperty
..}
= ResourceProperties
{awsType :: Text
awsType = Text
"AWS::IVS::EncoderConfiguration",
supportsTags :: Bool
supportsTags = Bool
Prelude.True,
properties :: Object
properties = [Item Object] -> Object
forall l. IsList l => [Item l] -> l
Prelude.fromList
([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[Key -> Value Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"Name" (Value Text -> (Key, Value))
-> Maybe (Value Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Text)
name,
Key -> [Tag] -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"Tags" ([Tag] -> (Key, Value)) -> Maybe [Tag] -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [Tag]
tags,
Key -> VideoProperty -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"Video" (VideoProperty -> (Key, Value))
-> Maybe VideoProperty -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe VideoProperty
video])}
instance JSON.ToJSON EncoderConfiguration where
toJSON :: EncoderConfiguration -> Value
toJSON EncoderConfiguration {Maybe [Tag]
Maybe (Value Text)
Maybe VideoProperty
()
haddock_workaround_ :: EncoderConfiguration -> ()
name :: EncoderConfiguration -> Maybe (Value Text)
tags :: EncoderConfiguration -> Maybe [Tag]
video :: EncoderConfiguration -> Maybe VideoProperty
haddock_workaround_ :: ()
name :: Maybe (Value Text)
tags :: Maybe [Tag]
video :: Maybe VideoProperty
..}
= [(Key, Value)] -> Value
JSON.object
([Item [(Key, Value)]] -> [(Key, Value)]
forall l. IsList l => [Item l] -> l
Prelude.fromList
([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[Key -> Value Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"Name" (Value Text -> (Key, Value))
-> Maybe (Value Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Text)
name,
Key -> [Tag] -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"Tags" ([Tag] -> (Key, Value)) -> Maybe [Tag] -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [Tag]
tags,
Key -> VideoProperty -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"Video" (VideoProperty -> (Key, Value))
-> Maybe VideoProperty -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe VideoProperty
video]))
instance Property "Name" EncoderConfiguration where
type PropertyType "Name" EncoderConfiguration = Value Prelude.Text
set :: PropertyType "Name" EncoderConfiguration
-> EncoderConfiguration -> EncoderConfiguration
set PropertyType "Name" EncoderConfiguration
newValue EncoderConfiguration {Maybe [Tag]
Maybe (Value Text)
Maybe VideoProperty
()
haddock_workaround_ :: EncoderConfiguration -> ()
name :: EncoderConfiguration -> Maybe (Value Text)
tags :: EncoderConfiguration -> Maybe [Tag]
video :: EncoderConfiguration -> Maybe VideoProperty
haddock_workaround_ :: ()
name :: Maybe (Value Text)
tags :: Maybe [Tag]
video :: Maybe VideoProperty
..}
= EncoderConfiguration {name :: Maybe (Value Text)
name = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "Name" EncoderConfiguration
Value Text
newValue, Maybe [Tag]
Maybe VideoProperty
()
haddock_workaround_ :: ()
tags :: Maybe [Tag]
video :: Maybe VideoProperty
haddock_workaround_ :: ()
tags :: Maybe [Tag]
video :: Maybe VideoProperty
..}
instance Property "Tags" EncoderConfiguration where
type PropertyType "Tags" EncoderConfiguration = [Tag]
set :: PropertyType "Tags" EncoderConfiguration
-> EncoderConfiguration -> EncoderConfiguration
set PropertyType "Tags" EncoderConfiguration
newValue EncoderConfiguration {Maybe [Tag]
Maybe (Value Text)
Maybe VideoProperty
()
haddock_workaround_ :: EncoderConfiguration -> ()
name :: EncoderConfiguration -> Maybe (Value Text)
tags :: EncoderConfiguration -> Maybe [Tag]
video :: EncoderConfiguration -> Maybe VideoProperty
haddock_workaround_ :: ()
name :: Maybe (Value Text)
tags :: Maybe [Tag]
video :: Maybe VideoProperty
..}
= EncoderConfiguration {tags :: Maybe [Tag]
tags = [Tag] -> Maybe [Tag]
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure [Tag]
PropertyType "Tags" EncoderConfiguration
newValue, Maybe (Value Text)
Maybe VideoProperty
()
haddock_workaround_ :: ()
name :: Maybe (Value Text)
video :: Maybe VideoProperty
haddock_workaround_ :: ()
name :: Maybe (Value Text)
video :: Maybe VideoProperty
..}
instance Property "Video" EncoderConfiguration where
type PropertyType "Video" EncoderConfiguration = VideoProperty
set :: PropertyType "Video" EncoderConfiguration
-> EncoderConfiguration -> EncoderConfiguration
set PropertyType "Video" EncoderConfiguration
newValue EncoderConfiguration {Maybe [Tag]
Maybe (Value Text)
Maybe VideoProperty
()
haddock_workaround_ :: EncoderConfiguration -> ()
name :: EncoderConfiguration -> Maybe (Value Text)
tags :: EncoderConfiguration -> Maybe [Tag]
video :: EncoderConfiguration -> Maybe VideoProperty
haddock_workaround_ :: ()
name :: Maybe (Value Text)
tags :: Maybe [Tag]
video :: Maybe VideoProperty
..}
= EncoderConfiguration {video :: Maybe VideoProperty
video = VideoProperty -> Maybe VideoProperty
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "Video" EncoderConfiguration
VideoProperty
newValue, Maybe [Tag]
Maybe (Value Text)
()
haddock_workaround_ :: ()
name :: Maybe (Value Text)
tags :: Maybe [Tag]
haddock_workaround_ :: ()
name :: Maybe (Value Text)
tags :: Maybe [Tag]
..}