module Stratosphere.QuickSight.Analysis.HistogramBinOptionsProperty (
        module Exports, HistogramBinOptionsProperty(..),
        mkHistogramBinOptionsProperty
    ) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import {-# SOURCE #-} Stratosphere.QuickSight.Analysis.BinCountOptionsProperty as Exports
import {-# SOURCE #-} Stratosphere.QuickSight.Analysis.BinWidthOptionsProperty as Exports
import Stratosphere.ResourceProperties
import Stratosphere.Value
data HistogramBinOptionsProperty
  = -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-quicksight-analysis-histogrambinoptions.html>
    HistogramBinOptionsProperty {HistogramBinOptionsProperty -> ()
haddock_workaround_ :: (),
                                 -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-quicksight-analysis-histogrambinoptions.html#cfn-quicksight-analysis-histogrambinoptions-bincount>
                                 HistogramBinOptionsProperty -> Maybe BinCountOptionsProperty
binCount :: (Prelude.Maybe BinCountOptionsProperty),
                                 -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-quicksight-analysis-histogrambinoptions.html#cfn-quicksight-analysis-histogrambinoptions-binwidth>
                                 HistogramBinOptionsProperty -> Maybe BinWidthOptionsProperty
binWidth :: (Prelude.Maybe BinWidthOptionsProperty),
                                 -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-quicksight-analysis-histogrambinoptions.html#cfn-quicksight-analysis-histogrambinoptions-selectedbintype>
                                 HistogramBinOptionsProperty -> Maybe (Value Text)
selectedBinType :: (Prelude.Maybe (Value Prelude.Text)),
                                 -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-quicksight-analysis-histogrambinoptions.html#cfn-quicksight-analysis-histogrambinoptions-startvalue>
                                 HistogramBinOptionsProperty -> Maybe (Value Double)
startValue :: (Prelude.Maybe (Value Prelude.Double))}
  deriving stock (HistogramBinOptionsProperty -> HistogramBinOptionsProperty -> Bool
(HistogramBinOptionsProperty
 -> HistogramBinOptionsProperty -> Bool)
-> (HistogramBinOptionsProperty
    -> HistogramBinOptionsProperty -> Bool)
-> Eq HistogramBinOptionsProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: HistogramBinOptionsProperty -> HistogramBinOptionsProperty -> Bool
== :: HistogramBinOptionsProperty -> HistogramBinOptionsProperty -> Bool
$c/= :: HistogramBinOptionsProperty -> HistogramBinOptionsProperty -> Bool
/= :: HistogramBinOptionsProperty -> HistogramBinOptionsProperty -> Bool
Prelude.Eq, Int -> HistogramBinOptionsProperty -> ShowS
[HistogramBinOptionsProperty] -> ShowS
HistogramBinOptionsProperty -> String
(Int -> HistogramBinOptionsProperty -> ShowS)
-> (HistogramBinOptionsProperty -> String)
-> ([HistogramBinOptionsProperty] -> ShowS)
-> Show HistogramBinOptionsProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> HistogramBinOptionsProperty -> ShowS
showsPrec :: Int -> HistogramBinOptionsProperty -> ShowS
$cshow :: HistogramBinOptionsProperty -> String
show :: HistogramBinOptionsProperty -> String
$cshowList :: [HistogramBinOptionsProperty] -> ShowS
showList :: [HistogramBinOptionsProperty] -> ShowS
Prelude.Show)
mkHistogramBinOptionsProperty :: HistogramBinOptionsProperty
mkHistogramBinOptionsProperty :: HistogramBinOptionsProperty
mkHistogramBinOptionsProperty
  = HistogramBinOptionsProperty
      {haddock_workaround_ :: ()
haddock_workaround_ = (), binCount :: Maybe BinCountOptionsProperty
binCount = Maybe BinCountOptionsProperty
forall a. Maybe a
Prelude.Nothing,
       binWidth :: Maybe BinWidthOptionsProperty
binWidth = Maybe BinWidthOptionsProperty
forall a. Maybe a
Prelude.Nothing, selectedBinType :: Maybe (Value Text)
selectedBinType = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing,
       startValue :: Maybe (Value Double)
startValue = Maybe (Value Double)
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties HistogramBinOptionsProperty where
  toResourceProperties :: HistogramBinOptionsProperty -> ResourceProperties
toResourceProperties HistogramBinOptionsProperty {Maybe (Value Double)
Maybe (Value Text)
Maybe BinCountOptionsProperty
Maybe BinWidthOptionsProperty
()
haddock_workaround_ :: HistogramBinOptionsProperty -> ()
binCount :: HistogramBinOptionsProperty -> Maybe BinCountOptionsProperty
binWidth :: HistogramBinOptionsProperty -> Maybe BinWidthOptionsProperty
selectedBinType :: HistogramBinOptionsProperty -> Maybe (Value Text)
startValue :: HistogramBinOptionsProperty -> Maybe (Value Double)
haddock_workaround_ :: ()
binCount :: Maybe BinCountOptionsProperty
binWidth :: Maybe BinWidthOptionsProperty
selectedBinType :: Maybe (Value Text)
startValue :: Maybe (Value Double)
..}
    = ResourceProperties
        {awsType :: Text
awsType = Text
"AWS::QuickSight::Analysis.HistogramBinOptions",
         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 -> BinCountOptionsProperty -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"BinCount" (BinCountOptionsProperty -> (Key, Value))
-> Maybe BinCountOptionsProperty -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe BinCountOptionsProperty
binCount,
                            Key -> BinWidthOptionsProperty -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"BinWidth" (BinWidthOptionsProperty -> (Key, Value))
-> Maybe BinWidthOptionsProperty -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe BinWidthOptionsProperty
binWidth,
                            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
"SelectedBinType" (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)
selectedBinType,
                            Key -> Value Double -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"StartValue" (Value Double -> (Key, Value))
-> Maybe (Value Double) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Double)
startValue])}
instance JSON.ToJSON HistogramBinOptionsProperty where
  toJSON :: HistogramBinOptionsProperty -> Value
