module Stratosphere.Config.ConfigRule.ScopeProperty (
ScopeProperty(..), mkScopeProperty
) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data ScopeProperty
=
ScopeProperty {ScopeProperty -> ()
haddock_workaround_ :: (),
ScopeProperty -> Maybe (Value Text)
complianceResourceId :: (Prelude.Maybe (Value Prelude.Text)),
ScopeProperty -> Maybe (ValueList Text)
complianceResourceTypes :: (Prelude.Maybe (ValueList Prelude.Text)),
ScopeProperty -> Maybe (Value Text)
tagKey :: (Prelude.Maybe (Value Prelude.Text)),
ScopeProperty -> Maybe (Value Text)
tagValue :: (Prelude.Maybe (Value Prelude.Text))}
deriving stock (ScopeProperty -> ScopeProperty -> Bool
(ScopeProperty -> ScopeProperty -> Bool)
-> (ScopeProperty -> ScopeProperty -> Bool) -> Eq ScopeProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: ScopeProperty -> ScopeProperty -> Bool
== :: ScopeProperty -> ScopeProperty -> Bool
$c/= :: ScopeProperty -> ScopeProperty -> Bool
/= :: ScopeProperty -> ScopeProperty -> Bool
Prelude.Eq, Int -> ScopeProperty -> ShowS
[ScopeProperty] -> ShowS
ScopeProperty -> String
(Int -> ScopeProperty -> ShowS)
-> (ScopeProperty -> String)
-> ([ScopeProperty] -> ShowS)
-> Show ScopeProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> ScopeProperty -> ShowS
showsPrec :: Int -> ScopeProperty -> ShowS
$cshow :: ScopeProperty -> String
show :: ScopeProperty -> String
$cshowList :: [ScopeProperty] -> ShowS
showList :: [ScopeProperty] -> ShowS
Prelude.Show)
mkScopeProperty :: ScopeProperty
mkScopeProperty :: ScopeProperty
mkScopeProperty
= ScopeProperty
{haddock_workaround_ :: ()
haddock_workaround_ = (), complianceResourceId :: Maybe (Value Text)
complianceResourceId = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing,
complianceResourceTypes :: Maybe (ValueList Text)
complianceResourceTypes = Maybe (ValueList Text)
forall a. Maybe a
Prelude.Nothing,
tagKey :: Maybe (Value Text)
tagKey = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing, tagValue :: Maybe (Value Text)
tagValue = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties ScopeProperty where
toResourceProperties :: ScopeProperty -> ResourceProperties
toResourceProperties ScopeProperty {Maybe (ValueList Text)
Maybe (Value Text)
()
haddock_workaround_ :: ScopeProperty -> ()
complianceResourceId :: ScopeProperty -> Maybe (Value Text)
complianceResourceTypes :: ScopeProperty -> Maybe (ValueList Text)
tagKey :: ScopeProperty -> Maybe (Value Text)
tagValue :: ScopeProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
complianceResourceId :: Maybe (Value Text)
complianceResourceTypes :: Maybe (ValueList Text)
tagKey :: Maybe (Value Text)
tagValue :: Maybe (Value Text)
..}
= ResourceProperties
{awsType :: Text
awsType = Text
"AWS::Config::ConfigRule.Scope",
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 -> 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
"ComplianceResourceId" (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)
complianceResourceId,
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
"ComplianceResourceTypes"
(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)
complianceResourceTypes,
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
"TagKey" (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)
tagKey,
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
"TagValue" (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)
tagValue])}
instance JSON.ToJSON ScopeProperty where
toJSON :: ScopeProperty -> Value
toJSON ScopeProperty {Maybe (ValueList Text)
Maybe (Value Text)
()
haddock_workaround_ :: ScopeProperty -> ()
complianceResourceId :: ScopeProperty -> Maybe (Value Text)
complianceResourceTypes :: ScopeProperty -> Maybe (ValueList Text)
tagKey :: ScopeProperty -> Maybe (Value Text)
tagValue :: ScopeProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
complianceResourceId :: Maybe (Value Text)
complianceResourceTypes :: Maybe (ValueList Text)
tagKey :: Maybe (Value Text)
tagValue :: 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 -> 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
"ComplianceResourceId" (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)
complianceResourceId,
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
"ComplianceResourceTypes"
(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)
complianceResourceTypes,
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
"TagKey" (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)
tagKey,
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
"TagValue" (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)
tagValue]))
instance Property "ComplianceResourceId" ScopeProperty where
type PropertyType "ComplianceResourceId" ScopeProperty = Value Prelude.Text
set :: PropertyType "ComplianceResourceId" ScopeProperty
-> ScopeProperty -> ScopeProperty
set PropertyType "ComplianceResourceId" ScopeProperty
newValue ScopeProperty {Maybe (ValueList Text)
Maybe (Value Text)
()
haddock_workaround_ :: ScopeProperty -> ()
complianceResourceId :: ScopeProperty -> Maybe (Value Text)
complianceResourceTypes :: ScopeProperty -> Maybe (ValueList Text)
tagKey :: ScopeProperty -> Maybe (Value Text)
tagValue :: ScopeProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
complianceResourceId :: Maybe (Value Text)
complianceResourceTypes :: Maybe (ValueList Text)
tagKey :: Maybe (Value Text)
tagValue :: Maybe (Value Text)
..}
= ScopeProperty {complianceResourceId :: Maybe (Value Text)
complianceResourceId = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "ComplianceResourceId" ScopeProperty
Value Text
newValue, Maybe (ValueList Text)
Maybe (Value Text)
()
haddock_workaround_ :: ()
complianceResourceTypes :: Maybe (ValueList Text)
tagKey :: Maybe (Value Text)
tagValue :: Maybe (Value Text)
haddock_workaround_ :: ()
complianceResourceTypes :: Maybe (ValueList Text)
tagKey :: Maybe (Value Text)
tagValue :: Maybe (Value Text)
..}
instance Property "ComplianceResourceTypes" ScopeProperty where
type PropertyType "ComplianceResourceTypes" ScopeProperty = ValueList Prelude.Text
set :: PropertyType "ComplianceResourceTypes" ScopeProperty
-> ScopeProperty -> ScopeProperty
set PropertyType "ComplianceResourceTypes" ScopeProperty
newValue ScopeProperty {Maybe (ValueList Text)
Maybe (Value Text)
()
haddock_workaround_ :: ScopeProperty -> ()
complianceResourceId :: ScopeProperty -> Maybe (Value Text)
complianceResourceTypes :: ScopeProperty -> Maybe (ValueList Text)
tagKey :: ScopeProperty -> Maybe (Value Text)
tagValue :: ScopeProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
complianceResourceId :: Maybe (Value Text)
complianceResourceTypes :: Maybe (ValueList Text)
tagKey :: Maybe (Value Text)
tagValue :: Maybe (Value Text)
..}
= ScopeProperty
{complianceResourceTypes :: Maybe (ValueList Text)
complianceResourceTypes = ValueList Text -> Maybe (ValueList Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "ComplianceResourceTypes" ScopeProperty
ValueList Text
newValue, Maybe (Value Text)
()
haddock_workaround_ :: ()
complianceResourceId :: Maybe (Value Text)
tagKey :: Maybe (Value Text)
tagValue :: Maybe (Value Text)
haddock_workaround_ :: ()
complianceResourceId :: Maybe (Value Text)
tagKey :: Maybe (Value Text)
tagValue :: Maybe (Value Text)
..}
instance Property "TagKey" ScopeProperty where
type PropertyType "TagKey" ScopeProperty = Value Prelude.Text
set :: PropertyType "TagKey" ScopeProperty
-> ScopeProperty -> ScopeProperty
set PropertyType "TagKey" ScopeProperty
newValue ScopeProperty {Maybe (ValueList Text)
Maybe (Value Text)
()
haddock_workaround_ :: ScopeProperty -> ()
complianceResourceId :: ScopeProperty -> Maybe (Value Text)
complianceResourceTypes :: ScopeProperty -> Maybe (ValueList Text)
tagKey :: ScopeProperty -> Maybe (Value Text)
tagValue :: ScopeProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
complianceResourceId :: Maybe (Value Text)
complianceResourceTypes :: Maybe (ValueList Text)
tagKey :: Maybe (Value Text)
tagValue :: Maybe (Value Text)
..}
= ScopeProperty {tagKey :: Maybe (Value Text)
tagKey = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "TagKey" ScopeProperty
Value Text
newValue, Maybe (ValueList Text)
Maybe (Value Text)
()
haddock_workaround_ :: ()
complianceResourceId :: Maybe (Value Text)
complianceResourceTypes :: Maybe (ValueList Text)
tagValue :: Maybe (Value Text)
haddock_workaround_ :: ()
complianceResourceId :: Maybe (Value Text)
complianceResourceTypes :: Maybe (ValueList Text)
tagValue :: Maybe (Value Text)
..}
instance Property "TagValue" ScopeProperty where
type PropertyType "TagValue" ScopeProperty = Value Prelude.Text
set :: PropertyType "TagValue" ScopeProperty
-> ScopeProperty -> ScopeProperty
set PropertyType "TagValue" ScopeProperty
newValue ScopeProperty {Maybe (ValueList Text)
Maybe (Value Text)
()
haddock_workaround_ :: ScopeProperty -> ()
complianceResourceId :: ScopeProperty -> Maybe (Value Text)
complianceResourceTypes :: ScopeProperty -> Maybe (ValueList Text)
tagKey :: ScopeProperty -> Maybe (Value Text)
tagValue :: ScopeProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
complianceResourceId :: Maybe (Value Text)
complianceResourceTypes :: Maybe (ValueList Text)
tagKey :: Maybe (Value Text)
tagValue :: Maybe (Value Text)
..}
= ScopeProperty {tagValue :: Maybe (Value Text)
tagValue = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "TagValue" ScopeProperty
Value Text
newValue, Maybe (ValueList Text)
Maybe (Value Text)
()
haddock_workaround_ :: ()
complianceResourceId :: Maybe (Value Text)
complianceResourceTypes :: Maybe (ValueList Text)
tagKey :: Maybe (Value Text)
haddock_workaround_ :: ()
complianceResourceId :: Maybe (Value Text)
complianceResourceTypes :: Maybe (ValueList Text)
tagKey :: Maybe (Value Text)
..}