{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}

-- Derived from AWS service descriptions, licensed under Apache 2.0.

-- |
-- Module      : Amazonka.QuickSight.Types.ScatterPlotConfiguration
-- Copyright   : (c) 2013-2023 Brendan Hay
-- License     : Mozilla Public License, v. 2.0.
-- Maintainer  : Brendan Hay
-- Stability   : auto-generated
-- Portability : non-portable (GHC extensions)
module Amazonka.QuickSight.Types.ScatterPlotConfiguration where

import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import qualified Amazonka.Prelude as Prelude
import Amazonka.QuickSight.Types.AxisDisplayOptions
import Amazonka.QuickSight.Types.ChartAxisLabelOptions
import Amazonka.QuickSight.Types.DataLabelOptions
import Amazonka.QuickSight.Types.LegendOptions
import Amazonka.QuickSight.Types.ScatterPlotFieldWells
import Amazonka.QuickSight.Types.TooltipOptions
import Amazonka.QuickSight.Types.VisualPalette

-- | The configuration of a scatter plot.
--
-- /See:/ 'newScatterPlotConfiguration' smart constructor.
data ScatterPlotConfiguration = ScatterPlotConfiguration'
  { -- | The options that determine if visual data labels are displayed.
    ScatterPlotConfiguration -> Maybe DataLabelOptions
dataLabels :: Prelude.Maybe DataLabelOptions,
    -- | The field wells of the visual.
    ScatterPlotConfiguration -> Maybe ScatterPlotFieldWells
fieldWells :: Prelude.Maybe ScatterPlotFieldWells,
    -- | The legend display setup of the visual.
    ScatterPlotConfiguration -> Maybe LegendOptions
legend :: Prelude.Maybe LegendOptions,
    -- | The legend display setup of the visual.
    ScatterPlotConfiguration -> Maybe TooltipOptions
tooltip :: Prelude.Maybe TooltipOptions,
    -- | The palette (chart color) display setup of the visual.
    ScatterPlotConfiguration -> Maybe VisualPalette
visualPalette :: Prelude.Maybe VisualPalette,
    -- | The label display options (grid line, range, scale, and axis step) of
    -- the scatter plot\'s x-axis.
    ScatterPlotConfiguration -> Maybe AxisDisplayOptions
xAxisDisplayOptions :: Prelude.Maybe AxisDisplayOptions,
    -- | The label options (label text, label visibility, and sort icon
    -- visibility) of the scatter plot\'s x-axis.
    ScatterPlotConfiguration -> Maybe ChartAxisLabelOptions
xAxisLabelOptions :: Prelude.Maybe ChartAxisLabelOptions,
    -- | The label display options (grid line, range, scale, and axis step) of
    -- the scatter plot\'s y-axis.
    ScatterPlotConfiguration -> Maybe AxisDisplayOptions
yAxisDisplayOptions :: Prelude.Maybe AxisDisplayOptions,
    -- | The label options (label text, label visibility, and sort icon
    -- visibility) of the scatter plot\'s y-axis.
    ScatterPlotConfiguration -> Maybe ChartAxisLabelOptions
yAxisLabelOptions :: Prelude.Maybe ChartAxisLabelOptions
  }
  deriving (ScatterPlotConfiguration -> ScatterPlotConfiguration -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ScatterPlotConfiguration -> ScatterPlotConfiguration -> Bool
$c/= :: ScatterPlotConfiguration -> ScatterPlotConfiguration -> Bool
== :: ScatterPlotConfiguration -> ScatterPlotConfiguration -> Bool
$c== :: ScatterPlotConfiguration -> ScatterPlotConfiguration -> Bool
Prelude.Eq, Int -> ScatterPlotConfiguration -> ShowS
[ScatterPlotConfiguration] -> ShowS
ScatterPlotConfiguration -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ScatterPlotConfiguration] -> ShowS
$cshowList :: [ScatterPlotConfiguration] -> ShowS
show :: ScatterPlotConfiguration -> String
$cshow :: ScatterPlotConfiguration -> String
showsPrec :: Int -> ScatterPlotConfiguration -> ShowS
$cshowsPrec :: Int -> ScatterPlotConfiguration -> ShowS
Prelude.Show, forall x.
Rep ScatterPlotConfiguration x -> ScatterPlotConfiguration
forall x.
ScatterPlotConfiguration -> Rep ScatterPlotConfiguration x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep ScatterPlotConfiguration x -> ScatterPlotConfiguration
$cfrom :: forall x.
ScatterPlotConfiguration -> Rep ScatterPlotConfiguration x
Prelude.Generic)

