{-# 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.BoxPlotChartConfiguration
-- 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.BoxPlotChartConfiguration 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.BoxPlotFieldWells
import Amazonka.QuickSight.Types.BoxPlotOptions
import Amazonka.QuickSight.Types.BoxPlotSortConfiguration
import Amazonka.QuickSight.Types.ChartAxisLabelOptions
import Amazonka.QuickSight.Types.LegendOptions
import Amazonka.QuickSight.Types.ReferenceLine
import Amazonka.QuickSight.Types.TooltipOptions
import Amazonka.QuickSight.Types.VisualPalette

-- | The configuration of a @BoxPlotVisual@.
--
-- /See:/ 'newBoxPlotChartConfiguration' smart constructor.
data BoxPlotChartConfiguration = BoxPlotChartConfiguration'
  { -- | The box plot chart options for a box plot visual
    BoxPlotChartConfiguration -> Maybe BoxPlotOptions
boxPlotOptions :: Prelude.Maybe BoxPlotOptions,
    -- | The label display options (grid line, range, scale, axis step) of a box
    -- plot category.
    BoxPlotChartConfiguration -> Maybe AxisDisplayOptions
categoryAxis :: Prelude.Maybe AxisDisplayOptions,
    -- | The label options (label text, label visibility and sort Icon
    -- visibility) of a box plot category.
    BoxPlotChartConfiguration -> Maybe ChartAxisLabelOptions
categoryLabelOptions :: Prelude.Maybe ChartAxisLabelOptions,
    -- | The field wells of the visual.
    BoxPlotChartConfiguration -> Maybe BoxPlotFieldWells
fieldWells :: Prelude.Maybe BoxPlotFieldWells,
    BoxPlotChartConfiguration -> Maybe LegendOptions
legend :: Prelude.Maybe LegendOptions,
    -- | The label display options (grid line, range, scale, axis step) of a box
    -- plot category.
    BoxPlotChartConfiguration -> Maybe AxisDisplayOptions
primaryYAxisDisplayOptions :: Prelude.Maybe AxisDisplayOptions,
    -- | The label options (label text, label visibility and sort icon
    -- visibility) of a box plot value.
    BoxPlotChartConfiguration -> Maybe ChartAxisLabelOptions
primaryYAxisLabelOptions :: Prelude.Maybe ChartAxisLabelOptions,
    -- | The reference line setup of the visual.
    BoxPlotChartConfiguration -> Maybe [ReferenceLine]
referenceLines :: Prelude.Maybe [ReferenceLine],
    -- | The sort configuration of a @BoxPlotVisual@.
    BoxPlotChartConfiguration -> Maybe BoxPlotSortConfiguration
sortConfiguration :: Prelude.Maybe BoxPlotSortConfiguration,
    -- | The tooltip display setup of the visual.
    BoxPlotChartConfiguration -> Maybe TooltipOptions
tooltip :: Prelude.Maybe TooltipOptions,
    -- | The palette (chart color) display setup of the visual.
    BoxPlotChartConfiguration -> Maybe VisualPalette
visualPalette :: Prelude.Maybe VisualPalette
  }
  deriving (BoxPlotChartConfiguration -> BoxPlotChartConfiguration -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: BoxPlotChartConfiguration -> BoxPlotChartConfiguration -> Bool
$c/= :: BoxPlotChartConfiguration -> BoxPlotChartConfiguration -> Bool
== :: BoxPlotChartConfiguration -> BoxPlotChartConfiguration -> Bool
$c== :: BoxPlotChartConfiguration -> BoxPlotChartConfiguration -> Bool
Prelude.Eq, Int -> BoxPlotChartConfiguration -> ShowS
[BoxPlotChartConfiguration] -> ShowS
BoxPlotChartConfiguration -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [BoxPlotChartConfiguration] -> ShowS
$cshowList :: [BoxPlotChartConfiguration] -> ShowS
show :: BoxPlotChartConfiguration -> String
$cshow :: BoxPlotChartConfiguration -> String
showsPrec :: Int -> BoxPlotChartConfiguration -> ShowS
$cshowsPrec :: Int -> BoxPlotChartConfiguration -> ShowS
Prelude.Show, forall x.
Rep BoxPlotChartConfiguration x -> BoxPlotChartConfiguration
forall x.
BoxPlotChartConfiguration -> Rep BoxPlotChartConfiguration x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep BoxPlotChartConfiguration x -> BoxPlotChartConfiguration
$cfrom :: forall x.
BoxPlotChartConfiguration -> Rep BoxPlotChartConfiguration x
Prelude.Generic)

-- |
-- Create a value of 'BoxPlotChartConfiguration' 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:
--
-- 'boxPlotOptions', 'boxPlotChartConfiguration_boxPlotOptions' - The box plot chart options for a box plot visual
--
-- 'categoryAxis', 'boxPlotChartConfiguration_categoryAxis' - The label display options (grid line, range, scale, axis step) of a box
-- plot category.
--
-- 'categoryLabelOptions', 'boxPlotChartConfiguration_categoryLabelOptions' - The label options (label text, label visibility and sort Icon
-- visibility) of a box plot category.
--
-- 'fieldWells', 'boxPlotChartConfiguration_fieldWells' - The field wells of the visual.
--
-- 'legend', 'boxPlotChartConfiguration_legend' - Undocumented member.
--
-- 'primaryYAxisDisplayOptions', 'boxPlotChartConfiguration_primaryYAxisDisplayOptions' - The label display options (grid line, range, scale, axis step) of a box
-- plot category.
--
-- 'primaryYAxisLabelOptions', 'boxPlotChartConfiguration_primaryYAxisLabelOptions' - The label options (label text, label visibility and sort icon
-- visibility) of a box plot value.
--
-- 'referenceLines', 'boxPlotChartConfiguration_referenceLines' - The reference line setup of the visual.
--
-- 'sortConfiguration', 'boxPlotChartConfiguration_sortConfiguration' - The sort configuration of a @BoxPlotVisual@.
--
-- 'tooltip', 'boxPlotChartConfiguration_tooltip' - The tooltip display setup of the visual.
--
-- 'visualPalette', 'boxPlotChartConfiguration_visualPalette' - The palette (chart color) display setup of the visual.
newBoxPlotChartConfiguration ::
  BoxPlotChartConfiguration
newBoxPlotChartConfiguration :: BoxPlotChartConfiguration
newBoxPlotChartConfiguration =
  BoxPlotChartConfiguration'
    { $sel:boxPlotOptions:BoxPlotChartConfiguration' :: Maybe BoxPlotOptions
boxPlotOptions =
        forall a. Maybe a
Prelude.Nothing,
      $sel:categoryAxis:BoxPlotChartConfiguration' :: Maybe AxisDisplayOptions
categoryAxis = forall a. Maybe a
Prelude.Nothing,
      $sel:categoryLabelOptions:BoxPlotChartConfiguration' :: Maybe ChartAxisLabelOptions
categoryLabelOptions = forall a. Maybe a
Prelude.Nothing,
      $sel:fieldWells:BoxPlotChartConfiguration' :: Maybe BoxPlotFieldWells
fieldWells = forall a. Maybe a
Prelude.Nothing,
      $sel:legend:BoxPlotChartConfiguration' :: Maybe LegendOptions
legend = forall a. Maybe a
Prelude.Nothing,
      $sel:primaryYAxisDisplayOptions:BoxPlotChartConfiguration' :: Maybe AxisDisplayOptions
primaryYAxisDisplayOptions = forall a. Maybe a
Prelude.Nothing,
      $sel:primaryYAxisLabelOptions:BoxPlotChartConfiguration' :: Maybe ChartAxisLabelOptions
primaryYAxisLabelOptions = forall a. Maybe a
Prelude.Nothing,
      $sel:referenceLines:BoxPlotChartConfiguration' :: Maybe [ReferenceLine]
referenceLines = forall a. Maybe a
Prelude.Nothing,
      $sel:sortConfiguration:BoxPlotChartConfiguration' :: Maybe BoxPlotSortConfiguration
sortConfiguration = forall a. Maybe a
Prelude.Nothing,
      $sel:tooltip:BoxPlotChartConfiguration' :: Maybe TooltipOptions
tooltip = forall a. Maybe a
Prelude.Nothing,
      $sel:visualPalette:BoxPlotChartConfiguration' :: Maybe VisualPalette
visualPalette = forall a. Maybe a
Prelude.Nothing
    }

-- | The box plot chart options for a box plot visual
boxPlotChartConfiguration_boxPlotOptions :: Lens.Lens' BoxPlotChartConfiguration (Prelude.Maybe BoxPlotOptions)
boxPlotChartConfiguration_boxPlotOptions :: Lens' BoxPlotChartConfiguration (Maybe BoxPlotOptions)
boxPlotChartConfiguration_boxPlotOptions = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\BoxPlotChartConfiguration' {Maybe BoxPlotOptions
boxPlotOptions :: Maybe BoxPlotOptions
$sel:boxPlotOptions:BoxPlotChartConfiguration' :: BoxPlotChartConfiguration -> Maybe BoxPlotOptions
boxPlotOptions} -> Maybe BoxPlotOptions
boxPlotOptions) (\s :: BoxPlotChartConfiguration
s@BoxPlotChartConfiguration' {} Maybe BoxPlotOptions
a -> BoxPlotChartConfiguration
s {$sel:boxPlotOptions:BoxPlotChartConfiguration' :: Maybe BoxPlotOptions
boxPlotOptions = Maybe BoxPlotOptions
a} :: BoxPlotChartConfiguration)

