module Stratosphere.Athena.WorkGroup (
module Exports, WorkGroup(..), mkWorkGroup
) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import {-# SOURCE #-} Stratosphere.Athena.WorkGroup.WorkGroupConfigurationProperty as Exports
import Stratosphere.ResourceProperties
import Stratosphere.Tag
import Stratosphere.Value
data WorkGroup
=
WorkGroup {WorkGroup -> ()
haddock_workaround_ :: (),
WorkGroup -> Maybe (Value Text)
description :: (Prelude.Maybe (Value Prelude.Text)),
WorkGroup -> Value Text
name :: (Value Prelude.Text),
WorkGroup -> Maybe (Value Bool)
recursiveDeleteOption :: (Prelude.Maybe (Value Prelude.Bool)),
WorkGroup -> Maybe (Value Text)
state :: (Prelude.Maybe (Value Prelude.Text)),
WorkGroup -> Maybe [Tag]
tags :: (Prelude.Maybe [Tag]),
WorkGroup -> Maybe WorkGroupConfigurationProperty
workGroupConfiguration :: (Prelude.Maybe WorkGroupConfigurationProperty)}
deriving stock (WorkGroup -> WorkGroup -> Bool
(WorkGroup -> WorkGroup -> Bool)
-> (WorkGroup -> WorkGroup -> Bool) -> Eq WorkGroup
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: WorkGroup -> WorkGroup -> Bool
== :: WorkGroup -> WorkGroup -> Bool
$c/= :: WorkGroup -> WorkGroup -> Bool
/= :: WorkGroup -> WorkGroup -> Bool
Prelude.Eq, Int -> WorkGroup -> ShowS
[WorkGroup] -> ShowS
WorkGroup -> String
(Int -> WorkGroup -> ShowS)
-> (WorkGroup -> String)
-> ([WorkGroup] -> ShowS)
-> Show WorkGroup
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> WorkGroup -> ShowS
showsPrec :: Int -> WorkGroup -> ShowS
$cshow :: WorkGroup -> String
show :: WorkGroup -> String
$cshowList :: [WorkGroup] -> ShowS
showList :: [WorkGroup] -> ShowS
Prelude.Show)
mkWorkGroup :: Value Prelude.Text -> WorkGroup
mkWorkGroup :: Value Text -> WorkGroup
mkWorkGroup Value Text
name
= WorkGroup
{haddock_workaround_ :: ()
haddock_workaround_ = (), name :: Value Text
name = Value Text
name,
description :: Maybe (Value Text)
description = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing,
recursiveDeleteOption :: Maybe (Value Bool)
recursiveDeleteOption = Maybe (Value Bool)
forall a. Maybe a
Prelude.Nothing, state :: Maybe (Value Text)
state = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing,
tags :: Maybe [Tag]
tags = Maybe [Tag]
forall a. Maybe a
Prelude.Nothing, workGroupConfiguration :: Maybe WorkGroupConfigurationProperty
workGroupConfiguration = Maybe WorkGroupConfigurationProperty
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties WorkGroup where
toResourceProperties :: WorkGroup -> ResourceProperties
toResourceProperties WorkGroup {Maybe [Tag]
Maybe (Value Bool)
Maybe (Value Text)
Maybe WorkGroupConfigurationProperty
()
Value Text
haddock_workaround_ :: WorkGroup -> ()
description :: WorkGroup -> Maybe (Value Text)
name :: WorkGroup -> Value Text
recursiveDeleteOption :: WorkGroup -> Maybe (Value Bool)
state :: WorkGroup -> Maybe (Value Text)
tags :: WorkGroup -> Maybe [Tag]
workGroupConfiguration :: WorkGroup -> Maybe WorkGroupConfigurationProperty
haddock_workaround_ :: ()
description :: Maybe (Value Text)
name :: Value Text
recursiveDeleteOption :: Maybe (Value Bool)
state :: Maybe (Value Text)
tags :: Maybe [Tag]
workGroupConfiguration :: Maybe WorkGroupConfigurationProperty
..}
= ResourceProperties
{awsType :: Text
awsType = Text
"AWS::Athena::WorkGroup", supportsTags :: Bool
supportsTags = Bool
Prelude.True,
properties :: Object
properties = [Item Object] -> Object
forall l. IsList l => [Item l] -> l
Prelude.fromList
([(Key, Value)] -> [(Key, Value)] -> [(Key, Value)]
forall a. Semigroup a => a -> a -> a
(Prelude.<>)
[Key
"Name" 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..= Value Text
name]
([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[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
"Description" (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)
description,
Key -> Value Bool -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"RecursiveDeleteOption"
(Value Bool -> (Key, Value))
-> Maybe (Value Bool) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Bool)
recursiveDeleteOption,
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
"State" (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)
state,
Key -> [Tag] -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"Tags" ([Tag] -> (Key, Value)) -> Maybe [Tag] -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [Tag]
tags,
Key -> WorkGroupConfigurationProperty -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"WorkGroupConfiguration"
(WorkGroupConfigurationProperty -> (Key, Value))
-> Maybe WorkGroupConfigurationProperty -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe WorkGroupConfigurationProperty
workGroupConfiguration]))}
instance JSON.ToJSON WorkGroup where
toJSON :: WorkGroup -> Value
toJSON WorkGroup {Maybe [Tag]
Maybe (Value Bool)
Maybe (Value Text)
Maybe WorkGroupConfigurationProperty
()
Value Text
haddock_workaround_ :: WorkGroup -> ()
description :: WorkGroup -> Maybe (Value Text)
name :: WorkGroup -> Value Text
recursiveDeleteOption :: WorkGroup -> Maybe (Value Bool)
state :: WorkGroup -> Maybe (Value Text)
tags :: WorkGroup -> Maybe [Tag]
workGroupConfiguration :: WorkGroup -> Maybe WorkGroupConfigurationProperty
haddock_workaround_ :: ()
description :: Maybe (Value Text)
name :: Value Text
recursiveDeleteOption :: Maybe (Value Bool)
state :: Maybe (Value Text)
tags :: Maybe [Tag]
workGroupConfiguration :: Maybe WorkGroupConfigurationProperty
..}
= [(Key, Value)] -> Value
JSON.object
([Item [(Key, Value)]] -> [(Key, Value)]
forall l. IsList l => [Item l] -> l
Prelude.fromList
([(Key, Value)] -> [(Key, Value)] -> [(Key, Value)]
forall a. Semigroup a => a -> a -> a
(Prelude.<>)
[Key
"Name" 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..= Value Text
name]
([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[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
"Description" (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)
description,
Key -> Value Bool -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"RecursiveDeleteOption"
(Value Bool -> (Key, Value))
-> Maybe (Value Bool) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Bool)
recursiveDeleteOption,
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
"State" (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)
state,
Key -> [Tag] -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"Tags" ([Tag] -> (Key, Value)) -> Maybe [Tag] -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [Tag]
tags,
Key -> WorkGroupConfigurationProperty -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"WorkGroupConfiguration"
(WorkGroupConfigurationProperty -> (Key, Value))
-> Maybe WorkGroupConfigurationProperty -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe WorkGroupConfigurationProperty
workGroupConfiguration])))
instance Property "Description" WorkGroup where
type PropertyType "Description" WorkGroup = Value Prelude.Text
set :: PropertyType "Description" WorkGroup -> WorkGroup -> WorkGroup
set PropertyType "Description" WorkGroup
newValue WorkGroup {Maybe [Tag]
Maybe (Value Bool)
Maybe (Value Text)
Maybe WorkGroupConfigurationProperty
()
Value Text
haddock_workaround_ :: WorkGroup -> ()
description :: WorkGroup -> Maybe (Value Text)
name :: WorkGroup -> Value Text
recursiveDeleteOption :: WorkGroup -> Maybe (Value Bool)
state :: WorkGroup -> Maybe (Value Text)
tags :: WorkGroup -> Maybe [Tag]
workGroupConfiguration :: WorkGroup -> Maybe WorkGroupConfigurationProperty
haddock_workaround_ :: ()
description :: Maybe (Value Text)
name :: Value Text
recursiveDeleteOption :: Maybe (Value Bool)
state :: Maybe (Value Text)
tags :: Maybe [Tag]
workGroupConfiguration :: Maybe WorkGroupConfigurationProperty
..}
= WorkGroup {description :: Maybe (Value Text)
description = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "Description" WorkGroup
Value Text
newValue, Maybe [Tag]
Maybe (Value Bool)
Maybe (Value Text)
Maybe WorkGroupConfigurationProperty
()
Value Text
haddock_workaround_ :: ()
name :: Value Text
recursiveDeleteOption :: Maybe (Value Bool)
state :: Maybe (Value Text)
tags :: Maybe [Tag]
workGroupConfiguration :: Maybe WorkGroupConfigurationProperty
haddock_workaround_ :: ()
name :: Value Text
recursiveDeleteOption :: Maybe (Value Bool)
state :: Maybe (Value Text)
tags :: Maybe [Tag]
workGroupConfiguration :: Maybe WorkGroupConfigurationProperty
..}
instance Property "Name" WorkGroup where
type PropertyType "Name" WorkGroup = Value Prelude.Text
set :: PropertyType "Name" WorkGroup -> WorkGroup -> WorkGroup
set PropertyType "Name" WorkGroup
newValue WorkGroup {Maybe [Tag]
Maybe (Value Bool)
Maybe (Value Text)
Maybe WorkGroupConfigurationProperty
()
Value Text
haddock_workaround_ :: WorkGroup -> ()
description :: WorkGroup -> Maybe (Value Text)
name :: WorkGroup -> Value Text
recursiveDeleteOption :: WorkGroup -> Maybe (Value Bool)
state :: WorkGroup -> Maybe (Value Text)
tags :: WorkGroup -> Maybe [Tag]
workGroupConfiguration :: WorkGroup -> Maybe WorkGroupConfigurationProperty
haddock_workaround_ :: ()
description :: Maybe (Value Text)
name :: Value Text
recursiveDeleteOption :: Maybe (Value Bool)
state :: Maybe (Value Text)
tags :: Maybe [Tag]
workGroupConfiguration :: Maybe WorkGroupConfigurationProperty
..} = WorkGroup {name :: Value Text
name = PropertyType "Name" WorkGroup
Value Text
newValue, Maybe [Tag]
Maybe (Value Bool)
Maybe (Value Text)
Maybe WorkGroupConfigurationProperty
()
haddock_workaround_ :: ()
description :: Maybe (Value Text)
recursiveDeleteOption :: Maybe (Value Bool)
state :: Maybe (Value Text)
tags :: Maybe [Tag]
workGroupConfiguration :: Maybe WorkGroupConfigurationProperty
haddock_workaround_ :: ()
description :: Maybe (Value Text)
recursiveDeleteOption :: Maybe (Value Bool)
state :: Maybe (Value Text)
tags :: Maybe [Tag]
workGroupConfiguration :: Maybe WorkGroupConfigurationProperty
..}
instance Property "RecursiveDeleteOption" WorkGroup where
type PropertyType "RecursiveDeleteOption" WorkGroup = Value Prelude.Bool
set :: PropertyType "RecursiveDeleteOption" WorkGroup
-> WorkGroup -> WorkGroup
set PropertyType "RecursiveDeleteOption" WorkGroup
newValue WorkGroup {Maybe [Tag]
Maybe (Value Bool)
Maybe (Value Text)
Maybe WorkGroupConfigurationProperty
()
Value Text
haddock_workaround_ :: WorkGroup -> ()
description :: WorkGroup -> Maybe (Value Text)
name :: WorkGroup -> Value Text
recursiveDeleteOption :: WorkGroup -> Maybe (Value Bool)
state :: WorkGroup -> Maybe (Value Text)
tags :: WorkGroup -> Maybe [Tag]
workGroupConfiguration :: WorkGroup -> Maybe WorkGroupConfigurationProperty
haddock_workaround_ :: ()
description :: Maybe (Value Text)
name :: Value Text
recursiveDeleteOption :: Maybe (Value Bool)
state :: Maybe (Value Text)
tags :: Maybe [Tag]
workGroupConfiguration :: Maybe WorkGroupConfigurationProperty
..}
= WorkGroup {recursiveDeleteOption :: Maybe (Value Bool)
recursiveDeleteOption = Value Bool -> Maybe (Value Bool)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "RecursiveDeleteOption" WorkGroup
Value Bool
newValue, Maybe [Tag]
Maybe (Value Text)
Maybe WorkGroupConfigurationProperty
()
Value Text
haddock_workaround_ :: ()
description :: Maybe (Value Text)
name :: Value Text
state :: Maybe (Value Text)
tags :: Maybe [Tag]
workGroupConfiguration :: Maybe WorkGroupConfigurationProperty
haddock_workaround_ :: ()
description :: Maybe (Value Text)
name :: Value Text
state :: Maybe (Value Text)
tags :: Maybe [Tag]
workGroupConfiguration :: Maybe WorkGroupConfigurationProperty
..}
instance Property "State" WorkGroup where
type PropertyType "State" WorkGroup = Value Prelude.Text
set :: PropertyType "State" WorkGroup -> WorkGroup -> WorkGroup
set PropertyType "State" WorkGroup
newValue WorkGroup {Maybe [Tag]
Maybe (Value Bool)
Maybe (Value Text)
Maybe WorkGroupConfigurationProperty
()
Value Text
haddock_workaround_ :: WorkGroup -> ()
description :: WorkGroup -> Maybe (Value Text)
name :: WorkGroup -> Value Text
recursiveDeleteOption :: WorkGroup -> Maybe (Value Bool)
state :: WorkGroup -> Maybe (Value Text)
tags :: WorkGroup -> Maybe [Tag]
workGroupConfiguration :: WorkGroup -> Maybe WorkGroupConfigurationProperty
haddock_workaround_ :: ()
description :: Maybe (Value Text)
name :: Value Text
recursiveDeleteOption :: Maybe (Value Bool)
state :: Maybe (Value Text)
tags :: Maybe [Tag]
workGroupConfiguration :: Maybe WorkGroupConfigurationProperty
..}
= WorkGroup {state :: Maybe (Value Text)
state = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "State" WorkGroup
Value Text
newValue, Maybe [Tag]
Maybe (Value Bool)
Maybe (Value Text)
Maybe WorkGroupConfigurationProperty
()
Value Text
haddock_workaround_ :: ()
description :: Maybe (Value Text)
name :: Value Text
recursiveDeleteOption :: Maybe (Value Bool)
tags :: Maybe [Tag]
workGroupConfiguration :: Maybe WorkGroupConfigurationProperty
haddock_workaround_ :: ()
description :: Maybe (Value Text)
name :: Value Text
recursiveDeleteOption :: Maybe (Value Bool)
tags :: Maybe [Tag]
workGroupConfiguration :: Maybe WorkGroupConfigurationProperty
..}
instance Property "Tags" WorkGroup where
type PropertyType "Tags" WorkGroup = [Tag]
set :: PropertyType "Tags" WorkGroup -> WorkGroup -> WorkGroup
set PropertyType "Tags" WorkGroup
newValue WorkGroup {Maybe [Tag]
Maybe (Value Bool)
Maybe (Value Text)
Maybe WorkGroupConfigurationProperty
()
Value Text
haddock_workaround_ :: WorkGroup -> ()
description :: WorkGroup -> Maybe (Value Text)
name :: WorkGroup -> Value Text
recursiveDeleteOption :: WorkGroup -> Maybe (Value Bool)
state :: WorkGroup -> Maybe (Value Text)
tags :: WorkGroup -> Maybe [Tag]
workGroupConfiguration :: WorkGroup -> Maybe WorkGroupConfigurationProperty
haddock_workaround_ :: ()
description :: Maybe (Value Text)
name :: Value Text
recursiveDeleteOption :: Maybe (Value Bool)
state :: Maybe (Value Text)
tags :: Maybe [Tag]
workGroupConfiguration :: Maybe WorkGroupConfigurationProperty
..}
= WorkGroup {tags :: Maybe [Tag]
tags = [Tag] -> Maybe [Tag]
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure [Tag]
PropertyType "Tags" WorkGroup
newValue, Maybe (Value Bool)
Maybe (Value Text)
Maybe WorkGroupConfigurationProperty
()
Value Text
haddock_workaround_ :: ()
description :: Maybe (Value Text)
name :: Value Text
recursiveDeleteOption :: Maybe (Value Bool)
state :: Maybe (Value Text)
workGroupConfiguration :: Maybe WorkGroupConfigurationProperty
haddock_workaround_ :: ()
description :: Maybe (Value Text)
name :: Value Text
recursiveDeleteOption :: Maybe (Value Bool)
state :: Maybe (Value Text)
workGroupConfiguration :: Maybe WorkGroupConfigurationProperty
..}
instance Property "WorkGroupConfiguration" WorkGroup where
type PropertyType "WorkGroupConfiguration" WorkGroup = WorkGroupConfigurationProperty
set :: PropertyType "WorkGroupConfiguration" WorkGroup
-> WorkGroup -> WorkGroup
set PropertyType "WorkGroupConfiguration" WorkGroup
newValue WorkGroup {Maybe [Tag]
Maybe (Value Bool)
Maybe (Value Text)
Maybe WorkGroupConfigurationProperty
()
Value Text
haddock_workaround_ :: WorkGroup -> ()
description :: WorkGroup -> Maybe (Value Text)
name :: WorkGroup -> Value Text
recursiveDeleteOption :: WorkGroup -> Maybe (Value Bool)
state :: WorkGroup -> Maybe (Value Text)
tags :: WorkGroup -> Maybe [Tag]
workGroupConfiguration :: WorkGroup -> Maybe WorkGroupConfigurationProperty
haddock_workaround_ :: ()
description :: Maybe (Value Text)
name :: Value Text
recursiveDeleteOption :: Maybe (Value Bool)
state :: Maybe (Value Text)
tags :: Maybe [Tag]
workGroupConfiguration :: Maybe WorkGroupConfigurationProperty
..}
= WorkGroup {workGroupConfiguration :: Maybe WorkGroupConfigurationProperty
workGroupConfiguration = WorkGroupConfigurationProperty
-> Maybe WorkGroupConfigurationProperty
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "WorkGroupConfiguration" WorkGroup
WorkGroupConfigurationProperty
newValue, Maybe [Tag]
Maybe (Value Bool)
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ()
description :: Maybe (Value Text)
name :: Value Text
recursiveDeleteOption :: Maybe (Value Bool)
state :: Maybe (Value Text)
tags :: Maybe [Tag]
haddock_workaround_ :: ()
description :: Maybe (Value Text)
name :: Value Text
recursiveDeleteOption :: Maybe (Value Bool)
state :: Maybe (Value Text)
tags :: Maybe [Tag]
..}