-- |
-- Create a value of 'ScatterPlotConfiguration' with all optional fields omitted.
--
-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.
--
-- The following record fields are available, with the corresponding lenses provided
-- for backwards compatibility:
--
-- 'dataLabels', 'scatterPlotConfiguration_dataLabels' - The options that determine if visual data labels are displayed.
--
-- 'fieldWells', 'scatterPlotConfiguration_fieldWells' - The field wells of the visual.
--
-- 'legend', 'scatterPlotConfiguration_legend' - The legend display setup of the visual.
--
-- 'tooltip', 'scatterPlotConfiguration_tooltip' - The legend display setup of the visual.
--
-- 'visualPalette', 'scatterPlotConfiguration_visualPalette' - The palette (chart color) display setup of the visual.
--
-- 'xAxisDisplayOptions', 'scatterPlotConfiguration_xAxisDisplayOptions' - The label display options (grid line, range, scale, and axis step) of
-- the scatter plot\'s x-axis.
--
-- 'xAxisLabelOptions', 'scatterPlotConfiguration_xAxisLabelOptions' - The label options (label text, label visibility, and sort icon
-- visibility) of the scatter plot\'s x-axis.
--
-- 'yAxisDisplayOptions', 'scatterPlotConfiguration_yAxisDisplayOptions' - The label display options (grid line, range, scale, and axis step) of
-- the scatter plot\'s y-axis.
--
-- 'yAxisLabelOptions', 'scatterPlotConfiguration_yAxisLabelOptions' - The label options (label text, label visibility, and sort icon
-- visibility) of the scatter plot\'s y-axis.
newScatterPlotConfiguration ::
  ScatterPlotConfiguration
newScatterPlotConfiguration :: ScatterPlotConfiguration
newScatterPlotConfiguration =
  ScatterPlotConfiguration'
    { $sel:dataLabels:ScatterPlotConfiguration' :: Maybe DataLabelOptions
dataLabels =
        forall a. Maybe a
Prelude.Nothing,
      $sel:fieldWells:ScatterPlotConfiguration' :: Maybe ScatterPlotFieldWells
fieldWells = forall a. Maybe a
Prelude.Nothing,
      $sel:legend:ScatterPlotConfiguration' :: Maybe LegendOptions
legend = forall a. Maybe a
Prelude.Nothing,
      $sel:tooltip:ScatterPlotConfiguration' :: Maybe TooltipOptions
tooltip = forall a. Maybe a
Prelude.Nothing,
      $sel:visualPalette:ScatterPlotConfiguration' :: Maybe VisualPalette
visualPalette = forall a. Maybe a
Prelude.Nothing,
      $sel:xAxisDisplayOptions:ScatterPlotConfiguration' :: Maybe AxisDisplayOptions
xAxisDisplayOptions = forall a. Maybe a
Prelude.Nothing,
      $sel:xAxisLabelOptions:ScatterPlotConfiguration' :: Maybe ChartAxisLabelOptions
xAxisLabelOptions = forall a. Maybe a
Prelude.Nothing,
      $sel:yAxisDisplayOptions:ScatterPlotConfiguration' :: Maybe AxisDisplayOptions
yAxisDisplayOptions = forall a. Maybe a
Prelude.Nothing,
      $sel:yAxisLabelOptions:ScatterPlotConfiguration' :: Maybe ChartAxisLabelOptions
yAxisLabelOptions = forall a. Maybe a
Prelude.Nothing
    }

