RuleScope
- class aws_cdk.aws_ec2.RuleScope(*, id, scope)
- Bases: - object- The scope and id in which a given SecurityGroup rule should be defined. - Parameters:
- id ( - str) – The construct ID to use for the rule.
- scope ( - ISecurityGroup) – The SecurityGroup in which a rule should be scoped.
 
- ExampleMetadata:
- fixture=_generated 
 - Example: - # The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk import aws_ec2 as ec2 # security_group: ec2.SecurityGroup rule_scope = ec2.RuleScope( id="id", scope=security_group ) - Attributes - id
- The construct ID to use for the rule. 
 - scope
- The SecurityGroup in which a rule should be scoped.