module Stratosphere.MediaLive.SdiSource (
module Exports, SdiSource(..), mkSdiSource
) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import {-# SOURCE #-} Stratosphere.MediaLive.SdiSource.TagsProperty as Exports
import Stratosphere.ResourceProperties
import Stratosphere.Value
data SdiSource
=
SdiSource {SdiSource -> ()
haddock_workaround_ :: (),
SdiSource -> Maybe (Value Text)
mode :: (Prelude.Maybe (Value Prelude.Text)),
SdiSource -> Value Text
name :: (Value Prelude.Text),
SdiSource -> Maybe [TagsProperty]
tags :: (Prelude.Maybe [TagsProperty]),
SdiSource -> Value Text
type' :: (Value Prelude.Text)}
deriving stock (SdiSource -> SdiSource -> Bool
(SdiSource -> SdiSource -> Bool)
-> (SdiSource -> SdiSource -> Bool) -> Eq SdiSource
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: SdiSource -> SdiSource -> Bool
== :: SdiSource -> SdiSource -> Bool
$c/= :: SdiSource -> SdiSource -> Bool
/= :: SdiSource -> SdiSource -> Bool
Prelude.Eq, Int -> SdiSource -> ShowS
[SdiSource] -> ShowS
SdiSource -> String
(Int -> SdiSource -> ShowS)
-> (SdiSource -> String)
-> ([SdiSource] -> ShowS)
-> Show SdiSource
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> SdiSource -> ShowS
showsPrec :: Int -> SdiSource -> ShowS
$cshow :: SdiSource -> String
show :: SdiSource -> String
$cshowList :: [SdiSource] -> ShowS
showList :: [SdiSource] -> ShowS
Prelude.Show)
mkSdiSource ::
Value Prelude.Text -> Value Prelude.Text -> SdiSource
mkSdiSource :: Value Text -> Value Text -> SdiSource
mkSdiSource Value Text
name Value Text
type'
= SdiSource
{haddock_workaround_ :: ()
haddock_workaround_ = (), name :: Value Text
name = Value Text
name, type' :: Value Text
type' = Value Text
type',
mode :: Maybe (Value Text)
mode = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing, tags :: Maybe [TagsProperty]
tags = Maybe [TagsProperty]
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties SdiSource where
toResourceProperties :: SdiSource -> ResourceProperties
toResourceProperties SdiSource {Maybe [TagsProperty]
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: SdiSource -> ()
mode :: SdiSource -> Maybe (Value Text)
name :: SdiSource -> Value Text
tags :: SdiSource -> Maybe [TagsProperty]
type' :: SdiSource -> Value Text
haddock_workaround_ :: ()
mode :: Maybe (Value Text)
name :: Value Text
tags :: Maybe [TagsProperty]
type' :: Value Text
..}
= ResourceProperties
{awsType :: Text
awsType = Text
"AWS::MediaLive::SdiSource",
supportsTags :: Bool
supportsTags = Bool
Prelude.True,
properties :: Object
properties = [Item Object] -> Object
forall l. IsList l => [Item l] -> l
Prelude.fromList
([(Key, Value)] -> [(Key, Value)] -> [(Key, Value)]
forall a. Semigroup a => a -> a -> a
(Prelude.<>)
[Key
"Name" 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..= Value Text
name, Key
"Type" 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..= Value Text
type']
([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
"Mode" (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)
mode,
Key -> [TagsProperty] -> (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" ([TagsProperty] -> (Key, Value))
-> Maybe [TagsProperty] -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [TagsProperty]
tags]))}
instance JSON.ToJSON SdiSource where
toJSON :: SdiSource -> Value
toJSON SdiSource {Maybe [TagsProperty]
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: SdiSource -> ()
mode :: SdiSource -> Maybe (Value Text)
name :: SdiSource -> Value Text
tags :: SdiSource -> Maybe [TagsProperty]
type' :: SdiSource -> Value Text
haddock_workaround_ :: ()
mode :: Maybe (Value Text)
name :: Value Text
tags :: Maybe [TagsProperty]
type' :: Value Text
..}
= [(Key, Value)] -> Value
JSON.object
([Item [(Key, Value)]] -> [(Key, Value)]
forall l. IsList l => [Item l] -> l
Prelude.fromList
([(Key, Value)] -> [(Key, Value)] -> [(Key, Value)]
forall a. Semigroup a => a -> a -> a
(Prelude.<>)
[Key
"Name" 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..= Value Text
name, Key
"Type" 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..= Value Text
type']
([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
"Mode" (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)
mode,
Key -> [TagsProperty] -> (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" ([TagsProperty] -> (Key, Value))
-> Maybe [TagsProperty] -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [TagsProperty]
tags])))
instance Property "Mode" SdiSource where
type PropertyType "Mode" SdiSource = Value Prelude.Text
set :: PropertyType "Mode" SdiSource -> SdiSource -> SdiSource
set PropertyType "Mode" SdiSource
newValue SdiSource {Maybe [TagsProperty]
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: SdiSource -> ()
mode :: SdiSource -> Maybe (Value Text)
name :: SdiSource -> Value Text
tags :: SdiSource -> Maybe [TagsProperty]
type' :: SdiSource -> Value Text
haddock_workaround_ :: ()
mode :: Maybe (Value Text)
name :: Value Text
tags :: Maybe [TagsProperty]
type' :: Value Text
..}
= SdiSource {mode :: Maybe (Value Text)
mode = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "Mode" SdiSource
Value Text
newValue, Maybe [TagsProperty]
()
Value Text
haddock_workaround_ :: ()
name :: Value Text
tags :: Maybe [TagsProperty]
type' :: Value Text
haddock_workaround_ :: ()
name :: Value Text
tags :: Maybe [TagsProperty]
type' :: Value Text
..}
instance Property "Name" SdiSource where
type PropertyType "Name" SdiSource = Value Prelude.Text
set :: PropertyType "Name" SdiSource -> SdiSource -> SdiSource
set PropertyType "Name" SdiSource
newValue SdiSource {Maybe [TagsProperty]
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: SdiSource -> ()
mode :: SdiSource -> Maybe (Value Text)
name :: SdiSource -> Value Text
tags :: SdiSource -> Maybe [TagsProperty]
type' :: SdiSource -> Value Text
haddock_workaround_ :: ()
mode :: Maybe (Value Text)
name :: Value Text
tags :: Maybe [TagsProperty]
type' :: Value Text
..} = SdiSource {name :: Value Text
name = PropertyType "Name" SdiSource
Value Text
newValue, Maybe [TagsProperty]
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ()
mode :: Maybe (Value Text)
tags :: Maybe [TagsProperty]
type' :: Value Text
haddock_workaround_ :: ()
mode :: Maybe (Value Text)
tags :: Maybe [TagsProperty]
type' :: Value Text
..}
instance Property "Tags" SdiSource where
type PropertyType "Tags" SdiSource = [TagsProperty]
set :: PropertyType "Tags" SdiSource -> SdiSource -> SdiSource
set PropertyType "Tags" SdiSource
newValue SdiSource {Maybe [TagsProperty]
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: SdiSource -> ()
mode :: SdiSource -> Maybe (Value Text)
name :: SdiSource -> Value Text
tags :: SdiSource -> Maybe [TagsProperty]
type' :: SdiSource -> Value Text
haddock_workaround_ :: ()
mode :: Maybe (Value Text)
name :: Value Text
tags :: Maybe [TagsProperty]
type' :: Value Text
..}
= SdiSource {tags :: Maybe [TagsProperty]
tags = [TagsProperty] -> Maybe [TagsProperty]
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure [TagsProperty]
PropertyType "Tags" SdiSource
newValue, Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ()
mode :: Maybe (Value Text)
name :: Value Text
type' :: Value Text
haddock_workaround_ :: ()
mode :: Maybe (Value Text)
name :: Value Text
type' :: Value Text
..}
instance Property "Type" SdiSource where
type PropertyType "Type" SdiSource = Value Prelude.Text
set :: PropertyType "Type" SdiSource -> SdiSource -> SdiSource
set PropertyType "Type" SdiSource
newValue SdiSource {Maybe [TagsProperty]
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: SdiSource -> ()
mode :: SdiSource -> Maybe (Value Text)
name :: SdiSource -> Value Text
tags :: SdiSource -> Maybe [TagsProperty]
type' :: SdiSource -> Value Text
haddock_workaround_ :: ()
mode :: Maybe (Value Text)
name :: Value Text
tags :: Maybe [TagsProperty]
type' :: Value Text
..} = SdiSource {type' :: Value Text
type' = PropertyType "Type" SdiSource
Value Text
newValue, Maybe [TagsProperty]
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ()
mode :: Maybe (Value Text)
name :: Value Text
tags :: Maybe [TagsProperty]
haddock_workaround_ :: ()
mode :: Maybe (Value Text)
name :: Value Text
tags :: Maybe [TagsProperty]
..}