-- | The options that determine if visual data labels are displayed.
scatterPlotConfiguration_dataLabels :: Lens.Lens' ScatterPlotConfiguration (Prelude.Maybe DataLabelOptions)
scatterPlotConfiguration_dataLabels :: Lens' ScatterPlotConfiguration (Maybe DataLabelOptions)
scatterPlotConfiguration_dataLabels = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ScatterPlotConfiguration' {Maybe DataLabelOptions
dataLabels :: Maybe DataLabelOptions
$sel:dataLabels:ScatterPlotConfiguration' :: ScatterPlotConfiguration -> Maybe DataLabelOptions
dataLabels} -> Maybe DataLabelOptions
dataLabels) (\s :: ScatterPlotConfiguration
s@ScatterPlotConfiguration' {} Maybe DataLabelOptions
a -> ScatterPlotConfiguration
s {$sel:dataLabels:ScatterPlotConfiguration' :: Maybe DataLabelOptions
dataLabels = Maybe DataLabelOptions
a} :: ScatterPlotConfiguration)

-- | The field wells of the visual.
scatterPlotConfiguration_fieldWells :: Lens.Lens' ScatterPlotConfiguration (Prelude.Maybe ScatterPlotFieldWells)
scatterPlotConfiguration_fieldWells :: Lens' ScatterPlotConfiguration (Maybe ScatterPlotFieldWells)
scatterPlotConfiguration_fieldWells = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ScatterPlotConfiguration' {Maybe ScatterPlotFieldWells
fieldWells :: Maybe ScatterPlotFieldWells
$sel:fieldWells:ScatterPlotConfiguration' :: ScatterPlotConfiguration -> Maybe ScatterPlotFieldWells
fieldWells} -> Maybe ScatterPlotFieldWells
fieldWells) (\s :: ScatterPlotConfiguration
s@ScatterPlotConfiguration' {} Maybe ScatterPlotFieldWells
a -> ScatterPlotConfiguration
s {$sel:fieldWells:ScatterPlotConfiguration' :: Maybe ScatterPlotFieldWells
fieldWells = Maybe ScatterPlotFieldWells
a} :: ScatterPlotConfiguration)

-- | The legend display setup of the visual.
scatterPlotConfiguration_legend :: Lens.Lens' ScatterPlotConfiguration (Prelude.Maybe LegendOptions)
scatterPlotConfiguration_legend :: Lens' ScatterPlotConfiguration (Maybe LegendOptions)
scatterPlotConfiguration_legend = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ScatterPlotConfiguration' {Maybe LegendOptions
legend :: Maybe LegendOptions
$sel:legend:ScatterPlotConfiguration' :: ScatterPlotConfiguration -> Maybe LegendOptions
legend} -> Maybe LegendOptions
legend) (\s :: ScatterPlotConfiguration
s@ScatterPlotConfiguration' {} Maybe LegendOptions
a -> ScatterPlotConfiguration
s {$sel:legend:ScatterPlotConfiguration' :: Maybe LegendOptions
legend = Maybe LegendOptions
a} :: ScatterPlotConfiguration)

-- | The legend display setup of the visual.
scatterPlotConfiguration_tooltip :: Lens.Lens' ScatterPlotConfiguration (Prelude.Maybe TooltipOptions)
scatterPlotConfiguration_tooltip :: Lens' ScatterPlotConfiguration (Maybe TooltipOptions)
scatterPlotConfiguration_tooltip = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ScatterPlotConfiguration' {Maybe TooltipOptions
tooltip :: Maybe TooltipOptions
$sel:tooltip:ScatterPlotConfiguration' :: ScatterPlotConfiguration -> Maybe TooltipOptions
tooltip} -> Maybe TooltipOptions
tooltip) (\s :: ScatterPlotConfiguration
s@ScatterPlotConfiguration' {} Maybe TooltipOptions
a -> ScatterPlotConfiguration
s {$sel:tooltip:ScatterPlotConfiguration' :: Maybe TooltipOptions
tooltip = Maybe TooltipOptions
a} :: ScatterPlotConfiguration)

