module Stratosphere.QuickSight.DataSource.AthenaParametersProperty (
        module Exports, AthenaParametersProperty(..),
        mkAthenaParametersProperty
    ) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import {-# SOURCE #-} Stratosphere.QuickSight.DataSource.IdentityCenterConfigurationProperty as Exports
import Stratosphere.ResourceProperties
import Stratosphere.Value
data AthenaParametersProperty
  = -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-quicksight-datasource-athenaparameters.html>
    AthenaParametersProperty {AthenaParametersProperty -> ()
haddock_workaround_ :: (),
                              -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-quicksight-datasource-athenaparameters.html#cfn-quicksight-datasource-athenaparameters-identitycenterconfiguration>
                              AthenaParametersProperty
-> Maybe IdentityCenterConfigurationProperty
identityCenterConfiguration :: (Prelude.Maybe IdentityCenterConfigurationProperty),
                              -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-quicksight-datasource-athenaparameters.html#cfn-quicksight-datasource-athenaparameters-rolearn>
                              AthenaParametersProperty -> Maybe (Value Text)
roleArn :: (Prelude.Maybe (Value Prelude.Text)),
                              -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-quicksight-datasource-athenaparameters.html#cfn-quicksight-datasource-athenaparameters-workgroup>
                              AthenaParametersProperty -> Maybe (Value Text)
workGroup :: (Prelude.Maybe (Value Prelude.Text))}
  deriving stock (AthenaParametersProperty -> AthenaParametersProperty -> Bool
(AthenaParametersProperty -> AthenaParametersProperty -> Bool)
-> (AthenaParametersProperty -> AthenaParametersProperty -> Bool)
-> Eq AthenaParametersProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: AthenaParametersProperty -> AthenaParametersProperty -> Bool
== :: AthenaParametersProperty -> AthenaParametersProperty -> Bool
$c/= :: AthenaParametersProperty -> AthenaParametersProperty -> Bool
/= :: AthenaParametersProperty -> AthenaParametersProperty -> Bool
Prelude.Eq, Int -> AthenaParametersProperty -> ShowS
[AthenaParametersProperty] -> ShowS
AthenaParametersProperty -> String
(Int -> AthenaParametersProperty -> ShowS)
-> (AthenaParametersProperty -> String)
-> ([AthenaParametersProperty] -> ShowS)
-> Show AthenaParametersProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> AthenaParametersProperty -> ShowS
showsPrec :: Int -> AthenaParametersProperty -> ShowS
$cshow :: AthenaParametersProperty -> String
show :: AthenaParametersProperty -> String
$cshowList :: [AthenaParametersProperty] -> ShowS
showList :: [AthenaParametersProperty] -> ShowS
Prelude.Show)
mkAthenaParametersProperty :: AthenaParametersProperty
mkAthenaParametersProperty :: AthenaParametersProperty
mkAthenaParametersProperty
  = AthenaParametersProperty
      {haddock_workaround_ :: ()
haddock_workaround_ = (),
       identityCenterConfiguration :: Maybe IdentityCenterConfigurationProperty
identityCenterConfiguration = Maybe IdentityCenterConfigurationProperty
forall a. Maybe a
Prelude.Nothing,
       roleArn :: Maybe (Value Text)
roleArn = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing, workGroup :: Maybe (Value Text)
workGroup = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties AthenaParametersProperty where
  toResourceProperties :: AthenaParametersProperty -> ResourceProperties
toResourceProperties AthenaParametersProperty {Maybe (Value Text)
Maybe IdentityCenterConfigurationProperty
()
haddock_workaround_ :: AthenaParametersProperty -> ()
identityCenterConfiguration :: AthenaParametersProperty
-> Maybe IdentityCenterConfigurationProperty
roleArn :: AthenaParametersProperty -> Maybe (Value Text)
workGroup :: AthenaParametersProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
identityCenterConfiguration :: Maybe IdentityCenterConfigurationProperty
roleArn :: Maybe (Value Text)
workGroup :: Maybe (Value Text)
..}
    = ResourceProperties
        {awsType :: Text
awsType = Text
"AWS::QuickSight::DataSource.AthenaParameters",
         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 -> IdentityCenterConfigurationProperty -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"IdentityCenterConfiguration"
                              (IdentityCenterConfigurationProperty -> (Key, Value))
-> Maybe IdentityCenterConfigurationProperty -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe IdentityCenterConfigurationProperty
identityCenterConfiguration,
                            Key -> Value 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
"RoleArn" (Value Text -> (Key, Value))
-> Maybe (Value Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Text)
roleArn,
                            Key -> Value 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
"WorkGroup" (Value Text -> (Key, Value))
-> Maybe (Value Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Text)
workGroup])}
instance JSON.ToJSON AthenaParametersProperty where
  toJSON :: AthenaParametersProperty -> Value
