module Stratosphere.MPA.ApprovalTeam (
module Exports, ApprovalTeam(..), mkApprovalTeam
) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import {-# SOURCE #-} Stratosphere.MPA.ApprovalTeam.ApprovalStrategyProperty as Exports
import {-# SOURCE #-} Stratosphere.MPA.ApprovalTeam.ApproverProperty as Exports
import {-# SOURCE #-} Stratosphere.MPA.ApprovalTeam.PolicyProperty as Exports
import Stratosphere.ResourceProperties
import Stratosphere.Tag
import Stratosphere.Value
data ApprovalTeam
=
ApprovalTeam {ApprovalTeam -> ()
haddock_workaround_ :: (),
ApprovalTeam -> ApprovalStrategyProperty
approvalStrategy :: ApprovalStrategyProperty,
ApprovalTeam -> [ApproverProperty]
approvers :: [ApproverProperty],
ApprovalTeam -> Value Text
description :: (Value Prelude.Text),
ApprovalTeam -> Value Text
name :: (Value Prelude.Text),
ApprovalTeam -> [PolicyProperty]
policies :: [PolicyProperty],
ApprovalTeam -> Maybe [Tag]
tags :: (Prelude.Maybe [Tag])}
deriving stock (ApprovalTeam -> ApprovalTeam -> Bool
(ApprovalTeam -> ApprovalTeam -> Bool)
-> (ApprovalTeam -> ApprovalTeam -> Bool) -> Eq ApprovalTeam
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: ApprovalTeam -> ApprovalTeam -> Bool
== :: ApprovalTeam -> ApprovalTeam -> Bool
$c/= :: ApprovalTeam -> ApprovalTeam -> Bool
/= :: ApprovalTeam -> ApprovalTeam -> Bool
Prelude.Eq, Int -> ApprovalTeam -> ShowS
[ApprovalTeam] -> ShowS
ApprovalTeam -> String
(Int -> ApprovalTeam -> ShowS)
-> (ApprovalTeam -> String)
-> ([ApprovalTeam] -> ShowS)
-> Show ApprovalTeam
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> ApprovalTeam -> ShowS
showsPrec :: Int -> ApprovalTeam -> ShowS
$cshow :: ApprovalTeam -> String
show :: ApprovalTeam -> String
$cshowList :: [ApprovalTeam] -> ShowS
showList :: [ApprovalTeam] -> ShowS
Prelude.Show)
mkApprovalTeam ::
ApprovalStrategyProperty
-> [ApproverProperty]
-> Value Prelude.Text
-> Value Prelude.Text -> [PolicyProperty] -> ApprovalTeam
mkApprovalTeam :: ApprovalStrategyProperty
-> [ApproverProperty]
-> Value Text
-> Value Text
-> [PolicyProperty]
-> ApprovalTeam
mkApprovalTeam ApprovalStrategyProperty
approvalStrategy [ApproverProperty]
approvers Value Text
description Value Text
name [PolicyProperty]
policies
= ApprovalTeam
{haddock_workaround_ :: ()
haddock_workaround_ = (), approvalStrategy :: ApprovalStrategyProperty
approvalStrategy = ApprovalStrategyProperty
approvalStrategy,
approvers :: [ApproverProperty]
approvers = [ApproverProperty]
approvers, description :: Value Text
description = Value Text
description, name :: Value Text
name = Value Text
name,
policies :: [PolicyProperty]
policies = [PolicyProperty]
policies, tags :: Maybe [Tag]
tags = Maybe [Tag]
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties ApprovalTeam where
toResourceProperties :: ApprovalTeam -> ResourceProperties
toResourceProperties ApprovalTeam {[ApproverProperty]
[PolicyProperty]
Maybe [Tag]
()
Value Text
ApprovalStrategyProperty
haddock_workaround_ :: ApprovalTeam -> ()
approvalStrategy :: ApprovalTeam -> ApprovalStrategyProperty
approvers :: ApprovalTeam -> [ApproverProperty]
description :: ApprovalTeam -> Value Text
name :: ApprovalTeam -> Value Text
policies :: ApprovalTeam -> [PolicyProperty]
tags :: ApprovalTeam -> Maybe [Tag]
haddock_workaround_ :: ()
approvalStrategy :: ApprovalStrategyProperty
approvers :: [ApproverProperty]
description :: Value Text
name :: Value Text
policies :: [PolicyProperty]
tags :: Maybe [Tag]
..}
= ResourceProperties
{awsType :: Text
awsType = Text
"AWS::MPA::ApprovalTeam", 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
"ApprovalStrategy" Key -> ApprovalStrategyProperty -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= ApprovalStrategyProperty
approvalStrategy,
Key
"Approvers" Key -> [ApproverProperty] -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= [ApproverProperty]
approvers, Key
"Description" 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
description,
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, Key
"Policies" Key -> [PolicyProperty] -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= [PolicyProperty]
policies]
([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes [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]))}
instance JSON.ToJSON ApprovalTeam where
toJSON :: ApprovalTeam -> Value
toJSON ApprovalTeam {[ApproverProperty]
[PolicyProperty]
Maybe [Tag]
()
Value Text
ApprovalStrategyProperty
haddock_workaround_ :: ApprovalTeam -> ()
approvalStrategy :: ApprovalTeam -> ApprovalStrategyProperty
approvers :: ApprovalTeam -> [ApproverProperty]
description :: ApprovalTeam -> Value Text
name :: ApprovalTeam -> Value Text
policies :: ApprovalTeam -> [PolicyProperty]
tags :: ApprovalTeam -> Maybe [Tag]
haddock_workaround_ :: ()
approvalStrategy :: ApprovalStrategyProperty
approvers :: [ApproverProperty]
description :: Value Text
name :: Value Text
policies :: [PolicyProperty]
tags :: Maybe [Tag]
..}
= [(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
"ApprovalStrategy" Key -> ApprovalStrategyProperty -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= ApprovalStrategyProperty
approvalStrategy,
Key
"Approvers" Key -> [ApproverProperty] -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= [ApproverProperty]
approvers, Key
"Description" 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
description,
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, Key
"Policies" Key -> [PolicyProperty] -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= [PolicyProperty]
policies]
([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes [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])))
instance Property "ApprovalStrategy" ApprovalTeam where
type PropertyType "ApprovalStrategy" ApprovalTeam = ApprovalStrategyProperty
set :: PropertyType "ApprovalStrategy" ApprovalTeam
-> ApprovalTeam -> ApprovalTeam
set PropertyType "ApprovalStrategy" ApprovalTeam
newValue ApprovalTeam {[ApproverProperty]
[PolicyProperty]
Maybe [Tag]
()
Value Text
ApprovalStrategyProperty
haddock_workaround_ :: ApprovalTeam -> ()
approvalStrategy :: ApprovalTeam -> ApprovalStrategyProperty
approvers :: ApprovalTeam -> [ApproverProperty]
description :: ApprovalTeam -> Value Text
name :: ApprovalTeam -> Value Text
policies :: ApprovalTeam -> [PolicyProperty]
tags :: ApprovalTeam -> Maybe [Tag]
haddock_workaround_ :: ()
approvalStrategy :: ApprovalStrategyProperty
approvers :: [ApproverProperty]
description :: Value Text
name :: Value Text
policies :: [PolicyProperty]
tags :: Maybe [Tag]
..}
= ApprovalTeam {approvalStrategy :: ApprovalStrategyProperty
approvalStrategy = PropertyType "ApprovalStrategy" ApprovalTeam
ApprovalStrategyProperty
newValue, [ApproverProperty]
[PolicyProperty]
Maybe [Tag]
()
Value Text
haddock_workaround_ :: ()
approvers :: [ApproverProperty]
description :: Value Text
name :: Value Text
policies :: [PolicyProperty]
tags :: Maybe [Tag]
haddock_workaround_ :: ()
approvers :: [ApproverProperty]
description :: Value Text
name :: Value Text
policies :: [PolicyProperty]
tags :: Maybe [Tag]
..}
instance Property "Approvers" ApprovalTeam where
type PropertyType "Approvers" ApprovalTeam = [ApproverProperty]
set :: PropertyType "Approvers" ApprovalTeam
-> ApprovalTeam -> ApprovalTeam
set PropertyType "Approvers" ApprovalTeam
newValue ApprovalTeam {[ApproverProperty]
[PolicyProperty]
Maybe [Tag]
()
Value Text
ApprovalStrategyProperty
haddock_workaround_ :: ApprovalTeam -> ()
approvalStrategy :: ApprovalTeam -> ApprovalStrategyProperty
approvers :: ApprovalTeam -> [ApproverProperty]
description :: ApprovalTeam -> Value Text
name :: ApprovalTeam -> Value Text
policies :: ApprovalTeam -> [PolicyProperty]
tags :: ApprovalTeam -> Maybe [Tag]
haddock_workaround_ :: ()
approvalStrategy :: ApprovalStrategyProperty
approvers :: [ApproverProperty]
description :: Value Text
name :: Value Text
policies :: [PolicyProperty]
tags :: Maybe [Tag]
..}
= ApprovalTeam {approvers :: [ApproverProperty]
approvers = [ApproverProperty]
PropertyType "Approvers" ApprovalTeam
newValue, [PolicyProperty]
Maybe [Tag]
()
Value Text
ApprovalStrategyProperty
haddock_workaround_ :: ()
approvalStrategy :: ApprovalStrategyProperty
description :: Value Text
name :: Value Text
policies :: [PolicyProperty]
tags :: Maybe [Tag]
haddock_workaround_ :: ()
approvalStrategy :: ApprovalStrategyProperty
description :: Value Text
name :: Value Text
policies :: [PolicyProperty]
tags :: Maybe [Tag]
..}
instance Property "Description" ApprovalTeam where
type PropertyType "Description" ApprovalTeam = Value Prelude.Text
set :: PropertyType "Description" ApprovalTeam
-> ApprovalTeam -> ApprovalTeam
set PropertyType "Description" ApprovalTeam
newValue ApprovalTeam {[ApproverProperty]
[PolicyProperty]
Maybe [Tag]
()
Value Text
ApprovalStrategyProperty
haddock_workaround_ :: ApprovalTeam -> ()
approvalStrategy :: ApprovalTeam -> ApprovalStrategyProperty
approvers :: ApprovalTeam -> [ApproverProperty]
description :: ApprovalTeam -> Value Text
name :: ApprovalTeam -> Value Text
policies :: ApprovalTeam -> [PolicyProperty]
tags :: ApprovalTeam -> Maybe [Tag]
haddock_workaround_ :: ()
approvalStrategy :: ApprovalStrategyProperty
approvers :: [ApproverProperty]
description :: Value Text
name :: Value Text
policies :: [PolicyProperty]
tags :: Maybe [Tag]
..}
= ApprovalTeam {description :: Value Text
description = PropertyType "Description" ApprovalTeam
Value Text
newValue, [ApproverProperty]
[PolicyProperty]
Maybe [Tag]
()
Value Text
ApprovalStrategyProperty
haddock_workaround_ :: ()
approvalStrategy :: ApprovalStrategyProperty
approvers :: [ApproverProperty]
name :: Value Text
policies :: [PolicyProperty]
tags :: Maybe [Tag]
haddock_workaround_ :: ()
approvalStrategy :: ApprovalStrategyProperty
approvers :: [ApproverProperty]
name :: Value Text
policies :: [PolicyProperty]
tags :: Maybe [Tag]
..}
instance Property "Name" ApprovalTeam where
type PropertyType "Name" ApprovalTeam = Value Prelude.Text
set :: PropertyType "Name" ApprovalTeam -> ApprovalTeam -> ApprovalTeam
set PropertyType "Name" ApprovalTeam
newValue ApprovalTeam {[ApproverProperty]
[PolicyProperty]
Maybe [Tag]
()
Value Text
ApprovalStrategyProperty
haddock_workaround_ :: ApprovalTeam -> ()
approvalStrategy :: ApprovalTeam -> ApprovalStrategyProperty
approvers :: ApprovalTeam -> [ApproverProperty]
description :: ApprovalTeam -> Value Text
name :: ApprovalTeam -> Value Text
policies :: ApprovalTeam -> [PolicyProperty]
tags :: ApprovalTeam -> Maybe [Tag]
haddock_workaround_ :: ()
approvalStrategy :: ApprovalStrategyProperty
approvers :: [ApproverProperty]
description :: Value Text
name :: Value Text
policies :: [PolicyProperty]
tags :: Maybe [Tag]
..} = ApprovalTeam {name :: Value Text
name = PropertyType "Name" ApprovalTeam
Value Text
newValue, [ApproverProperty]
[PolicyProperty]
Maybe [Tag]
()
Value Text
ApprovalStrategyProperty
haddock_workaround_ :: ()
approvalStrategy :: ApprovalStrategyProperty
approvers :: [ApproverProperty]
description :: Value Text
policies :: [PolicyProperty]
tags :: Maybe [Tag]
haddock_workaround_ :: ()
approvalStrategy :: ApprovalStrategyProperty
approvers :: [ApproverProperty]
description :: Value Text
policies :: [PolicyProperty]
tags :: Maybe [Tag]
..}
instance Property "Policies" ApprovalTeam where
type PropertyType "Policies" ApprovalTeam = [PolicyProperty]
set :: PropertyType "Policies" ApprovalTeam
-> ApprovalTeam -> ApprovalTeam
set PropertyType "Policies" ApprovalTeam
newValue ApprovalTeam {[ApproverProperty]
[PolicyProperty]
Maybe [Tag]
()
Value Text
ApprovalStrategyProperty
haddock_workaround_ :: ApprovalTeam -> ()
approvalStrategy :: ApprovalTeam -> ApprovalStrategyProperty
approvers :: ApprovalTeam -> [ApproverProperty]
description :: ApprovalTeam -> Value Text
name :: ApprovalTeam -> Value Text
policies :: ApprovalTeam -> [PolicyProperty]
tags :: ApprovalTeam -> Maybe [Tag]
haddock_workaround_ :: ()
approvalStrategy :: ApprovalStrategyProperty
approvers :: [ApproverProperty]
description :: Value Text
name :: Value Text
policies :: [PolicyProperty]
tags :: Maybe [Tag]
..}
= ApprovalTeam {policies :: [PolicyProperty]
policies = [PolicyProperty]
PropertyType "Policies" ApprovalTeam
newValue, [ApproverProperty]
Maybe [Tag]
()
Value Text
ApprovalStrategyProperty
haddock_workaround_ :: ()
approvalStrategy :: ApprovalStrategyProperty
approvers :: [ApproverProperty]
description :: Value Text
name :: Value Text
tags :: Maybe [Tag]
haddock_workaround_ :: ()
approvalStrategy :: ApprovalStrategyProperty
approvers :: [ApproverProperty]
description :: Value Text
name :: Value Text
tags :: Maybe [Tag]
..}
instance Property "Tags" ApprovalTeam where
type PropertyType "Tags" ApprovalTeam = [Tag]
set :: PropertyType "Tags" ApprovalTeam -> ApprovalTeam -> ApprovalTeam
set PropertyType "Tags" ApprovalTeam
newValue ApprovalTeam {[ApproverProperty]
[PolicyProperty]
Maybe [Tag]
()
Value Text
ApprovalStrategyProperty
haddock_workaround_ :: ApprovalTeam -> ()
approvalStrategy :: ApprovalTeam -> ApprovalStrategyProperty
approvers :: ApprovalTeam -> [ApproverProperty]
description :: ApprovalTeam -> Value Text
name :: ApprovalTeam -> Value Text
policies :: ApprovalTeam -> [PolicyProperty]
tags :: ApprovalTeam -> Maybe [Tag]
haddock_workaround_ :: ()
approvalStrategy :: ApprovalStrategyProperty
approvers :: [ApproverProperty]
description :: Value Text
name :: Value Text
policies :: [PolicyProperty]
tags :: Maybe [Tag]
..}
= ApprovalTeam {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" ApprovalTeam
newValue, [ApproverProperty]
[PolicyProperty]
()
Value Text
ApprovalStrategyProperty
haddock_workaround_ :: ()
approvalStrategy :: ApprovalStrategyProperty
approvers :: [ApproverProperty]
description :: Value Text
name :: Value Text
policies :: [PolicyProperty]
haddock_workaround_ :: ()
approvalStrategy :: ApprovalStrategyProperty
approvers :: [ApproverProperty]
description :: Value Text
name :: Value Text
policies :: [PolicyProperty]
..}