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