module Stratosphere.QuickSight.Topic.CollectiveConstantProperty (
        CollectiveConstantProperty(..), mkCollectiveConstantProperty
    ) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data CollectiveConstantProperty
  = -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-quicksight-topic-collectiveconstant.html>
    CollectiveConstantProperty {CollectiveConstantProperty -> ()
haddock_workaround_ :: (),
                                -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-quicksight-topic-collectiveconstant.html#cfn-quicksight-topic-collectiveconstant-valuelist>
                                CollectiveConstantProperty -> Maybe (ValueList Text)
valueList :: (Prelude.Maybe (ValueList Prelude.Text))}
  deriving stock (CollectiveConstantProperty -> CollectiveConstantProperty -> Bool
(CollectiveConstantProperty -> CollectiveConstantProperty -> Bool)
-> (CollectiveConstantProperty
    -> CollectiveConstantProperty -> Bool)
-> Eq CollectiveConstantProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: CollectiveConstantProperty -> CollectiveConstantProperty -> Bool
== :: CollectiveConstantProperty -> CollectiveConstantProperty -> Bool
$c/= :: CollectiveConstantProperty -> CollectiveConstantProperty -> Bool
/= :: CollectiveConstantProperty -> CollectiveConstantProperty -> Bool
Prelude.Eq, Int -> CollectiveConstantProperty -> ShowS
[CollectiveConstantProperty] -> ShowS
CollectiveConstantProperty -> String
(Int -> CollectiveConstantProperty -> ShowS)
-> (CollectiveConstantProperty -> String)
-> ([CollectiveConstantProperty] -> ShowS)
-> Show CollectiveConstantProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> CollectiveConstantProperty -> ShowS
showsPrec :: Int -> CollectiveConstantProperty -> ShowS
$cshow :: CollectiveConstantProperty -> String
show :: CollectiveConstantProperty -> String
$cshowList :: [CollectiveConstantProperty] -> ShowS
showList :: [CollectiveConstantProperty] -> ShowS
Prelude.Show)
mkCollectiveConstantProperty :: CollectiveConstantProperty
mkCollectiveConstantProperty :: CollectiveConstantProperty
mkCollectiveConstantProperty
  = CollectiveConstantProperty
      {haddock_workaround_ :: ()
haddock_workaround_ = (), valueList :: Maybe (ValueList Text)
valueList = Maybe (ValueList Text)
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties CollectiveConstantProperty where
  toResourceProperties :: CollectiveConstantProperty -> ResourceProperties
toResourceProperties CollectiveConstantProperty {Maybe (ValueList Text)
()
haddock_workaround_ :: CollectiveConstantProperty -> ()
valueList :: CollectiveConstantProperty -> Maybe (ValueList Text)
haddock_workaround_ :: ()
valueList :: Maybe (ValueList Text)
..}
    = ResourceProperties
        {awsType :: Text
awsType = Text
"AWS::QuickSight::Topic.CollectiveConstant",
         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 -> ValueList 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
"ValueList" (ValueList Text -> (Key, Value))
-> Maybe (ValueList Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (ValueList Text)
valueList])}
instance JSON.ToJSON CollectiveConstantProperty where
  toJSON :: CollectiveConstantProperty -> Value
toJSON CollectiveConstantProperty {Maybe (ValueList Text)
()
haddock_workaround_ :: CollectiveConstantProperty -> ()
valueList :: CollectiveConstantProperty -> Maybe (ValueList Text)
haddock_workaround_ :: ()
valueList :: Maybe (ValueList Text)
..}
    = [(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 -> ValueList 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
"ValueList" (ValueList Text -> (Key, Value))
-> Maybe (ValueList Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (ValueList Text)
valueList]))
instance Property "ValueList" CollectiveConstantProperty where
  type PropertyType "ValueList" CollectiveConstantProperty = ValueList Prelude.Text
  set :: PropertyType "ValueList" CollectiveConstantProperty
-> CollectiveConstantProperty -> CollectiveConstantProperty
set PropertyType "ValueList" CollectiveConstantProperty
newValue CollectiveConstantProperty {Maybe (ValueList Text)
()
haddock_workaround_ :: CollectiveConstantProperty -> ()
valueList :: CollectiveConstantProperty -> Maybe (ValueList Text)
haddock_workaround_ :: ()
valueList :: Maybe (ValueList Text)
..}
    = CollectiveConstantProperty
        {valueList :: Maybe (ValueList Text)
valueList = ValueList Text -> Maybe (ValueList Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "ValueList" CollectiveConstantProperty
ValueList Text
newValue, ()
haddock_workaround_ :: ()
haddock_workaround_ :: ()
..}