-- | The label display options (grid line, range, scale, axis step) of a box
-- plot category.
boxPlotChartConfiguration_categoryAxis :: Lens.Lens' BoxPlotChartConfiguration (Prelude.Maybe AxisDisplayOptions)
boxPlotChartConfiguration_categoryAxis :: Lens' BoxPlotChartConfiguration (Maybe AxisDisplayOptions)
boxPlotChartConfiguration_categoryAxis = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\BoxPlotChartConfiguration' {Maybe AxisDisplayOptions
categoryAxis :: Maybe AxisDisplayOptions
$sel:categoryAxis:BoxPlotChartConfiguration' :: BoxPlotChartConfiguration -> Maybe AxisDisplayOptions
categoryAxis} -> Maybe AxisDisplayOptions
categoryAxis) (\s :: BoxPlotChartConfiguration
s@BoxPlotChartConfiguration' {} Maybe AxisDisplayOptions
a -> BoxPlotChartConfiguration
s {$sel:categoryAxis:BoxPlotChartConfiguration' :: Maybe AxisDisplayOptions
categoryAxis = Maybe AxisDisplayOptions
a} :: BoxPlotChartConfiguration)

-- | The label options (label text, label visibility and sort Icon
-- visibility) of a box plot category.
boxPlotChartConfiguration_categoryLabelOptions :: Lens.Lens' BoxPlotChartConfiguration (Prelude.Maybe ChartAxisLabelOptions)
boxPlotChartConfiguration_categoryLabelOptions :: Lens' BoxPlotChartConfiguration (Maybe ChartAxisLabelOptions)
boxPlotChartConfiguration_categoryLabelOptions = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\BoxPlotChartConfiguration' {Maybe ChartAxisLabelOptions
categoryLabelOptions :: Maybe ChartAxisLabelOptions
$sel:categoryLabelOptions:BoxPlotChartConfiguration' :: BoxPlotChartConfiguration -> Maybe ChartAxisLabelOptions
categoryLabelOptions} -> Maybe ChartAxisLabelOptions
categoryLabelOptions) (\s :: BoxPlotChartConfiguration
s@BoxPlotChartConfiguration' {} Maybe ChartAxisLabelOptions
a -> BoxPlotChartConfiguration
s {$sel:categoryLabelOptions:BoxPlotChartConfiguration' :: Maybe ChartAxisLabelOptions
categoryLabelOptions = Maybe ChartAxisLabelOptions
a} :: BoxPlotChartConfiguration)

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

