module Stratosphere.MediaPackageV2.OriginEndpoint.DashUtcTimingProperty (
        DashUtcTimingProperty(..), mkDashUtcTimingProperty
    ) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data DashUtcTimingProperty
  = -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-mediapackagev2-originendpoint-dashutctiming.html>
    DashUtcTimingProperty {DashUtcTimingProperty -> ()
haddock_workaround_ :: (),
                           -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-mediapackagev2-originendpoint-dashutctiming.html#cfn-mediapackagev2-originendpoint-dashutctiming-timingmode>
                           DashUtcTimingProperty -> Maybe (Value Text)
timingMode :: (Prelude.Maybe (Value Prelude.Text)),
                           -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-mediapackagev2-originendpoint-dashutctiming.html#cfn-mediapackagev2-originendpoint-dashutctiming-timingsource>
                           DashUtcTimingProperty -> Maybe (Value Text)
timingSource :: (Prelude.Maybe (Value Prelude.Text))}
  deriving stock (DashUtcTimingProperty -> DashUtcTimingProperty -> Bool
(DashUtcTimingProperty -> DashUtcTimingProperty -> Bool)
-> (DashUtcTimingProperty -> DashUtcTimingProperty -> Bool)
-> Eq DashUtcTimingProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: DashUtcTimingProperty -> DashUtcTimingProperty -> Bool
== :: DashUtcTimingProperty -> DashUtcTimingProperty -> Bool
$c/= :: DashUtcTimingProperty -> DashUtcTimingProperty -> Bool
/= :: DashUtcTimingProperty -> DashUtcTimingProperty -> Bool
Prelude.Eq, Int -> DashUtcTimingProperty -> ShowS
[DashUtcTimingProperty] -> ShowS
DashUtcTimingProperty -> String
(Int -> DashUtcTimingProperty -> ShowS)
-> (DashUtcTimingProperty -> String)
-> ([DashUtcTimingProperty] -> ShowS)
-> Show DashUtcTimingProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> DashUtcTimingProperty -> ShowS
showsPrec :: Int -> DashUtcTimingProperty -> ShowS
$cshow :: DashUtcTimingProperty -> String
show :: DashUtcTimingProperty -> String
$cshowList :: [DashUtcTimingProperty] -> ShowS
showList :: [DashUtcTimingProperty] -> ShowS
Prelude.Show)
mkDashUtcTimingProperty :: DashUtcTimingProperty
mkDashUtcTimingProperty :: DashUtcTimingProperty
mkDashUtcTimingProperty
  = DashUtcTimingProperty
      {haddock_workaround_ :: ()
haddock_workaround_ = (), timingMode :: Maybe (Value Text)
timingMode = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing,
       timingSource :: Maybe (Value Text)
timingSource = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties DashUtcTimingProperty where
  toResourceProperties :: DashUtcTimingProperty -> ResourceProperties
toResourceProperties DashUtcTimingProperty {Maybe (Value Text)
()
haddock_workaround_ :: DashUtcTimingProperty -> ()
timingMode :: DashUtcTimingProperty -> Maybe (Value Text)
timingSource :: DashUtcTimingProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
timingMode :: Maybe (Value Text)
timingSource :: Maybe (Value Text)
..}
    = ResourceProperties
        {awsType :: Text
awsType = Text
"AWS::MediaPackageV2::OriginEndpoint.DashUtcTiming",
         supportsTags :: Bool
supportsTags = Bool
Prelude.False,
         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
"TimingMode" (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)
timingMode,
                            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
"TimingSource" (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)
timingSource])}
instance JSON.ToJSON DashUtcTimingProperty where
  toJSON :: DashUtcTimingProperty -> Value
toJSON DashUtcTimingProperty {Maybe (Value Text)
()
haddock_workaround_ :: DashUtcTimingProperty -> ()
timingMode :: DashUtcTimingProperty -> Maybe (Value Text)
timingSource :: DashUtcTimingProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
timingMode :: Maybe (Value Text)
timingSource :: Maybe (Value Text)
..}
    = [(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
"TimingMode" (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)
timingMode,
               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
"TimingSource" (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)
timingSource]))
instance Property "TimingMode" DashUtcTimingProperty where
  type PropertyType "TimingMode" DashUtcTimingProperty = Value Prelude.Text
  set :: PropertyType "TimingMode" DashUtcTimingProperty
-> DashUtcTimingProperty -> DashUtcTimingProperty
set PropertyType "TimingMode" DashUtcTimingProperty
newValue DashUtcTimingProperty {Maybe (Value Text)
()
haddock_workaround_ :: DashUtcTimingProperty -> ()
timingMode :: DashUtcTimingProperty -> Maybe (Value Text)
timingSource :: DashUtcTimingProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
timingMode :: Maybe (Value Text)
timingSource :: Maybe (Value Text)
..}
    = DashUtcTimingProperty {timingMode :: Maybe (Value Text)
timingMode = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "TimingMode" DashUtcTimingProperty
Value Text
newValue, Maybe (Value Text)
()
haddock_workaround_ :: ()
timingSource :: Maybe (Value Text)
haddock_workaround_ :: ()
timingSource :: Maybe (Value Text)
..}
instance Property "TimingSource" DashUtcTimingProperty where
  type PropertyType "TimingSource" DashUtcTimingProperty = Value Prelude.Text
  set :: PropertyType "TimingSource" DashUtcTimingProperty
-> DashUtcTimingProperty -> DashUtcTimingProperty
set PropertyType "TimingSource" DashUtcTimingProperty
newValue DashUtcTimingProperty {Maybe (Value Text)
()
haddock_workaround_ :: DashUtcTimingProperty -> ()
timingMode :: DashUtcTimingProperty -> Maybe (Value Text)
timingSource :: DashUtcTimingProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
timingMode :: Maybe (Value Text)
timingSource :: Maybe (Value Text)
..}
    = DashUtcTimingProperty {timingSource :: Maybe (Value Text)
timingSource = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "TimingSource" DashUtcTimingProperty
Value Text
newValue, Maybe (Value Text)
()
haddock_workaround_ :: ()
timingMode :: Maybe (Value Text)
haddock_workaround_ :: ()
timingMode :: Maybe (Value Text)
..}