-- | The palette (chart color) display setup of the visual.
scatterPlotConfiguration_visualPalette :: Lens.Lens' ScatterPlotConfiguration (Prelude.Maybe VisualPalette)
scatterPlotConfiguration_visualPalette :: Lens' ScatterPlotConfiguration (Maybe VisualPalette)
scatterPlotConfiguration_visualPalette = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ScatterPlotConfiguration' {Maybe VisualPalette
visualPalette :: Maybe VisualPalette
$sel:visualPalette:ScatterPlotConfiguration' :: ScatterPlotConfiguration -> Maybe VisualPalette
visualPalette} -> Maybe VisualPalette
visualPalette) (\s :: ScatterPlotConfiguration
s@ScatterPlotConfiguration' {} Maybe VisualPalette
a -> ScatterPlotConfiguration
s {$sel:visualPalette:ScatterPlotConfiguration' :: Maybe VisualPalette
visualPalette = Maybe VisualPalette
a} :: ScatterPlotConfiguration)

-- | The label display options (grid line, range, scale, and axis step) of
-- the scatter plot\'s x-axis.
scatterPlotConfiguration_xAxisDisplayOptions :: Lens.Lens' ScatterPlotConfiguration (Prelude.Maybe AxisDisplayOptions)
scatterPlotConfiguration_xAxisDisplayOptions :: Lens' ScatterPlotConfiguration (Maybe AxisDisplayOptions)
scatterPlotConfiguration_xAxisDisplayOptions = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ScatterPlotConfiguration' {Maybe AxisDisplayOptions
xAxisDisplayOptions :: Maybe AxisDisplayOptions
$sel:xAxisDisplayOptions:ScatterPlotConfiguration' :: ScatterPlotConfiguration -> Maybe AxisDisplayOptions
xAxisDisplayOptions} -> Maybe AxisDisplayOptions
xAxisDisplayOptions) (\s :: ScatterPlotConfiguration
s@ScatterPlotConfiguration' {} Maybe AxisDisplayOptions
a -> ScatterPlotConfiguration
s {$sel:xAxisDisplayOptions:ScatterPlotConfiguration' :: Maybe AxisDisplayOptions
xAxisDisplayOptions = Maybe AxisDisplayOptions
a} :: ScatterPlotConfiguration)

-- | The label options (label text, label visibility, and sort icon
-- visibility) of the scatter plot\'s x-axis.
scatterPlotConfiguration_xAxisLabelOptions :: Lens.Lens' ScatterPlotConfiguration (Prelude.Maybe ChartAxisLabelOptions)
scatterPlotConfiguration_xAxisLabelOptions :: Lens' ScatterPlotConfiguration (Maybe ChartAxisLabelOptions)
scatterPlotConfiguration_xAxisLabelOptions = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ScatterPlotConfiguration' {Maybe ChartAxisLabelOptions
xAxisLabelOptions :: Maybe ChartAxisLabelOptions
$sel:xAxisLabelOptions:ScatterPlotConfiguration' :: ScatterPlotConfiguration -> Maybe ChartAxisLabelOptions
xAxisLabelOptions} -> Maybe ChartAxisLabelOptions
xAxisLabelOptions) (\s :: ScatterPlotConfiguration
s@ScatterPlotConfiguration' {} Maybe ChartAxisLabelOptions
a -> ScatterPlotConfiguration
s {$sel:xAxisLabelOptions:ScatterPlotConfiguration' :: Maybe ChartAxisLabelOptions
xAxisLabelOptions = Maybe ChartAxisLabelOptions
a} :: ScatterPlotConfiguration)