-- | Undocumented member.
boxPlotChartConfiguration_legend :: Lens.Lens' BoxPlotChartConfiguration (Prelude.Maybe LegendOptions)
boxPlotChartConfiguration_legend :: Lens' BoxPlotChartConfiguration (Maybe LegendOptions)
boxPlotChartConfiguration_legend = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\BoxPlotChartConfiguration' {Maybe LegendOptions
legend :: Maybe LegendOptions
$sel:legend:BoxPlotChartConfiguration' :: BoxPlotChartConfiguration -> Maybe LegendOptions
legend} -> Maybe LegendOptions
legend) (\s :: BoxPlotChartConfiguration
s@BoxPlotChartConfiguration' {} Maybe LegendOptions
a -> BoxPlotChartConfiguration
s {$sel:legend:BoxPlotChartConfiguration' :: Maybe LegendOptions
legend = Maybe LegendOptions
a} :: BoxPlotChartConfiguration)

-- | The label display options (grid line, range, scale, axis step) of a box
-- plot category.
boxPlotChartConfiguration_primaryYAxisDisplayOptions :: Lens.Lens' BoxPlotChartConfiguration (Prelude.Maybe AxisDisplayOptions)
boxPlotChartConfiguration_primaryYAxisDisplayOptions :: Lens' BoxPlotChartConfiguration (Maybe AxisDisplayOptions)
boxPlotChartConfiguration_primaryYAxisDisplayOptions = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\BoxPlotChartConfiguration' {Maybe AxisDisplayOptions
primaryYAxisDisplayOptions :: Maybe AxisDisplayOptions
$sel:primaryYAxisDisplayOptions:BoxPlotChartConfiguration' :: BoxPlotChartConfiguration -> Maybe AxisDisplayOptions
primaryYAxisDisplayOptions} -> Maybe AxisDisplayOptions
primaryYAxisDisplayOptions) (\s :: BoxPlotChartConfiguration
s@BoxPlotChartConfiguration' {} Maybe AxisDisplayOptions
a -> BoxPlotChartConfiguration
s {$sel:primaryYAxisDisplayOptions:BoxPlotChartConfiguration' :: Maybe AxisDisplayOptions
primaryYAxisDisplayOptions = Maybe AxisDisplayOptions
a} :: BoxPlotChartConfiguration)

