Class CfnTrafficMirrorFilterRule
java.lang.Object
software.amazon.jsii.JsiiObject
software.constructs.Construct
software.amazon.awscdk.CfnElement
software.amazon.awscdk.CfnRefElement
software.amazon.awscdk.CfnResource
software.amazon.awscdk.services.ec2.CfnTrafficMirrorFilterRule
- All Implemented Interfaces:
IInspectable
,ITaggableV2
,software.amazon.jsii.JsiiSerializable
,software.constructs.IConstruct
,software.constructs.IDependable
@Generated(value="jsii-pacmak/1.110.0 (build 336b265)",
date="2025-04-17T00:47:03.053Z")
@Stability(Stable)
public class CfnTrafficMirrorFilterRule
extends CfnResource
implements IInspectable, ITaggableV2
Creates a Traffic Mirror filter rule.
A Traffic Mirror rule defines the Traffic Mirror source traffic to mirror.
You need the Traffic Mirror filter ID when you create the rule.
Example:
// The code below shows an example of how to instantiate this type. // The values are placeholders you should change. import software.amazon.awscdk.services.ec2.*; CfnTrafficMirrorFilterRule cfnTrafficMirrorFilterRule = CfnTrafficMirrorFilterRule.Builder.create(this, "MyCfnTrafficMirrorFilterRule") .destinationCidrBlock("destinationCidrBlock") .ruleAction("ruleAction") .ruleNumber(123) .sourceCidrBlock("sourceCidrBlock") .trafficDirection("trafficDirection") .trafficMirrorFilterId("trafficMirrorFilterId") // the properties below are optional .description("description") .destinationPortRange(TrafficMirrorPortRangeProperty.builder() .fromPort(123) .toPort(123) .build()) .protocol(123) .sourcePortRange(TrafficMirrorPortRangeProperty.builder() .fromPort(123) .toPort(123) .build()) .tags(List.of(CfnTag.builder() .key("key") .value("value") .build())) .build();
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final class
A fluent builder forCfnTrafficMirrorFilterRule
.static interface
Describes the Traffic Mirror port range.Nested classes/interfaces inherited from class software.amazon.jsii.JsiiObject
software.amazon.jsii.JsiiObject.InitializationMode
Nested classes/interfaces inherited from interface software.constructs.IConstruct
software.constructs.IConstruct.Jsii$Default
Nested classes/interfaces inherited from interface software.amazon.awscdk.IInspectable
IInspectable.Jsii$Default, IInspectable.Jsii$Proxy
Nested classes/interfaces inherited from interface software.amazon.awscdk.ITaggableV2
ITaggableV2.Jsii$Default, ITaggableV2.Jsii$Proxy
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final String
The CloudFormation resource type name for this resource class. -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotected
CfnTrafficMirrorFilterRule
(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) protected
CfnTrafficMirrorFilterRule
(software.amazon.jsii.JsiiObjectRef objRef) CfnTrafficMirrorFilterRule
(software.constructs.Construct scope, String id, CfnTrafficMirrorFilterRuleProps props) -
Method Summary
Modifier and TypeMethodDescriptionTag Manager which manages the tags for this resource.The description of the Traffic Mirror rule.The destination CIDR block to assign to the Traffic Mirror rule.The destination port range.The protocol, for example UDP, to assign to the Traffic Mirror rule.The action to take on the filtered traffic.The number of the Traffic Mirror rule.The source CIDR block to assign to the Traffic Mirror rule.The source port range.getTags()
Tags on Traffic Mirroring filter rules.The type of traffic.The ID of the filter that this rule is associated with.void
inspect
(TreeInspector inspector) Examines the CloudFormation resource and discloses attributes.renderProperties
(Map<String, Object> props) void
setDescription
(String value) The description of the Traffic Mirror rule.void
setDestinationCidrBlock
(String value) The destination CIDR block to assign to the Traffic Mirror rule.void
The destination port range.void
The destination port range.void
setProtocol
(Number value) The protocol, for example UDP, to assign to the Traffic Mirror rule.void
setRuleAction
(String value) The action to take on the filtered traffic.void
setRuleNumber
(Number value) The number of the Traffic Mirror rule.void
setSourceCidrBlock
(String value) The source CIDR block to assign to the Traffic Mirror rule.void
setSourcePortRange
(IResolvable value) The source port range.void
The source port range.void
Tags on Traffic Mirroring filter rules.void
setTrafficDirection
(String value) The type of traffic.void
setTrafficMirrorFilterId
(String value) The ID of the filter that this rule is associated with.Methods inherited from class software.amazon.awscdk.CfnResource
addDeletionOverride, addDependency, addDependsOn, addMetadata, addOverride, addPropertyDeletionOverride, addPropertyOverride, applyRemovalPolicy, applyRemovalPolicy, applyRemovalPolicy, getAtt, getAtt, getCfnOptions, getCfnResourceType, getMetadata, getUpdatedProperites, getUpdatedProperties, isCfnResource, obtainDependencies, obtainResourceDependencies, removeDependency, replaceDependency, shouldSynthesize, toString, validateProperties
Methods inherited from class software.amazon.awscdk.CfnRefElement
getRef
Methods inherited from class software.amazon.awscdk.CfnElement
getCreationStack, getLogicalId, getStack, isCfnElement, overrideLogicalId
Methods inherited from class software.constructs.Construct
getNode, isConstruct
Methods inherited from class software.amazon.jsii.JsiiObject
jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSet
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Field Details
-
CFN_RESOURCE_TYPE_NAME
The CloudFormation resource type name for this resource class.
-
-
Constructor Details
-
CfnTrafficMirrorFilterRule
protected CfnTrafficMirrorFilterRule(software.amazon.jsii.JsiiObjectRef objRef) -
CfnTrafficMirrorFilterRule
protected CfnTrafficMirrorFilterRule(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) -
CfnTrafficMirrorFilterRule
@Stability(Stable) public CfnTrafficMirrorFilterRule(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull CfnTrafficMirrorFilterRuleProps props) - Parameters:
scope
- Scope in which this resource is defined. This parameter is required.id
- Construct identifier for this resource (unique in its scope). This parameter is required.props
- Resource properties. This parameter is required.
-
-
Method Details
-
inspect
Examines the CloudFormation resource and discloses attributes.- Specified by:
inspect
in interfaceIInspectable
- Parameters:
inspector
- tree inspector to collect and process attributes. This parameter is required.
-
renderProperties
@Stability(Stable) @NotNull protected Map<String,Object> renderProperties(@NotNull Map<String, Object> props) - Overrides:
renderProperties
in classCfnResource
- Parameters:
props
- This parameter is required.
-
getAttrId
-
getCdkTagManager
Tag Manager which manages the tags for this resource.- Specified by:
getCdkTagManager
in interfaceITaggableV2
-
getCfnProperties
- Overrides:
getCfnProperties
in classCfnResource
-
getDestinationCidrBlock
The destination CIDR block to assign to the Traffic Mirror rule. -
setDestinationCidrBlock
The destination CIDR block to assign to the Traffic Mirror rule. -
getRuleAction
The action to take on the filtered traffic. -
setRuleAction
The action to take on the filtered traffic. -
getRuleNumber
The number of the Traffic Mirror rule. -
setRuleNumber
The number of the Traffic Mirror rule. -
getSourceCidrBlock
The source CIDR block to assign to the Traffic Mirror rule. -
setSourceCidrBlock
The source CIDR block to assign to the Traffic Mirror rule. -
getTrafficDirection
The type of traffic. -
setTrafficDirection
The type of traffic. -
getTrafficMirrorFilterId
The ID of the filter that this rule is associated with. -
setTrafficMirrorFilterId
The ID of the filter that this rule is associated with. -
getDescription
The description of the Traffic Mirror rule. -
setDescription
The description of the Traffic Mirror rule. -
getDestinationPortRange
The destination port range. -
setDestinationPortRange
The destination port range. -
setDestinationPortRange
@Stability(Stable) public void setDestinationPortRange(@Nullable CfnTrafficMirrorFilterRule.TrafficMirrorPortRangeProperty value) The destination port range. -
getProtocol
The protocol, for example UDP, to assign to the Traffic Mirror rule. -
setProtocol
The protocol, for example UDP, to assign to the Traffic Mirror rule. -
getSourcePortRange
The source port range. -
setSourcePortRange
The source port range. -
setSourcePortRange
@Stability(Stable) public void setSourcePortRange(@Nullable CfnTrafficMirrorFilterRule.TrafficMirrorPortRangeProperty value) The source port range. -
getTags
Tags on Traffic Mirroring filter rules. -
setTags
Tags on Traffic Mirroring filter rules.
-