-- | The label display options (grid line, range, scale, and axis step) of
-- the scatter plot\'s y-axis.
scatterPlotConfiguration_yAxisDisplayOptions :: Lens.Lens' ScatterPlotConfiguration (Prelude.Maybe AxisDisplayOptions)
scatterPlotConfiguration_yAxisDisplayOptions :: Lens' ScatterPlotConfiguration (Maybe AxisDisplayOptions)
scatterPlotConfiguration_yAxisDisplayOptions = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ScatterPlotConfiguration' {Maybe AxisDisplayOptions
yAxisDisplayOptions :: Maybe AxisDisplayOptions
$sel:yAxisDisplayOptions:ScatterPlotConfiguration' :: ScatterPlotConfiguration -> Maybe AxisDisplayOptions
yAxisDisplayOptions} -> Maybe AxisDisplayOptions
yAxisDisplayOptions) (\s :: ScatterPlotConfiguration
s@ScatterPlotConfiguration' {} Maybe AxisDisplayOptions
a -> ScatterPlotConfiguration
s {$sel:yAxisDisplayOptions:ScatterPlotConfiguration' :: Maybe AxisDisplayOptions
yAxisDisplayOptions = Maybe AxisDisplayOptions
a} :: ScatterPlotConfiguration)

-- | The label options (label text, label visibility, and sort icon
-- visibility) of the scatter plot\'s y-axis.
scatterPlotConfiguration_yAxisLabelOptions :: Lens.Lens' ScatterPlotConfiguration (Prelude.Maybe ChartAxisLabelOptions)
scatterPlotConfiguration_yAxisLabelOptions :: Lens' ScatterPlotConfiguration (Maybe ChartAxisLabelOptions)
scatterPlotConfiguration_yAxisLabelOptions = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ScatterPlotConfiguration' {Maybe ChartAxisLabelOptions
yAxisLabelOptions :: Maybe ChartAxisLabelOptions
$sel:yAxisLabelOptions:ScatterPlotConfiguration' :: ScatterPlotConfiguration -> Maybe ChartAxisLabelOptions
yAxisLabelOptions} -> Maybe ChartAxisLabelOptions
yAxisLabelOptions) (\s :: ScatterPlotConfiguration
s@ScatterPlotConfiguration' {} Maybe ChartAxisLabelOptions
a -> ScatterPlotConfiguration
s {$sel:yAxisLabelOptions:ScatterPlotConfiguration' :: Maybe ChartAxisLabelOptions
yAxisLabelOptions = Maybe ChartAxisLabelOptions
a} :: ScatterPlotConfiguration)

instance Data.FromJSON ScatterPlotConfiguration where
  parseJSON :: Value -> Parser ScatterPlotConfiguration
parseJSON =
    forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.withObject
      String
"ScatterPlotConfiguration"
      ( \Object
x ->
          Maybe DataLabelOptions
-> Maybe ScatterPlotFieldWells
-> Maybe LegendOptions
-> Maybe TooltipOptions
-> Maybe VisualPalette
-> Maybe AxisDisplayOptions
-> Maybe ChartAxisLabelOptions
-> Maybe AxisDisplayOptions
-> Maybe ChartAxisLabelOptions
-> ScatterPlotConfiguration
ScatterPlotConfiguration'
            forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"DataLabels")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"FieldWells")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"Legend")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"Tooltip")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"VisualPalette")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"XAxisDisplayOptions")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"XAxisLabelOptions")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"YAxisDisplayOptions")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"YAxisLabelOptions")
      )

instance Prelude.Hashable ScatterPlotConfiguration where
  hashWithSalt :: Int -> ScatterPlotConfiguration -> Int