-- | The label options (label text, label visibility and sort icon
-- visibility) of a box plot value.
boxPlotChartConfiguration_primaryYAxisLabelOptions :: Lens.Lens' BoxPlotChartConfiguration (Prelude.Maybe ChartAxisLabelOptions)
boxPlotChartConfiguration_primaryYAxisLabelOptions :: Lens' BoxPlotChartConfiguration (Maybe ChartAxisLabelOptions)
boxPlotChartConfiguration_primaryYAxisLabelOptions = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\BoxPlotChartConfiguration' {Maybe ChartAxisLabelOptions
primaryYAxisLabelOptions :: Maybe ChartAxisLabelOptions
$sel:primaryYAxisLabelOptions:BoxPlotChartConfiguration' :: BoxPlotChartConfiguration -> Maybe ChartAxisLabelOptions
primaryYAxisLabelOptions} -> Maybe ChartAxisLabelOptions
primaryYAxisLabelOptions) (\s :: BoxPlotChartConfiguration
s@BoxPlotChartConfiguration' {} Maybe ChartAxisLabelOptions
a -> BoxPlotChartConfiguration
s {$sel:primaryYAxisLabelOptions:BoxPlotChartConfiguration' :: Maybe ChartAxisLabelOptions
primaryYAxisLabelOptions = Maybe ChartAxisLabelOptions
a} :: BoxPlotChartConfiguration)