toJSON HistogramBinOptionsProperty {Maybe (Value Double)
Maybe (Value Text)
Maybe BinCountOptionsProperty
Maybe BinWidthOptionsProperty
()
haddock_workaround_ :: HistogramBinOptionsProperty -> ()
binCount :: HistogramBinOptionsProperty -> Maybe BinCountOptionsProperty
binWidth :: HistogramBinOptionsProperty -> Maybe BinWidthOptionsProperty
selectedBinType :: HistogramBinOptionsProperty -> Maybe (Value Text)
startValue :: HistogramBinOptionsProperty -> Maybe (Value Double)
haddock_workaround_ :: ()
binCount :: Maybe BinCountOptionsProperty
binWidth :: Maybe BinWidthOptionsProperty
selectedBinType :: Maybe (Value Text)
startValue :: Maybe (Value Double)
..}
    = [(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 -> BinCountOptionsProperty -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"BinCount" (BinCountOptionsProperty -> (Key, Value))
-> Maybe BinCountOptionsProperty -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe BinCountOptionsProperty
binCount,
               Key -> BinWidthOptionsProperty -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"BinWidth" (BinWidthOptionsProperty -> (Key, Value))
-> Maybe BinWidthOptionsProperty -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe BinWidthOptionsProperty
binWidth,
               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
"SelectedBinType" (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)
selectedBinType,
               Key -> Value Double -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"StartValue" (Value Double -> (Key, Value))
-> Maybe (Value Double) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Double)
startValue]))
instance Property "BinCount" HistogramBinOptionsProperty where
  type PropertyType "BinCount" HistogramBinOptionsProperty = BinCountOptionsProperty
  set :: PropertyType "BinCount" HistogramBinOptionsProperty
-> HistogramBinOptionsProperty -> HistogramBinOptionsProperty
set PropertyType "BinCount" HistogramBinOptionsProperty
newValue HistogramBinOptionsProperty {Maybe (Value Double)
Maybe (Value Text)
Maybe BinCountOptionsProperty
Maybe BinWidthOptionsProperty
()
haddock_workaround_ :: HistogramBinOptionsProperty -> ()
binCount :: HistogramBinOptionsProperty -> Maybe BinCountOptionsProperty
binWidth :: HistogramBinOptionsProperty -> Maybe BinWidthOptionsProperty
selectedBinType :: HistogramBinOptionsProperty -> Maybe (Value Text)
startValue :: HistogramBinOptionsProperty -> Maybe (Value Double)
haddock_workaround_ :: ()
binCount :: Maybe BinCountOptionsProperty
binWidth :: Maybe BinWidthOptionsProperty
selectedBinType :: Maybe (Value Text)
startValue :: Maybe (Value Double)
..}
    = HistogramBinOptionsProperty
        {binCount :: Maybe BinCountOptionsProperty
binCount = BinCountOptionsProperty -> Maybe BinCountOptionsProperty
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "BinCount" HistogramBinOptionsProperty
BinCountOptionsProperty
newValue, Maybe (Value Double)
Maybe (Value Text)
Maybe BinWidthOptionsProperty
()
haddock_workaround_ :: ()
binWidth :: Maybe BinWidthOptionsProperty
selectedBinType :: Maybe (Value Text)
startValue :: Maybe (Value Double)
haddock_workaround_ :: ()
binWidth :: Maybe BinWidthOptionsProperty
selectedBinType :: Maybe (Value Text)
startValue :: Maybe (Value Double)
..}
instance Property "BinWidth" HistogramBinOptionsProperty where
  type PropertyType "BinWidth" HistogramBinOptionsProperty = BinWidthOptionsProperty
  set :: PropertyType "BinWidth" HistogramBinOptionsProperty