toJSON AthenaParametersProperty {Maybe (Value Text)
Maybe IdentityCenterConfigurationProperty
()
haddock_workaround_ :: AthenaParametersProperty -> ()
identityCenterConfiguration :: AthenaParametersProperty
-> Maybe IdentityCenterConfigurationProperty
roleArn :: AthenaParametersProperty -> Maybe (Value Text)
workGroup :: AthenaParametersProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
identityCenterConfiguration :: Maybe IdentityCenterConfigurationProperty
roleArn :: Maybe (Value Text)
workGroup :: Maybe (Value 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 -> IdentityCenterConfigurationProperty -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"IdentityCenterConfiguration"
                 (IdentityCenterConfigurationProperty -> (Key, Value))
-> Maybe IdentityCenterConfigurationProperty -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe IdentityCenterConfigurationProperty
identityCenterConfiguration,
               Key -> Value 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
"RoleArn" (Value Text -> (Key, Value))
-> Maybe (Value Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Text)
roleArn,
               Key -> Value 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
"WorkGroup" (Value Text -> (Key, Value))
-> Maybe (Value Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Text)
workGroup]))
instance Property "IdentityCenterConfiguration" AthenaParametersProperty where
  type PropertyType "IdentityCenterConfiguration" AthenaParametersProperty = IdentityCenterConfigurationProperty
  set :: PropertyType "IdentityCenterConfiguration" AthenaParametersProperty
-> AthenaParametersProperty -> AthenaParametersProperty
set PropertyType "IdentityCenterConfiguration" AthenaParametersProperty
newValue AthenaParametersProperty {Maybe (Value Text)
Maybe IdentityCenterConfigurationProperty
()
haddock_workaround_ :: AthenaParametersProperty -> ()
identityCenterConfiguration :: AthenaParametersProperty
-> Maybe IdentityCenterConfigurationProperty
roleArn :: AthenaParametersProperty -> Maybe (Value Text)
workGroup :: AthenaParametersProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
identityCenterConfiguration :: Maybe IdentityCenterConfigurationProperty
roleArn :: Maybe (Value Text)
workGroup :: Maybe (Value Text)
..}
    = AthenaParametersProperty
        {identityCenterConfiguration :: Maybe IdentityCenterConfigurationProperty
identityCenterConfiguration = IdentityCenterConfigurationProperty
-> Maybe IdentityCenterConfigurationProperty
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "IdentityCenterConfiguration" AthenaParametersProperty
IdentityCenterConfigurationProperty
newValue, Maybe (Value Text)
()
haddock_workaround_ :: ()
roleArn :: Maybe (Value Text)
workGroup :: Maybe (Value Text)
haddock_workaround_ :: ()
roleArn :: Maybe (Value Text)
workGroup :: Maybe (Value Text)
..}
instance Property "RoleArn" AthenaParametersProperty where
  type PropertyType "RoleArn" AthenaParametersProperty = Value Prelude.Text
  set :: PropertyType "RoleArn" AthenaParametersProperty
-> AthenaParametersProperty -> AthenaParametersProperty
set PropertyType "RoleArn" AthenaParametersProperty
newValue AthenaParametersProperty {Maybe (Value Text)
Maybe IdentityCenterConfigurationProperty
()
haddock_workaround_ :: AthenaParametersProperty -> ()
identityCenterConfiguration :: AthenaParametersProperty
-> Maybe IdentityCenterConfigurationProperty
roleArn :: AthenaParametersProperty -> Maybe (Value Text)
workGroup :: AthenaParametersProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
identityCenterConfiguration :: Maybe IdentityCenterConfigurationProperty
roleArn :: Maybe (Value Text)
workGroup :: Maybe (Value Text)
..}
    = AthenaParametersProperty {roleArn :: Maybe (Value Text)
roleArn = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "RoleArn" AthenaParametersProperty
Value Text
newValue, Maybe (Value Text)
Maybe IdentityCenterConfigurationProperty
()
haddock_workaround_ :: ()
identityCenterConfiguration :: Maybe IdentityCenterConfigurationProperty
workGroup :: Maybe (Value Text)
haddock_workaround_ :: ()
identityCenterConfiguration :: Maybe IdentityCenterConfigurationProperty
workGroup :: Maybe (Value Text)
..}
instance Property "WorkGroup" AthenaParametersProperty where
  type PropertyType "WorkGroup" AthenaParametersProperty = Value Prelude.Text
  set :: PropertyType "WorkGroup" AthenaParametersProperty
-> AthenaParametersProperty -> AthenaParametersProperty
set PropertyType "WorkGroup" AthenaParametersProperty
newValue AthenaParametersProperty {Maybe (Value Text)
Maybe IdentityCenterConfigurationProperty
()
haddock_workaround_ :: AthenaParametersProperty -> ()
identityCenterConfiguration :: AthenaParametersProperty
-> Maybe IdentityCenterConfigurationProperty
roleArn :: AthenaParametersProperty -> Maybe (Value Text)
workGroup :: AthenaParametersProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
identityCenterConfiguration :: Maybe IdentityCenterConfigurationProperty
roleArn :: Maybe (Value Text)
workGroup :: Maybe (Value Text)
..}
    = AthenaParametersProperty {workGroup :: Maybe (Value Text)
workGroup = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "WorkGroup" AthenaParametersProperty
Value Text
newValue, Maybe (Value Text)
Maybe IdentityCenterConfigurationProperty
()
haddock_workaround_ :: ()
identityCenterConfiguration :: Maybe IdentityCenterConfigurationProperty
roleArn :: Maybe (Value Text)
haddock_workaround_ :: ()
identityCenterConfiguration :: Maybe IdentityCenterConfigurationProperty
roleArn :: Maybe (Value Text)
..}