-- | The reference line setup of the visual.
boxPlotChartConfiguration_referenceLines :: Lens.Lens' BoxPlotChartConfiguration (Prelude.Maybe [ReferenceLine])
boxPlotChartConfiguration_referenceLines :: Lens' BoxPlotChartConfiguration (Maybe [ReferenceLine])
boxPlotChartConfiguration_referenceLines = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\BoxPlotChartConfiguration' {Maybe [ReferenceLine]
referenceLines :: Maybe [ReferenceLine]
$sel:referenceLines:BoxPlotChartConfiguration' :: BoxPlotChartConfiguration -> Maybe [ReferenceLine]
referenceLines} -> Maybe [ReferenceLine]
referenceLines) (\s :: BoxPlotChartConfiguration
s@BoxPlotChartConfiguration' {} Maybe [ReferenceLine]
a -> BoxPlotChartConfiguration
s {$sel:referenceLines:BoxPlotChartConfiguration' :: Maybe [ReferenceLine]
referenceLines = Maybe [ReferenceLine]
a} :: BoxPlotChartConfiguration) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The sort configuration of a @BoxPlotVisual@.
boxPlotChartConfiguration_sortConfiguration :: Lens.Lens' BoxPlotChartConfiguration (Prelude.Maybe BoxPlotSortConfiguration)
boxPlotChartConfiguration_sortConfiguration :: Lens' BoxPlotChartConfiguration (Maybe BoxPlotSortConfiguration)
boxPlotChartConfiguration_sortConfiguration = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\BoxPlotChartConfiguration' {Maybe BoxPlotSortConfiguration
sortConfiguration :: Maybe BoxPlotSortConfiguration
$sel:sortConfiguration:BoxPlotChartConfiguration' :: BoxPlotChartConfiguration -> Maybe BoxPlotSortConfiguration
sortConfiguration} -> Maybe BoxPlotSortConfiguration
sortConfiguration) (\s :: BoxPlotChartConfiguration
s@BoxPlotChartConfiguration' {} Maybe BoxPlotSortConfiguration
a -> BoxPlotChartConfiguration
s {$sel:sortConfiguration:BoxPlotChartConfiguration' :: Maybe BoxPlotSortConfiguration
sortConfiguration = Maybe BoxPlotSortConfiguration
a} :: BoxPlotChartConfiguration)

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

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

instance Data.FromJSON BoxPlotChartConfiguration where
  parseJSON :: Value -> Parser BoxPlotChartConfiguration
parseJSON =
    forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.withObject
      String
"BoxPlotChartConfiguration"
      ( \Object
x ->
          Maybe BoxPlotOptions
-> Maybe AxisDisplayOptions
-> Maybe ChartAxisLabelOptions
-> Maybe BoxPlotFieldWells
-> Maybe LegendOptions
-> Maybe AxisDisplayOptions
-> Maybe ChartAxisLabelOptions
-> Maybe [ReferenceLine]
-> Maybe BoxPlotSortConfiguration
-> Maybe TooltipOptions
-> Maybe VisualPalette
-> BoxPlotChartConfiguration
BoxPlotChartConfiguration'
            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
"BoxPlotOptions")
            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
"CategoryAxis")
            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
"CategoryLabelOptions")
            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
"PrimaryYAxisDisplayOptions")
            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
"PrimaryYAxisLabelOptions")
            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
"ReferenceLines" forall a. Parser (Maybe a) -> a -> Parser a
Data..!= forall a. Monoid a => a
Prelude.mempty)
            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
"SortConfiguration")
            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")
      )

instance Prelude.Hashable BoxPlotChartConfiguration where
  hashWithSalt :: Int -> BoxPlotChartConfiguration -> Int
hashWithSalt Int
_salt BoxPlotChartConfiguration' {Maybe [ReferenceLine]
Maybe BoxPlotSortConfiguration
Maybe BoxPlotFieldWells
Maybe LegendOptions
Maybe TooltipOptions
Maybe ChartAxisLabelOptions
Maybe BoxPlotOptions
Maybe AxisDisplayOptions
Maybe VisualPalette
visualPalette :: Maybe VisualPalette
tooltip :: Maybe TooltipOptions
sortConfiguration :: Maybe BoxPlotSortConfiguration
referenceLines :: Maybe [ReferenceLine]
primaryYAxisLabelOptions :: Maybe ChartAxisLabelOptions
primaryYAxisDisplayOptions :: Maybe AxisDisplayOptions
legend :: Maybe LegendOptions
fieldWells :: Maybe BoxPlotFieldWells
categoryLabelOptions :: Maybe ChartAxisLabelOptions
categoryAxis :: Maybe AxisDisplayOptions
boxPlotOptions :: Maybe BoxPlotOptions
$sel:visualPalette:BoxPlotChartConfiguration' :: BoxPlotChartConfiguration -> Maybe VisualPalette
$sel:tooltip:BoxPlotChartConfiguration' :: BoxPlotChartConfiguration -> Maybe TooltipOptions
$sel:sortConfiguration:BoxPlotChartConfiguration' :: BoxPlotChartConfiguration -> Maybe BoxPlotSortConfiguration
$sel:referenceLines:BoxPlotChartConfiguration' :: BoxPlotChartConfiguration -> Maybe [ReferenceLine]
$sel:primaryYAxisLabelOptions:BoxPlotChartConfiguration' :: BoxPlotChartConfiguration -> Maybe ChartAxisLabelOptions
$sel:primaryYAxisDisplayOptions:BoxPlotChartConfiguration' :: BoxPlotChartConfiguration -> Maybe AxisDisplayOptions
$sel:legend:BoxPlotChartConfiguration' :: BoxPlotChartConfiguration -> Maybe LegendOptions
$sel:fieldWells:BoxPlotChartConfiguration' :: BoxPlotChartConfiguration -> Maybe BoxPlotFieldWells
$sel:categoryLabelOptions:BoxPlotChartConfiguration' :: BoxPlotChartConfiguration -> Maybe ChartAxisLabelOptions
$sel:categoryAxis:BoxPlotChartConfiguration' :: BoxPlotChartConfiguration -> Maybe AxisDisplayOptions
$sel:boxPlotOptions:BoxPlotChartConfiguration' :: BoxPlotChartConfiguration -> Maybe BoxPlotOptions
..} =
    Int
