Skip to content
v2.278.0

PortRangeProperty Struct ​

TCP or UDP protocols: The range of ports the rule applies to.

Example ​

ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_fms as fms } from 'aws-cdk-lib';
const portRangeProperty: fms.CfnPolicy.PortRangeProperty = {
  from: 123,
  to: 123,
};
python
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_fms as fms

port_range_property = fms.CfnPolicy.PortRangeProperty(
    from=123,
    to=123
)
java
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.fms.*;

PortRangeProperty portRangeProperty = PortRangeProperty.builder()
        .from(123)
        .to(123)
        .build();
csharp
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.FMS;

var portRangeProperty = new PortRangeProperty {
    From = 123,
    To = 123
};
go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdk"

portRangeProperty := &PortRangeProperty{
	From: jsii.Number(123),
	To: jsii.Number(123),
}

Properties ​

fromnumberfromint | floatfromNumberFromdoubleFrom*float64 required #
The beginning port number of the range.
tonumbertoint | floattoNumberTodoubleTo*float64 required #
The ending port number of the range.