Class: AWSCDK::ResourceGroups::CfnGroupProps
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::ResourceGroups::CfnGroupProps
- Defined in:
- resource_groups/cfn_group_props.rb
Overview
Properties for defining a CfnGroup.
Instance Attribute Summary collapse
-
#configuration ⇒ AWSCDK::IResolvable, ...
readonly
The service configuration currently associated with the resource group and in effect for the members of the resource group.
-
#description ⇒ String?
readonly
The description of the resource group.
-
#name ⇒ String
readonly
The name of a resource group.
-
#resource_query ⇒ AWSCDK::IResolvable, ...
readonly
The resource query structure that is used to dynamically determine which AWS resources are members of the associated resource group.
-
#resources ⇒ Array<String>?
readonly
A list of the Amazon Resource Names (ARNs) of AWS resources that you want to add to the specified group.
-
#tags ⇒ Array<AWSCDK::CfnTag>?
readonly
The tag key and value pairs that are attached to the resource group.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(name:, configuration: nil, description: nil, resource_query: nil, resources: nil, tags: nil) ⇒ CfnGroupProps
constructor
A new instance of CfnGroupProps.
- #to_jsii ⇒ Object
Constructor Details
#initialize(name:, configuration: nil, description: nil, resource_query: nil, resources: nil, tags: nil) ⇒ CfnGroupProps
Returns a new instance of CfnGroupProps.
15 16 17 18 19 20 21 22 23 24 25 26 27 28 |
# File 'resource_groups/cfn_group_props.rb', line 15 def initialize(name:, configuration: nil, description: nil, resource_query: nil, resources: nil, tags: nil) @name = name Jsii::Type.check_type(@name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "name") @configuration = configuration Jsii::Type.check_type(@configuration, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImNvbGxlY3Rpb24iOnsiZWxlbWVudHR5cGUiOnsidW5pb24iOnsidHlwZXMiOlt7ImZxbiI6ImF3cy1jZGstbGliLklSZXNvbHZhYmxlIn0seyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfcmVzb3VyY2Vncm91cHMuQ2ZuR3JvdXAuQ29uZmlndXJhdGlvbkl0ZW1Qcm9wZXJ0eSJ9XX19LCJraW5kIjoiYXJyYXkifX1dfX0=")), "configuration") unless @configuration.nil? @description = description Jsii::Type.check_type(@description, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "description") unless @description.nil? @resource_query = resource_query.is_a?(Hash) ? ::AWSCDK::ResourceGroups::CfnGroup::ResourceQueryProperty.new(**resource_query.transform_keys(&:to_sym)) : resource_query Jsii::Type.check_type(@resource_query, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c19yZXNvdXJjZWdyb3Vwcy5DZm5Hcm91cC5SZXNvdXJjZVF1ZXJ5UHJvcGVydHkifV19fQ==")), "resourceQuery") unless @resource_query.nil? @resources = resources Jsii::Type.check_type(@resources, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7InByaW1pdGl2ZSI6InN0cmluZyJ9LCJraW5kIjoiYXJyYXkifX0=")), "resources") unless @resources.nil? @tags = .is_a?(Array) ? .map { |jsii_v0| jsii_v0.is_a?(Hash) ? ::AWSCDK::CfnTag.new(**jsii_v0.transform_keys(&:to_sym)) : jsii_v0 } : Jsii::Type.check_type(@tags, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7ImZxbiI6ImF3cy1jZGstbGliLkNmblRhZyJ9LCJraW5kIjoiYXJyYXkifX0=")), "tags") unless @tags.nil? end |
Instance Attribute Details
#configuration ⇒ AWSCDK::IResolvable, ... (readonly)
The service configuration currently associated with the resource group and in effect for the members of the resource group.
A Configuration consists of one or more ConfigurationItem entries. For information about service configurations for resource groups and how to construct them, see Service configurations for resource groups in the Resource Groups User Guide .
You can include either a
Configurationor aResourceQuery, but not both.
45 46 47 |
# File 'resource_groups/cfn_group_props.rb', line 45 def configuration @configuration end |
#description ⇒ String? (readonly)
The description of the resource group.
50 51 52 |
# File 'resource_groups/cfn_group_props.rb', line 50 def description @description end |
#name ⇒ String (readonly)
The name of a resource group.
The name must be unique within the AWS Region in which you create the resource. To create multiple resource groups based on the same CloudFormation stack, you must generate unique names for each.
36 37 38 |
# File 'resource_groups/cfn_group_props.rb', line 36 def name @name end |
#resource_query ⇒ AWSCDK::IResolvable, ... (readonly)
The resource query structure that is used to dynamically determine which AWS resources are members of the associated resource group.
For more information about queries and how to construct them, see Build queries and groups in Resource Groups in the Resource Groups User Guide
- You can include either a
ResourceQueryor aConfiguration, but not both.- You can specify the group's membership either by using a
ResourceQueryor by using a list ofResources, but not both.
60 61 62 |
# File 'resource_groups/cfn_group_props.rb', line 60 def resource_query @resource_query end |
#resources ⇒ Array<String>? (readonly)
A list of the Amazon Resource Names (ARNs) of AWS resources that you want to add to the specified group.
- You can specify the group membership either by using a list of
Resourcesor by using aResourceQuery, but not both.- You can include a
Resourcesproperty only if you also specify aConfigurationproperty.
68 69 70 |
# File 'resource_groups/cfn_group_props.rb', line 68 def resources @resources end |
#tags ⇒ Array<AWSCDK::CfnTag>? (readonly)
The tag key and value pairs that are attached to the resource group.
73 74 75 |
# File 'resource_groups/cfn_group_props.rb', line 73 def @tags end |
Class Method Details
.jsii_properties ⇒ Object
75 76 77 78 79 80 81 82 83 84 |
# File 'resource_groups/cfn_group_props.rb', line 75 def self.jsii_properties { :name => "name", :configuration => "configuration", :description => "description", :resource_query => "resourceQuery", :resources => "resources", :tags => "tags", } end |
Instance Method Details
#to_jsii ⇒ Object
86 87 88 89 90 91 92 93 94 95 96 97 |
# File 'resource_groups/cfn_group_props.rb', line 86 def to_jsii result = {} result.merge!({ "name" => @name, "configuration" => @configuration, "description" => @description, "resourceQuery" => @resource_query, "resources" => @resources, "tags" => @tags, }) result.compact end |