Class CfnGroupProps.Builder
java.lang.Object
software.amazon.awscdk.services.resourcegroups.CfnGroupProps.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<CfnGroupProps>
- Enclosing interface:
CfnGroupProps
@Stability(Stable)
public static final class CfnGroupProps.Builder
extends Object
implements software.amazon.jsii.Builder<CfnGroupProps>
A builder for
CfnGroupProps
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionbuild()
Builds the configured instance.configuration
(List<? extends Object> configuration) Sets the value ofCfnGroupProps.getConfiguration()
configuration
(IResolvable configuration) Sets the value ofCfnGroupProps.getConfiguration()
description
(String description) Sets the value ofCfnGroupProps.getDescription()
Sets the value ofCfnGroupProps.getName()
resourceQuery
(IResolvable resourceQuery) Sets the value ofCfnGroupProps.getResourceQuery()
resourceQuery
(CfnGroup.ResourceQueryProperty resourceQuery) Sets the value ofCfnGroupProps.getResourceQuery()
Sets the value ofCfnGroupProps.getResources()
Sets the value ofCfnGroupProps.getTags()
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
name
Sets the value ofCfnGroupProps.getName()
- Parameters:
name
- The name of a resource group. This parameter is required. 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.- Returns:
this
-
configuration
Sets the value ofCfnGroupProps.getConfiguration()
- Parameters:
configuration
- The service configuration currently associated with the resource group and in effect for the members of the resource group. AConfiguration
consists of one or moreConfigurationItem
entries. For information about service configurations for resource groups and how to construct them, see Service configurations for resource groups in the AWS Resource Groups User Guide .You can include either a
Configuration
or aResourceQuery
, but not both.- Returns:
this
-
configuration
Sets the value ofCfnGroupProps.getConfiguration()
- Parameters:
configuration
- The service configuration currently associated with the resource group and in effect for the members of the resource group. AConfiguration
consists of one or moreConfigurationItem
entries. For information about service configurations for resource groups and how to construct them, see Service configurations for resource groups in the AWS Resource Groups User Guide .You can include either a
Configuration
or aResourceQuery
, but not both.- Returns:
this
-
description
Sets the value ofCfnGroupProps.getDescription()
- Parameters:
description
- The description of the resource group.- Returns:
this
-
resourceQuery
Sets the value ofCfnGroupProps.getResourceQuery()
- Parameters:
resourceQuery
- 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 AWS Resource Groups in the AWS Resource Groups User Guide- You can include either a
ResourceQuery
or aConfiguration
, but not both. - You can specify the group's membership either by using a
ResourceQuery
or by using a list ofResources
, but not both.
- You can include either a
- Returns:
this
-
resourceQuery
@Stability(Stable) public CfnGroupProps.Builder resourceQuery(CfnGroup.ResourceQueryProperty resourceQuery) Sets the value ofCfnGroupProps.getResourceQuery()
- Parameters:
resourceQuery
- 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 AWS Resource Groups in the AWS Resource Groups User Guide- You can include either a
ResourceQuery
or aConfiguration
, but not both. - You can specify the group's membership either by using a
ResourceQuery
or by using a list ofResources
, but not both.
- You can include either a
- Returns:
this
-
resources
Sets the value ofCfnGroupProps.getResources()
- Parameters:
resources
- 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
Resources
or by using aResourceQuery
, but not both. - You can include a
Resources
property only if you also specify aConfiguration
property.
- You can specify the group membership either by using a list of
- Returns:
this
-
tags
Sets the value ofCfnGroupProps.getTags()
- Parameters:
tags
- The tag key and value pairs that are attached to the resource group.- Returns:
this
-
build
Builds the configured instance.- Specified by:
build
in interfacesoftware.amazon.jsii.Builder<CfnGroupProps>
- Returns:
- a new instance of
CfnGroupProps
- Throws:
NullPointerException
- if any required attribute was not provided
-