hashWithSalt Int
_salt ScatterPlotConfiguration' {Maybe ScatterPlotFieldWells
Maybe LegendOptions
Maybe DataLabelOptions
Maybe TooltipOptions
Maybe ChartAxisLabelOptions
Maybe AxisDisplayOptions
Maybe VisualPalette
yAxisLabelOptions :: Maybe ChartAxisLabelOptions
yAxisDisplayOptions :: Maybe AxisDisplayOptions
xAxisLabelOptions :: Maybe ChartAxisLabelOptions
xAxisDisplayOptions :: Maybe AxisDisplayOptions
visualPalette :: Maybe VisualPalette
tooltip :: Maybe TooltipOptions
legend :: Maybe LegendOptions
fieldWells :: Maybe ScatterPlotFieldWells
dataLabels :: Maybe DataLabelOptions
$sel:yAxisLabelOptions:ScatterPlotConfiguration' :: ScatterPlotConfiguration -> Maybe ChartAxisLabelOptions
$sel:yAxisDisplayOptions:ScatterPlotConfiguration' :: ScatterPlotConfiguration -> Maybe AxisDisplayOptions
$sel:xAxisLabelOptions:ScatterPlotConfiguration' :: ScatterPlotConfiguration -> Maybe ChartAxisLabelOptions
$sel:xAxisDisplayOptions:ScatterPlotConfiguration' :: ScatterPlotConfiguration -> Maybe AxisDisplayOptions
$sel:visualPalette:ScatterPlotConfiguration' :: ScatterPlotConfiguration -> Maybe VisualPalette
$sel:tooltip:ScatterPlotConfiguration' :: ScatterPlotConfiguration -> Maybe TooltipOptions
$sel:legend:ScatterPlotConfiguration' :: ScatterPlotConfiguration -> Maybe LegendOptions
$sel:fieldWells:ScatterPlotConfiguration' :: ScatterPlotConfiguration -> Maybe ScatterPlotFieldWells
$sel:dataLabels:ScatterPlotConfiguration' :: ScatterPlotConfiguration -> Maybe DataLabelOptions
..} =
    Int
_salt
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe DataLabelOptions
dataLabels
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe ScatterPlotFieldWells
fieldWells
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe LegendOptions
legend
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe TooltipOptions
tooltip
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe VisualPalette
visualPalette
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe AxisDisplayOptions
xAxisDisplayOptions
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe ChartAxisLabelOptions
xAxisLabelOptions
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe AxisDisplayOptions
yAxisDisplayOptions
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe ChartAxisLabelOptions
yAxisLabelOptions

instance Prelude.NFData ScatterPlotConfiguration where
  rnf :: ScatterPlotConfiguration -> ()
rnf ScatterPlotConfiguration' {Maybe ScatterPlotFieldWells
Maybe LegendOptions
Maybe DataLabelOptions
Maybe TooltipOptions
Maybe ChartAxisLabelOptions
Maybe AxisDisplayOptions
Maybe VisualPalette
yAxisLabelOptions :: Maybe ChartAxisLabelOptions
yAxisDisplayOptions :: Maybe AxisDisplayOptions
xAxisLabelOptions :: Maybe ChartAxisLabelOptions
xAxisDisplayOptions :: Maybe AxisDisplayOptions
visualPalette :: Maybe VisualPalette
tooltip :: Maybe TooltipOptions
legend :: Maybe LegendOptions
fieldWells :: Maybe ScatterPlotFieldWells
dataLabels :: Maybe DataLabelOptions
$sel:yAxisLabelOptions:ScatterPlotConfiguration' :: ScatterPlotConfiguration -> Maybe ChartAxisLabelOptions
$sel:yAxisDisplayOptions:ScatterPlotConfiguration' :: ScatterPlotConfiguration -> Maybe AxisDisplayOptions
$sel:xAxisLabelOptions:ScatterPlotConfiguration' :: ScatterPlotConfiguration -> Maybe ChartAxisLabelOptions
$sel:xAxisDisplayOptions:ScatterPlotConfiguration' :: ScatterPlotConfiguration -> Maybe AxisDisplayOptions
$sel:visualPalette:ScatterPlotConfiguration' :: ScatterPlotConfiguration -> Maybe VisualPalette
$sel:tooltip:ScatterPlotConfiguration' :: ScatterPlotConfiguration -> Maybe TooltipOptions
$sel:legend:ScatterPlotConfiguration' :: ScatterPlotConfiguration -> Maybe LegendOptions
$sel:fieldWells:ScatterPlotConfiguration' :: ScatterPlotConfiguration -> Maybe ScatterPlotFieldWells
$sel:dataLabels:ScatterPlotConfiguration' :: ScatterPlotConfiguration -> Maybe DataLabelOptions
..} =
    forall a. NFData a => a -> ()