-> HistogramBinOptionsProperty -> HistogramBinOptionsProperty
set PropertyType "BinWidth" HistogramBinOptionsProperty
newValue HistogramBinOptionsProperty {Maybe (Value Double)
Maybe (Value Text)
Maybe BinCountOptionsProperty
Maybe BinWidthOptionsProperty
()
haddock_workaround_ :: HistogramBinOptionsProperty -> ()
binCount :: HistogramBinOptionsProperty -> Maybe BinCountOptionsProperty
binWidth :: HistogramBinOptionsProperty -> Maybe BinWidthOptionsProperty
selectedBinType :: HistogramBinOptionsProperty -> Maybe (Value Text)
startValue :: HistogramBinOptionsProperty -> Maybe (Value Double)
haddock_workaround_ :: ()
binCount :: Maybe BinCountOptionsProperty
binWidth :: Maybe BinWidthOptionsProperty
selectedBinType :: Maybe (Value Text)
startValue :: Maybe (Value Double)
..}
    = HistogramBinOptionsProperty
        {binWidth :: Maybe BinWidthOptionsProperty
binWidth = BinWidthOptionsProperty -> Maybe BinWidthOptionsProperty
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "BinWidth" HistogramBinOptionsProperty
BinWidthOptionsProperty
newValue, Maybe (Value Double)
Maybe (Value Text)
Maybe BinCountOptionsProperty
()
haddock_workaround_ :: ()
binCount :: Maybe BinCountOptionsProperty
selectedBinType :: Maybe (Value Text)
startValue :: Maybe (Value Double)
haddock_workaround_ :: ()
binCount :: Maybe BinCountOptionsProperty
selectedBinType :: Maybe (Value Text)
startValue :: Maybe (Value Double)
..}
instance Property "SelectedBinType" HistogramBinOptionsProperty where
  type PropertyType "SelectedBinType" HistogramBinOptionsProperty = Value Prelude.Text
  set :: PropertyType "SelectedBinType" HistogramBinOptionsProperty
-> HistogramBinOptionsProperty -> HistogramBinOptionsProperty
set PropertyType "SelectedBinType" HistogramBinOptionsProperty
newValue HistogramBinOptionsProperty {Maybe (Value Double)
Maybe (Value Text)
Maybe BinCountOptionsProperty
Maybe BinWidthOptionsProperty
()
haddock_workaround_ :: HistogramBinOptionsProperty -> ()
binCount :: HistogramBinOptionsProperty -> Maybe BinCountOptionsProperty
binWidth :: HistogramBinOptionsProperty -> Maybe BinWidthOptionsProperty
selectedBinType :: HistogramBinOptionsProperty -> Maybe (Value Text)
startValue :: HistogramBinOptionsProperty -> Maybe (Value Double)
haddock_workaround_ :: ()
binCount :: Maybe BinCountOptionsProperty
binWidth :: Maybe BinWidthOptionsProperty
selectedBinType :: Maybe (Value Text)
startValue :: Maybe (Value Double)
..}
    = HistogramBinOptionsProperty
        {selectedBinType :: Maybe (Value Text)
selectedBinType = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "SelectedBinType" HistogramBinOptionsProperty
Value Text
newValue, Maybe (Value Double)
Maybe BinCountOptionsProperty
Maybe BinWidthOptionsProperty
()
haddock_workaround_ :: ()
binCount :: Maybe BinCountOptionsProperty
binWidth :: Maybe BinWidthOptionsProperty
startValue :: Maybe (Value Double)
haddock_workaround_ :: ()
binCount :: Maybe BinCountOptionsProperty
binWidth :: Maybe BinWidthOptionsProperty
startValue :: Maybe (Value Double)
..}
instance Property "StartValue" HistogramBinOptionsProperty where
  type PropertyType "StartValue" HistogramBinOptionsProperty = Value Prelude.Double
  set :: PropertyType "StartValue" HistogramBinOptionsProperty
-> HistogramBinOptionsProperty -> HistogramBinOptionsProperty
set PropertyType "StartValue" HistogramBinOptionsProperty
newValue HistogramBinOptionsProperty {Maybe (Value Double)
Maybe (Value Text)
Maybe BinCountOptionsProperty
Maybe BinWidthOptionsProperty
()
haddock_workaround_ :: HistogramBinOptionsProperty -> ()
binCount :: HistogramBinOptionsProperty -> Maybe BinCountOptionsProperty
binWidth :: HistogramBinOptionsProperty -> Maybe BinWidthOptionsProperty
selectedBinType :: HistogramBinOptionsProperty -> Maybe (Value Text)
startValue :: HistogramBinOptionsProperty -> Maybe (Value Double)
haddock_workaround_ :: ()
binCount :: Maybe BinCountOptionsProperty
binWidth :: Maybe BinWidthOptionsProperty
selectedBinType :: Maybe (Value Text)
startValue :: Maybe (Value Double)
..}
    = HistogramBinOptionsProperty
        {startValue :: Maybe (Value Double)
startValue = Value Double -> Maybe (Value Double)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "StartValue" HistogramBinOptionsProperty
Value Double
newValue, Maybe (Value Text)
Maybe BinCountOptionsProperty
Maybe BinWidthOptionsProperty
()
haddock_workaround_ :: ()
binCount :: Maybe BinCountOptionsProperty
binWidth :: Maybe BinWidthOptionsProperty
selectedBinType :: Maybe (Value Text)
haddock_workaround_ :: ()
binCount :: Maybe BinCountOptionsProperty
binWidth :: Maybe BinWidthOptionsProperty
selectedBinType :: Maybe (Value Text)
..}