module Stratosphere.QuickSight.Dashboard.ForecastScenarioProperty (
module Exports, ForecastScenarioProperty(..),
mkForecastScenarioProperty
) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import {-# SOURCE #-} Stratosphere.QuickSight.Dashboard.WhatIfPointScenarioProperty as Exports
import {-# SOURCE #-} Stratosphere.QuickSight.Dashboard.WhatIfRangeScenarioProperty as Exports
import Stratosphere.ResourceProperties
data ForecastScenarioProperty
=
ForecastScenarioProperty {ForecastScenarioProperty -> ()
haddock_workaround_ :: (),
ForecastScenarioProperty -> Maybe WhatIfPointScenarioProperty
whatIfPointScenario :: (Prelude.Maybe WhatIfPointScenarioProperty),
ForecastScenarioProperty -> Maybe WhatIfRangeScenarioProperty
whatIfRangeScenario :: (Prelude.Maybe WhatIfRangeScenarioProperty)}
deriving stock (ForecastScenarioProperty -> ForecastScenarioProperty -> Bool
(ForecastScenarioProperty -> ForecastScenarioProperty -> Bool)
-> (ForecastScenarioProperty -> ForecastScenarioProperty -> Bool)
-> Eq ForecastScenarioProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: ForecastScenarioProperty -> ForecastScenarioProperty -> Bool
== :: ForecastScenarioProperty -> ForecastScenarioProperty -> Bool
$c/= :: ForecastScenarioProperty -> ForecastScenarioProperty -> Bool
/= :: ForecastScenarioProperty -> ForecastScenarioProperty -> Bool
Prelude.Eq, Int -> ForecastScenarioProperty -> ShowS
[ForecastScenarioProperty] -> ShowS
ForecastScenarioProperty -> String
(Int -> ForecastScenarioProperty -> ShowS)
-> (ForecastScenarioProperty -> String)
-> ([ForecastScenarioProperty] -> ShowS)
-> Show ForecastScenarioProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> ForecastScenarioProperty -> ShowS
showsPrec :: Int -> ForecastScenarioProperty -> ShowS
$cshow :: ForecastScenarioProperty -> String
show :: ForecastScenarioProperty -> String
$cshowList :: [ForecastScenarioProperty] -> ShowS
showList :: [ForecastScenarioProperty] -> ShowS
Prelude.Show)
mkForecastScenarioProperty :: ForecastScenarioProperty
mkForecastScenarioProperty :: ForecastScenarioProperty
mkForecastScenarioProperty
= ForecastScenarioProperty
{haddock_workaround_ :: ()
haddock_workaround_ = (), whatIfPointScenario :: Maybe WhatIfPointScenarioProperty
whatIfPointScenario = Maybe WhatIfPointScenarioProperty
forall a. Maybe a
Prelude.Nothing,
whatIfRangeScenario :: Maybe WhatIfRangeScenarioProperty
whatIfRangeScenario = Maybe WhatIfRangeScenarioProperty
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties ForecastScenarioProperty where
toResourceProperties :: ForecastScenarioProperty -> ResourceProperties
toResourceProperties ForecastScenarioProperty {Maybe WhatIfPointScenarioProperty
Maybe WhatIfRangeScenarioProperty
()
haddock_workaround_ :: ForecastScenarioProperty -> ()
whatIfPointScenario :: ForecastScenarioProperty -> Maybe WhatIfPointScenarioProperty
whatIfRangeScenario :: ForecastScenarioProperty -> Maybe WhatIfRangeScenarioProperty
haddock_workaround_ :: ()
whatIfPointScenario :: Maybe WhatIfPointScenarioProperty
whatIfRangeScenario :: Maybe WhatIfRangeScenarioProperty
..}
= ResourceProperties
{awsType :: Text
awsType = Text
"AWS::QuickSight::Dashboard.ForecastScenario",
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 -> WhatIfPointScenarioProperty -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"WhatIfPointScenario" (WhatIfPointScenarioProperty -> (Key, Value))
-> Maybe WhatIfPointScenarioProperty -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe WhatIfPointScenarioProperty
whatIfPointScenario,
Key -> WhatIfRangeScenarioProperty -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"WhatIfRangeScenario" (WhatIfRangeScenarioProperty -> (Key, Value))
-> Maybe WhatIfRangeScenarioProperty -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe WhatIfRangeScenarioProperty
whatIfRangeScenario])}
instance JSON.ToJSON ForecastScenarioProperty where
toJSON :: ForecastScenarioProperty -> Value
toJSON ForecastScenarioProperty {Maybe WhatIfPointScenarioProperty
Maybe WhatIfRangeScenarioProperty
()
haddock_workaround_ :: ForecastScenarioProperty -> ()
whatIfPointScenario :: ForecastScenarioProperty -> Maybe WhatIfPointScenarioProperty
whatIfRangeScenario :: ForecastScenarioProperty -> Maybe WhatIfRangeScenarioProperty
haddock_workaround_ :: ()
whatIfPointScenario :: Maybe WhatIfPointScenarioProperty
whatIfRangeScenario :: Maybe WhatIfRangeScenarioProperty
..}
= [(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 -> WhatIfPointScenarioProperty -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"WhatIfPointScenario" (WhatIfPointScenarioProperty -> (Key, Value))
-> Maybe WhatIfPointScenarioProperty -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe WhatIfPointScenarioProperty
whatIfPointScenario,
Key -> WhatIfRangeScenarioProperty -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"WhatIfRangeScenario" (WhatIfRangeScenarioProperty -> (Key, Value))
-> Maybe WhatIfRangeScenarioProperty -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe WhatIfRangeScenarioProperty
whatIfRangeScenario]))
instance Property "WhatIfPointScenario" ForecastScenarioProperty where
type PropertyType "WhatIfPointScenario" ForecastScenarioProperty = WhatIfPointScenarioProperty
set :: PropertyType "WhatIfPointScenario" ForecastScenarioProperty
-> ForecastScenarioProperty -> ForecastScenarioProperty
set PropertyType "WhatIfPointScenario" ForecastScenarioProperty
newValue ForecastScenarioProperty {Maybe WhatIfPointScenarioProperty
Maybe WhatIfRangeScenarioProperty
()
haddock_workaround_ :: ForecastScenarioProperty -> ()
whatIfPointScenario :: ForecastScenarioProperty -> Maybe WhatIfPointScenarioProperty
whatIfRangeScenario :: ForecastScenarioProperty -> Maybe WhatIfRangeScenarioProperty
haddock_workaround_ :: ()
whatIfPointScenario :: Maybe WhatIfPointScenarioProperty
whatIfRangeScenario :: Maybe WhatIfRangeScenarioProperty
..}
= ForecastScenarioProperty
{whatIfPointScenario :: Maybe WhatIfPointScenarioProperty
whatIfPointScenario = WhatIfPointScenarioProperty -> Maybe WhatIfPointScenarioProperty
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "WhatIfPointScenario" ForecastScenarioProperty
WhatIfPointScenarioProperty
newValue, Maybe WhatIfRangeScenarioProperty
()
haddock_workaround_ :: ()
whatIfRangeScenario :: Maybe WhatIfRangeScenarioProperty
haddock_workaround_ :: ()
whatIfRangeScenario :: Maybe WhatIfRangeScenarioProperty
..}
instance Property "WhatIfRangeScenario" ForecastScenarioProperty where
type PropertyType "WhatIfRangeScenario" ForecastScenarioProperty = WhatIfRangeScenarioProperty
set :: PropertyType "WhatIfRangeScenario" ForecastScenarioProperty
-> ForecastScenarioProperty -> ForecastScenarioProperty
set PropertyType "WhatIfRangeScenario" ForecastScenarioProperty
newValue ForecastScenarioProperty {Maybe WhatIfPointScenarioProperty
Maybe WhatIfRangeScenarioProperty
()
haddock_workaround_ :: ForecastScenarioProperty -> ()
whatIfPointScenario :: ForecastScenarioProperty -> Maybe WhatIfPointScenarioProperty
whatIfRangeScenario :: ForecastScenarioProperty -> Maybe WhatIfRangeScenarioProperty
haddock_workaround_ :: ()
whatIfPointScenario :: Maybe WhatIfPointScenarioProperty
whatIfRangeScenario :: Maybe WhatIfRangeScenarioProperty
..}
= ForecastScenarioProperty
{whatIfRangeScenario :: Maybe WhatIfRangeScenarioProperty
whatIfRangeScenario = WhatIfRangeScenarioProperty -> Maybe WhatIfRangeScenarioProperty
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "WhatIfRangeScenario" ForecastScenarioProperty
WhatIfRangeScenarioProperty
newValue, Maybe WhatIfPointScenarioProperty
()
haddock_workaround_ :: ()
whatIfPointScenario :: Maybe WhatIfPointScenarioProperty
haddock_workaround_ :: ()
whatIfPointScenario :: Maybe WhatIfPointScenarioProperty
..}