EIPSegment
- Implements: IEIPSegment
This class encapsulates and extends the ROS resource type ALIYUN::VPC::EIPSegment, which is used to apply for contiguous elastic IP addresses (EIPs).
Initializers
import com.aliyun.ros.cdk.vpc.EIPSegment;
EIPSegment.Builder.create(Construct scope, java.lang.String id, java.lang.Boolean enableResourcePropertyConstraint)
.eipMask(java.lang.Number)
.eipMask(IResolvable)
// .bandwidth(java.lang.Number)
// .bandwidth(IResolvable)
// .internetChargeType(java.lang.String)
// .internetChargeType(IResolvable)
// .isp(java.lang.String)
// .isp(IResolvable)
// .netmode(java.lang.String)
// .netmode(IResolvable)
// .resourceGroupId(java.lang.String)
// .resourceGroupId(IResolvable)
// .zone(java.lang.String)
// .zone(IResolvable)
.build();
| Name | Type | Description |
|---|---|---|
scope | com.aliyun.ros.cdk.core.Construct | No description. |
id | java.lang.String | No description. |
enableResourcePropertyConstraint | java.lang.Boolean | No description. |
eipMask | java.lang.Number OR com.aliyun.ros.cdk.core.IResolvable | Property eipMask: The mask of the contiguous EIP group. |
bandwidth | java.lang.Number OR com.aliyun.ros.cdk.core.IResolvable | Property bandwidth: The maximum bandwidth of the contiguous EIPs. |
internetChargeType | java.lang.String OR com.aliyun.ros.cdk.core.IResolvable | Property internetChargeType: The metering method of the contiguous EIPs. |
isp | java.lang.String OR com.aliyun.ros.cdk.core.IResolvable | Property isp: The line type. |
netmode | java.lang.String OR com.aliyun.ros.cdk.core.IResolvable | Property netmode: The network type. |
resourceGroupId | java.lang.String OR com.aliyun.ros.cdk.core.IResolvable | Property resourceGroupId: The ID of the resource group to which the EIPs belong. |
zone | java.lang.String OR com.aliyun.ros.cdk.core.IResolvable | Property zone: The zone of the contiguous EIP group. |
scopeRequired
- Type: com.aliyun.ros.cdk.core.Construct
idRequired
- Type: java.lang.String
enableResourcePropertyConstraintOptional
- Type: java.lang.Boolean
eipMaskRequired
- Type: java.lang.Number OR com.aliyun.ros.cdk.core.IResolvable
Property eipMask: The mask of the contiguous EIP group.
Valid values: 28: 16 contiguous EIPs are allocated for one call. 27: 32 contiguous EIPs are allocated for one call. 26: 64 contiguous EIPs are allocated for one call. 25: 128 contiguous EIPs are allocated for one call. 24: 256 contiguous EIPs are allocated for one call. Note The actual number of assigned EIPs may be less than the expected number because one, three, or four EIPs may be reserved.
bandwidthOptional
- Type: java.lang.Number OR com.aliyun.ros.cdk.core.IResolvable
Property bandwidth: The maximum bandwidth of the contiguous EIPs.
Unit: Mbit/s. Default value: 5.
internetChargeTypeOptional
- Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable
Property internetChargeType: The metering method of the contiguous EIPs.
Valid values: PayByBandwidth: Fees are charged based on bandwidth usage. This is the default value. PayByTraffic: Fees are charged based on data transfer. Note If the Netmode parameter is set to hybrid, InternetChargeType is set to PayByBandwidth.
ispOptional
- Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable
Property isp: The line type.
Valid values:
- BGP (default): BGP (multi-line). All regions support BGP (multi-line) EIPs.
- BGP_PRO: BGP (multi-line)_Premium. Currently supported only in China (Hong Kong), Singapore, Japan (Tokyo), Malaysia (Kuala Lumpur), Philippines (Manila), India (Jakarta), and Thailand (Bangkok). If you are a single-bandwidth whitelist user, you can also choose:
- ChinaTelecom: China Telecom
- ChinaUnicom: China Unicom
- ChinaMobile: China Mobile
- ChinaTelecom_L2: China Telecom L2
- ChinaUnicom_L2: China Unicom L2
- ChinaMobile_L2: China Mobile L2
If you are a Hangzhou Finance Cloud user, this field is required with value: BGP_FinanceCloud.
netmodeOptional
- Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable
Property netmode: The network type.
Valid values: public: the Internet. This is the default value. After contiguous EIPs are associated with cloud resources, the cloud resources can access the Internet by using the EIPs. hybrid: the hybrid cloud. After contiguous EIPs are associated with cloud resources, the cloud resources can access the hybrid cloud by using the EIPs. Note This network type is available only to users who are added to the whitelist. To use this network type, contact your customer manager.
resourceGroupIdOptional
- Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable
Property resourceGroupId: The ID of the resource group to which the EIPs belong.
zoneOptional
- Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable
Property zone: The zone of the contiguous EIP group.
Methods
| Name | Description |
|---|---|
toString | Returns a string representation of this construct. |
synthesize | Allows this construct to emit artifacts into the cloud assembly during synthesis. |
addCondition | No description. |
addCount | No description. |
addDependency | No description. |
addResourceDesc | No description. |
applyRemovalPolicy | No description. |
fetchCondition | No description. |
fetchDependency | No description. |
fetchResourceDesc | No description. |
getAtt | No description. |
setMetadata | No description. |
toString
public java.lang.String toString()
Returns a string representation of this construct.
synthesize
public void synthesize(ISynthesisSession session)
Allows this construct to emit artifacts into the cloud assembly during synthesis.
This method is usually implemented by framework-level constructs such as Stack and Asset as they participate in synthesizing the cloud assembly.
- Type: com.aliyun.ros.cdk.core.ISynthesisSession
The synthesis session.
addCondition
public void addCondition(RosCondition condition)
- Type: com.aliyun.ros.cdk.core.RosCondition
addCount
public void addCount(java.lang.Number OR IResolvable count)
- Type: java.lang.Number OR com.aliyun.ros.cdk.core.IResolvable
addDependency
public void addDependency(Resource resource)
- Type: com.aliyun.ros.cdk.core.Resource
addResourceDesc
public void addResourceDesc(java.lang.String desc)
- Type: java.lang.String
applyRemovalPolicy
public void applyRemovalPolicy(RemovalPolicy policy)
- Type: com.aliyun.ros.cdk.core.RemovalPolicy
fetchCondition
public RosCondition fetchCondition()
fetchDependency
public java.util.List<java.lang.String> fetchDependency()
fetchResourceDesc
public java.lang.String fetchResourceDesc()
getAtt
public IResolvable getAtt(java.lang.String name)
- Type: java.lang.String
setMetadata
public void setMetadata(java.lang.String key, java.lang.Object value)
- Type: java.lang.String
- Type: java.lang.Object
Static Functions
| Name | Description |
|---|---|
isConstruct | Return whether the given object is a Construct. |
isConstruct
import com.aliyun.ros.cdk.vpc.EIPSegment;
EIPSegment.isConstruct(java.lang.Object x)
Return whether the given object is a Construct.
- Type: java.lang.Object
Properties
| Name | Type | Description |
|---|---|---|
node | com.aliyun.ros.cdk.core.ConstructNode | The construct tree node associated with this construct. |
env | com.aliyun.ros.cdk.core.IResourceEnvironment | The environment this resource belongs to. |
ref | java.lang.String | No description. |
stack | com.aliyun.ros.cdk.core.Stack | The stack in which this resource is defined. |
resource | com.aliyun.ros.cdk.core.RosResource | No description. |
attrEipAddresses | java.lang.String OR com.aliyun.ros.cdk.core.IResolvable | Attribute EipAddresses: List of EIP addresses. |
attrEipSegmentInstanceId | java.lang.String OR com.aliyun.ros.cdk.core.IResolvable | Attribute EipSegmentInstanceId: The ID of the contiguous EIP group. |
props | EIPSegmentProps | No description. |
nodeRequired
public ConstructNode getNode();
- Type: com.aliyun.ros.cdk.core.ConstructNode
The construct tree node associated with this construct.
envRequired
public IResourceEnvironment getEnv();
- Type: com.aliyun.ros.cdk.core.IResourceEnvironment
The environment this resource belongs to.
For resources that are created and managed by the CDK (generally, those created by creating new class instances like Role, Bucket, etc.), this is always the same as the environment of the stack they belong to; however, for imported resources (those obtained from static methods like fromRoleArn, fromBucketName, etc.), that might be different than the stack they were imported into.
refRequired
public java.lang.String getRef();
- Type: java.lang.String
stackRequired
public Stack getStack();
- Type: com.aliyun.ros.cdk.core.Stack
The stack in which this resource is defined.
resourceOptional
public RosResource getResource();
- Type: com.aliyun.ros.cdk.core.RosResource
attrEipAddressesRequired
public java.lang.Object getAttrEipAddresses();
- Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable
Attribute EipAddresses: List of EIP addresses.
like [{"AllocationId": "eip-xxx", "IpAddress": "xx.xx.xx.xx"}]
attrEipSegmentInstanceIdRequired
public java.lang.Object getAttrEipSegmentInstanceId();
- Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable
Attribute EipSegmentInstanceId: The ID of the contiguous EIP group.
propsRequired
public EIPSegmentProps getProps();
- Type: EIPSegmentProps