Class RuleScope.Builder
java.lang.Object
software.amazon.awscdk.services.ec2.RuleScope.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<RuleScope>
- Enclosing interface:
RuleScope
@Stability(Stable)
public static final class RuleScope.Builder
extends Object
implements software.amazon.jsii.Builder<RuleScope>
A builder for
RuleScope
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionbuild()
Builds the configured instance.Sets the value ofRuleScope.getId()
scope
(ISecurityGroup scope) Sets the value ofRuleScope.getScope()
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
id
Sets the value ofRuleScope.getId()
- Parameters:
id
- The construct ID to use for the rule. This parameter is required.- Returns:
this
-
scope
Sets the value ofRuleScope.getScope()
- Parameters:
scope
- The SecurityGroup in which a rule should be scoped. This parameter is required.- Returns:
this
-
build
Builds the configured instance.- Specified by:
build
in interfacesoftware.amazon.jsii.Builder<RuleScope>
- Returns:
- a new instance of
RuleScope
- Throws:
NullPointerException
- if any required attribute was not provided
-