module Stratosphere.QuickSight.Dashboard.TreeMapSortConfigurationProperty (
        module Exports, TreeMapSortConfigurationProperty(..),
        mkTreeMapSortConfigurationProperty
    ) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import {-# SOURCE #-} Stratosphere.QuickSight.Dashboard.FieldSortOptionsProperty as Exports
import {-# SOURCE #-} Stratosphere.QuickSight.Dashboard.ItemsLimitConfigurationProperty as Exports
import Stratosphere.ResourceProperties
data TreeMapSortConfigurationProperty
  = -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-quicksight-dashboard-treemapsortconfiguration.html>
    TreeMapSortConfigurationProperty {TreeMapSortConfigurationProperty -> ()
haddock_workaround_ :: (),
                                      -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-quicksight-dashboard-treemapsortconfiguration.html#cfn-quicksight-dashboard-treemapsortconfiguration-treemapgroupitemslimitconfiguration>
                                      TreeMapSortConfigurationProperty
-> Maybe ItemsLimitConfigurationProperty
treeMapGroupItemsLimitConfiguration :: (Prelude.Maybe ItemsLimitConfigurationProperty),
                                      -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-quicksight-dashboard-treemapsortconfiguration.html#cfn-quicksight-dashboard-treemapsortconfiguration-treemapsort>
                                      TreeMapSortConfigurationProperty
-> Maybe [FieldSortOptionsProperty]
treeMapSort :: (Prelude.Maybe [FieldSortOptionsProperty])}
  deriving stock (TreeMapSortConfigurationProperty
-> TreeMapSortConfigurationProperty -> Bool
(TreeMapSortConfigurationProperty
 -> TreeMapSortConfigurationProperty -> Bool)
-> (TreeMapSortConfigurationProperty
    -> TreeMapSortConfigurationProperty -> Bool)
-> Eq TreeMapSortConfigurationProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: TreeMapSortConfigurationProperty
-> TreeMapSortConfigurationProperty -> Bool
== :: TreeMapSortConfigurationProperty
-> TreeMapSortConfigurationProperty -> Bool
$c/= :: TreeMapSortConfigurationProperty
-> TreeMapSortConfigurationProperty -> Bool
/= :: TreeMapSortConfigurationProperty
-> TreeMapSortConfigurationProperty -> Bool
Prelude.Eq, Int -> TreeMapSortConfigurationProperty -> ShowS
[TreeMapSortConfigurationProperty] -> ShowS
TreeMapSortConfigurationProperty -> String
(Int -> TreeMapSortConfigurationProperty -> ShowS)
-> (TreeMapSortConfigurationProperty -> String)
-> ([TreeMapSortConfigurationProperty] -> ShowS)
-> Show TreeMapSortConfigurationProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> TreeMapSortConfigurationProperty -> ShowS
showsPrec :: Int -> TreeMapSortConfigurationProperty -> ShowS
$cshow :: TreeMapSortConfigurationProperty -> String
show :: TreeMapSortConfigurationProperty -> String
$cshowList :: [TreeMapSortConfigurationProperty] -> ShowS
showList :: [TreeMapSortConfigurationProperty] -> ShowS
Prelude.Show)
mkTreeMapSortConfigurationProperty ::
  TreeMapSortConfigurationProperty
mkTreeMapSortConfigurationProperty :: TreeMapSortConfigurationProperty
mkTreeMapSortConfigurationProperty
  = TreeMapSortConfigurationProperty
      {haddock_workaround_ :: ()
haddock_workaround_ = (),
       treeMapGroupItemsLimitConfiguration :: Maybe ItemsLimitConfigurationProperty
treeMapGroupItemsLimitConfiguration = Maybe ItemsLimitConfigurationProperty
forall a. Maybe a
Prelude.Nothing,
       treeMapSort :: Maybe [FieldSortOptionsProperty]
treeMapSort = Maybe [FieldSortOptionsProperty]
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties TreeMapSortConfigurationProperty where
  toResourceProperties :: TreeMapSortConfigurationProperty -> ResourceProperties
toResourceProperties TreeMapSortConfigurationProperty {Maybe [FieldSortOptionsProperty]
Maybe ItemsLimitConfigurationProperty
()
haddock_workaround_ :: TreeMapSortConfigurationProperty -> ()
treeMapGroupItemsLimitConfiguration :: TreeMapSortConfigurationProperty
-> Maybe ItemsLimitConfigurationProperty
treeMapSort :: TreeMapSortConfigurationProperty
-> Maybe [FieldSortOptionsProperty]
haddock_workaround_ :: ()
treeMapGroupItemsLimitConfiguration :: Maybe ItemsLimitConfigurationProperty
treeMapSort :: Maybe [FieldSortOptionsProperty]
..}
    = ResourceProperties
        {awsType :: Text
awsType = Text
"AWS::QuickSight::Dashboard.TreeMapSortConfiguration",
         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 -> ItemsLimitConfigurationProperty -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"TreeMapGroupItemsLimitConfiguration"
                              (ItemsLimitConfigurationProperty -> (Key, Value))
-> Maybe ItemsLimitConfigurationProperty -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe ItemsLimitConfigurationProperty
treeMapGroupItemsLimitConfiguration,
                            Key -> [FieldSortOptionsProperty] -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"TreeMapSort" ([FieldSortOptionsProperty] -> (Key, Value))
-> Maybe [FieldSortOptionsProperty] -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [FieldSortOptionsProperty]
treeMapSort])}
instance JSON.ToJSON TreeMapSortConfigurationProperty where
  toJSON :: TreeMapSortConfigurationProperty -> Value
toJSON TreeMapSortConfigurationProperty {Maybe [FieldSortOptionsProperty]
Maybe ItemsLimitConfigurationProperty
()
haddock_workaround_ :: TreeMapSortConfigurationProperty -> ()
treeMapGroupItemsLimitConfiguration :: TreeMapSortConfigurationProperty
-> Maybe ItemsLimitConfigurationProperty
treeMapSort :: TreeMapSortConfigurationProperty
-> Maybe [FieldSortOptionsProperty]
haddock_workaround_ :: ()
treeMapGroupItemsLimitConfiguration :: Maybe ItemsLimitConfigurationProperty
treeMapSort :: Maybe [FieldSortOptionsProperty]
..}
    = [(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 -> ItemsLimitConfigurationProperty -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"TreeMapGroupItemsLimitConfiguration"
                 (ItemsLimitConfigurationProperty -> (Key, Value))
-> Maybe ItemsLimitConfigurationProperty -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe ItemsLimitConfigurationProperty
treeMapGroupItemsLimitConfiguration,
               Key -> [FieldSortOptionsProperty] -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"TreeMapSort" ([FieldSortOptionsProperty] -> (Key, Value))
-> Maybe [FieldSortOptionsProperty] -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [FieldSortOptionsProperty]
treeMapSort]))
instance Property "TreeMapGroupItemsLimitConfiguration" TreeMapSortConfigurationProperty where
  type PropertyType "TreeMapGroupItemsLimitConfiguration" TreeMapSortConfigurationProperty = ItemsLimitConfigurationProperty
  set :: PropertyType
  "TreeMapGroupItemsLimitConfiguration"
  TreeMapSortConfigurationProperty