_salt
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe BoxPlotOptions
boxPlotOptions
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe AxisDisplayOptions
categoryAxis
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe ChartAxisLabelOptions
categoryLabelOptions
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe BoxPlotFieldWells
fieldWells
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe LegendOptions
legend
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe AxisDisplayOptions
primaryYAxisDisplayOptions
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe ChartAxisLabelOptions
primaryYAxisLabelOptions
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe [ReferenceLine]
referenceLines
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe BoxPlotSortConfiguration
sortConfiguration
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe TooltipOptions
tooltip
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe VisualPalette
visualPalette

instance Prelude.NFData BoxPlotChartConfiguration where
  rnf :: BoxPlotChartConfiguration -> ()
rnf BoxPlotChartConfiguration' {Maybe [ReferenceLine]
Maybe BoxPlotSortConfiguration
Maybe BoxPlotFieldWells
Maybe LegendOptions
Maybe TooltipOptions
Maybe ChartAxisLabelOptions
Maybe BoxPlotOptions
Maybe AxisDisplayOptions
Maybe VisualPalette
visualPalette :: Maybe VisualPalette
tooltip :: Maybe TooltipOptions
sortConfiguration :: Maybe BoxPlotSortConfiguration
referenceLines :: Maybe [ReferenceLine]
primaryYAxisLabelOptions :: Maybe ChartAxisLabelOptions
primaryYAxisDisplayOptions :: Maybe AxisDisplayOptions
legend :: Maybe LegendOptions
fieldWells :: Maybe BoxPlotFieldWells
categoryLabelOptions :: Maybe ChartAxisLabelOptions
categoryAxis :: Maybe AxisDisplayOptions
boxPlotOptions :: Maybe BoxPlotOptions
$sel:visualPalette:BoxPlotChartConfiguration' :: BoxPlotChartConfiguration -> Maybe VisualPalette
$sel:tooltip:BoxPlotChartConfiguration' :: BoxPlotChartConfiguration -> Maybe TooltipOptions
$sel:sortConfiguration:BoxPlotChartConfiguration' :: BoxPlotChartConfiguration -> Maybe BoxPlotSortConfiguration
$sel:referenceLines:BoxPlotChartConfiguration' :: BoxPlotChartConfiguration -> Maybe [ReferenceLine]
$sel:primaryYAxisLabelOptions:BoxPlotChartConfiguration' :: BoxPlotChartConfiguration -> Maybe ChartAxisLabelOptions
$sel:primaryYAxisDisplayOptions:BoxPlotChartConfiguration' :: BoxPlotChartConfiguration -> Maybe AxisDisplayOptions
$sel:legend:BoxPlotChartConfiguration' :: BoxPlotChartConfiguration -> Maybe LegendOptions
$sel:fieldWells:BoxPlotChartConfiguration' :: BoxPlotChartConfiguration -> Maybe BoxPlotFieldWells
$sel:categoryLabelOptions:BoxPlotChartConfiguration' :: BoxPlotChartConfiguration -> Maybe ChartAxisLabelOptions
$sel:categoryAxis:BoxPlotChartConfiguration' :: BoxPlotChartConfiguration -> Maybe AxisDisplayOptions
$sel:boxPlotOptions:BoxPlotChartConfiguration' :: BoxPlotChartConfiguration -> Maybe BoxPlotOptions
..} =
    forall a. NFData a => a -> ()