Prelude.rnf Maybe DataLabelOptions
dataLabels
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe ScatterPlotFieldWells
fieldWells
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe LegendOptions
legend
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe TooltipOptions
tooltip
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe VisualPalette
visualPalette
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe AxisDisplayOptions
xAxisDisplayOptions
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe ChartAxisLabelOptions
xAxisLabelOptions
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe AxisDisplayOptions
yAxisDisplayOptions
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe ChartAxisLabelOptions
yAxisLabelOptions

instance Data.ToJSON ScatterPlotConfiguration where
  toJSON :: ScatterPlotConfiguration -> Value
toJSON ScatterPlotConfiguration' {Maybe ScatterPlotFieldWells
Maybe LegendOptions
Maybe DataLabelOptions
Maybe TooltipOptions
Maybe ChartAxisLabelOptions
Maybe AxisDisplayOptions
Maybe VisualPalette
yAxisLabelOptions :: Maybe ChartAxisLabelOptions
yAxisDisplayOptions :: Maybe AxisDisplayOptions
xAxisLabelOptions :: Maybe ChartAxisLabelOptions
xAxisDisplayOptions :: Maybe AxisDisplayOptions
visualPalette :: Maybe VisualPalette
tooltip :: Maybe TooltipOptions
legend :: Maybe LegendOptions
fieldWells :: Maybe ScatterPlotFieldWells
dataLabels :: Maybe DataLabelOptions
$sel:yAxisLabelOptions:ScatterPlotConfiguration' :: ScatterPlotConfiguration -> Maybe ChartAxisLabelOptions
$sel:yAxisDisplayOptions:ScatterPlotConfiguration' :: ScatterPlotConfiguration -> Maybe AxisDisplayOptions
$sel:xAxisLabelOptions:ScatterPlotConfiguration' :: ScatterPlotConfiguration -> Maybe ChartAxisLabelOptions
$sel:xAxisDisplayOptions:ScatterPlotConfiguration' :: ScatterPlotConfiguration -> Maybe AxisDisplayOptions
$sel:visualPalette:ScatterPlotConfiguration' :: ScatterPlotConfiguration -> Maybe VisualPalette
$sel:tooltip:ScatterPlotConfiguration' :: ScatterPlotConfiguration -> Maybe TooltipOptions
$sel:legend:ScatterPlotConfiguration' :: ScatterPlotConfiguration -> Maybe LegendOptions
$sel:fieldWells:ScatterPlotConfiguration' :: ScatterPlotConfiguration -> Maybe ScatterPlotFieldWells
$sel:dataLabels:ScatterPlotConfiguration' :: ScatterPlotConfiguration -> Maybe DataLabelOptions
..} =
    [Pair] -> Value
Data.object
      ( forall a. [Maybe a] -> [a]
Prelude.catMaybes
          [ (Key
"DataLabels" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe DataLabelOptions
dataLabels,
            (Key
"FieldWells" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe ScatterPlotFieldWells
fieldWells,
            (Key
"Legend" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe LegendOptions
legend,
            (Key
"Tooltip" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe TooltipOptions
tooltip,
            (Key
"VisualPalette" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe VisualPalette
visualPalette,
            (Key
"XAxisDisplayOptions" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
              forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe AxisDisplayOptions
xAxisDisplayOptions,
            (Key
"XAxisLabelOptions" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
              forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe ChartAxisLabelOptions
xAxisLabelOptions,
            (Key
"YAxisDisplayOptions" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
              forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe AxisDisplayOptions
yAxisDisplayOptions,
            (Key
"YAxisLabelOptions" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
              forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe ChartAxisLabelOptions
yAxisLabelOptions
          ]
      )