-> TreeMapSortConfigurationProperty
-> TreeMapSortConfigurationProperty
set PropertyType
  "TreeMapGroupItemsLimitConfiguration"
  TreeMapSortConfigurationProperty
newValue TreeMapSortConfigurationProperty {Maybe [FieldSortOptionsProperty]
Maybe ItemsLimitConfigurationProperty
()
haddock_workaround_ :: TreeMapSortConfigurationProperty -> ()
treeMapGroupItemsLimitConfiguration :: TreeMapSortConfigurationProperty
-> Maybe ItemsLimitConfigurationProperty
treeMapSort :: TreeMapSortConfigurationProperty
-> Maybe [FieldSortOptionsProperty]
haddock_workaround_ :: ()
treeMapGroupItemsLimitConfiguration :: Maybe ItemsLimitConfigurationProperty
treeMapSort :: Maybe [FieldSortOptionsProperty]
..}
    = TreeMapSortConfigurationProperty
        {treeMapGroupItemsLimitConfiguration :: Maybe ItemsLimitConfigurationProperty
treeMapGroupItemsLimitConfiguration = ItemsLimitConfigurationProperty
-> Maybe ItemsLimitConfigurationProperty
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType
  "TreeMapGroupItemsLimitConfiguration"
  TreeMapSortConfigurationProperty
ItemsLimitConfigurationProperty
newValue, Maybe [FieldSortOptionsProperty]
()
haddock_workaround_ :: ()
treeMapSort :: Maybe [FieldSortOptionsProperty]
haddock_workaround_ :: ()
treeMapSort :: Maybe [FieldSortOptionsProperty]
..}
instance Property "TreeMapSort" TreeMapSortConfigurationProperty where
  type PropertyType "TreeMapSort" TreeMapSortConfigurationProperty = [FieldSortOptionsProperty]
  set :: PropertyType "TreeMapSort" TreeMapSortConfigurationProperty
-> TreeMapSortConfigurationProperty
-> TreeMapSortConfigurationProperty
set PropertyType "TreeMapSort" TreeMapSortConfigurationProperty
newValue TreeMapSortConfigurationProperty {Maybe [FieldSortOptionsProperty]
Maybe ItemsLimitConfigurationProperty
()
haddock_workaround_ :: TreeMapSortConfigurationProperty -> ()
treeMapGroupItemsLimitConfiguration :: TreeMapSortConfigurationProperty
-> Maybe ItemsLimitConfigurationProperty
treeMapSort :: TreeMapSortConfigurationProperty
-> Maybe [FieldSortOptionsProperty]
haddock_workaround_ :: ()
treeMapGroupItemsLimitConfiguration :: Maybe ItemsLimitConfigurationProperty
treeMapSort :: Maybe [FieldSortOptionsProperty]
..}
    = TreeMapSortConfigurationProperty
        {treeMapSort :: Maybe [FieldSortOptionsProperty]
treeMapSort = [FieldSortOptionsProperty] -> Maybe [FieldSortOptionsProperty]
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure [FieldSortOptionsProperty]
PropertyType "TreeMapSort" TreeMapSortConfigurationProperty
newValue, Maybe ItemsLimitConfigurationProperty
()
haddock_workaround_ :: ()
treeMapGroupItemsLimitConfiguration :: Maybe ItemsLimitConfigurationProperty
haddock_workaround_ :: ()
treeMapGroupItemsLimitConfiguration :: Maybe ItemsLimitConfigurationProperty
..}