Prelude.rnf Maybe BoxPlotOptions
boxPlotOptions
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe AxisDisplayOptions
categoryAxis
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe ChartAxisLabelOptions
categoryLabelOptions
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe BoxPlotFieldWells
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 AxisDisplayOptions
primaryYAxisDisplayOptions
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe ChartAxisLabelOptions
primaryYAxisLabelOptions
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe [ReferenceLine]
referenceLines
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe BoxPlotSortConfiguration
sortConfiguration
      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

instance Data.ToJSON BoxPlotChartConfiguration where
  toJSON :: BoxPlotChartConfiguration -> Value
toJSON BoxPlotChartConfiguration' {Maybe [ReferenceLine]
Maybe BoxPlotSortConfiguration
Maybe BoxPlotFieldWells
Maybe LegendOptions
Maybe TooltipOptions
Maybe ChartAxisLabelOptions
Maybe BoxPlotOptions
Maybe AxisDisplayOptions
Maybe VisualPalette
visualPalette :: Maybe VisualPalette
tooltip :: Maybe TooltipOptions
sortConfiguration :: Maybe BoxPlotSortConfiguration
referenceLines :: Maybe [ReferenceLine]
primaryYAxisLabelOptions :: Maybe ChartAxisLabelOptions
primaryYAxisDisplayOptions :: Maybe AxisDisplayOptions
legend :: Maybe LegendOptions
fieldWells :: Maybe BoxPlotFieldWells
categoryLabelOptions :: Maybe ChartAxisLabelOptions
categoryAxis :: Maybe AxisDisplayOptions
boxPlotOptions :: Maybe BoxPlotOptions
$sel:visualPalette:BoxPlotChartConfiguration' :: BoxPlotChartConfiguration -> Maybe VisualPalette
$sel:tooltip:BoxPlotChartConfiguration' :: BoxPlotChartConfiguration -> Maybe TooltipOptions
$sel:sortConfiguration:BoxPlotChartConfiguration' :: BoxPlotChartConfiguration -> Maybe BoxPlotSortConfiguration
$sel:referenceLines:BoxPlotChartConfiguration' :: BoxPlotChartConfiguration -> Maybe [ReferenceLine]
$sel:primaryYAxisLabelOptions:BoxPlotChartConfiguration' :: BoxPlotChartConfiguration -> Maybe ChartAxisLabelOptions
$sel:primaryYAxisDisplayOptions:BoxPlotChartConfiguration' :: BoxPlotChartConfiguration -> Maybe AxisDisplayOptions
$sel:legend:BoxPlotChartConfiguration' :: BoxPlotChartConfiguration -> Maybe LegendOptions
$sel:fieldWells:BoxPlotChartConfiguration' :: BoxPlotChartConfiguration -> Maybe BoxPlotFieldWells
$sel:categoryLabelOptions:BoxPlotChartConfiguration' :: BoxPlotChartConfiguration -> Maybe ChartAxisLabelOptions
$sel:categoryAxis:BoxPlotChartConfiguration' :: BoxPlotChartConfiguration -> Maybe AxisDisplayOptions
$sel:boxPlotOptions:BoxPlotChartConfiguration' :: BoxPlotChartConfiguration -> Maybe BoxPlotOptions
..} =
    [Pair] -> Value
Data.object
      ( forall a. [Maybe a] -> [a]
Prelude.catMaybes
          [ (Key
"BoxPlotOptions" 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 BoxPlotOptions
boxPlotOptions,
            (Key
"CategoryAxis" 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
categoryAxis,
            (Key
"CategoryLabelOptions" 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
categoryLabelOptions,
            (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 BoxPlotFieldWells
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
"PrimaryYAxisDisplayOptions" 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
primaryYAxisDisplayOptions,
            (Key
"PrimaryYAxisLabelOptions" 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
primaryYAxisLabelOptions,
            (Key
"ReferenceLines" 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 [ReferenceLine]
referenceLines,
            (Key
"SortConfiguration" 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 BoxPlotSortConfiguration
sortConfiguration,
            (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
          ]
      )