public class SubnetClient extends AbstractBceClient
config, DEFAULT_CONTENT_TYPE, DEFAULT_ENCODING, DEFAULT_SERVICE_DOMAIN, URL_PREFIX| Constructor and Description |
|---|
SubnetClient()
Constructs a new client to invoke service methods on network.
|
SubnetClient(BceClientConfiguration clientConfiguration)
Constructs a new network client using the client configuration to access network.
|
| Modifier and Type | Method and Description |
|---|---|
CreateSubnetResponse |
createSubnet(CreateSubnetRequest request)
Create a subnet with the specified options.
|
CreateSubnetResponse |
createSubnet(String name,
String vpcId,
String cidr,
String zoneName) |
void |
deleteSubnet(DeleteSubnetRequest deleteSubnetRequest)
Delete the specified subnet owned by the user.
|
void |
deleteSubnet(String subnetId)
Delete the specified subnet owned by the user.
|
GetSubnetResponse |
getSubnet(GetSubnetRequest getSubnetRequest)
Get the detail information of specified subnet.
|
GetSubnetResponse |
getSubnet(String subnetId)
Deprecated.
|
GetSubnetDetailResponse |
getSubnetDetail(String subnetId)
Get the detail information of specified subnet.
|
ListSubnetsResponse |
listSubnets()
Return a list of subnets owned by the authenticated user.
|
ListSubnetsResponse |
listSubnets(ListSubnetsRequest request)
Return a list of subnet owned by the authenticated user.
|
void |
modifySubnetAttributes(ModifySubnetAttributesRequest modifySubnetAttributesRequest)
Modifying the special attribute to new value of the subnet owned by the user.
|
void |
modifySubnetAttributes(String subnetId,
String name)
Modifying the special attribute to new value of the subnet owned by the user.
|
computeBktVirEndpoint, computeServiceId, getBktVirEndpoint, getClient, getEndpoint, getServiceId, invokeHttpClient, isRegionSupported, setClient, shutdownpublic SubnetClient()
public SubnetClient(BceClientConfiguration clientConfiguration)
clientConfiguration - The network client configuration options controlling how this client
connects to network (e.g. proxy settings, retry counts, etc).public CreateSubnetResponse createSubnet(String name, String vpcId, String cidr, String zoneName)
name - The name of subnet that will be created.vpcId - The id of vpc which this subnet belong.cidr - The CIDR of this subnet.zoneName - the name of available zone which the subnet belong
through listZones, we can get all available zone info at current region
ee.g. "cn-gz-a" "cn-gz-b"public CreateSubnetResponse createSubnet(CreateSubnetRequest request) throws BceClientException
request - The request containing all options for creating subnet.BceClientExceptionpublic ListSubnetsResponse listSubnets()
public ListSubnetsResponse listSubnets(ListSubnetsRequest request)
request - The request containing all options for listing own's subnet.@Deprecated public GetSubnetResponse getSubnet(String subnetId)
subnetId - The id of the subnet.public GetSubnetResponse getSubnet(GetSubnetRequest getSubnetRequest)
getSubnetRequest - The request containing all options for getting the subnet info.public GetSubnetDetailResponse getSubnetDetail(String subnetId)
subnetId - The id of the subnet.public void deleteSubnet(String subnetId)
subnetId - The id of the subnet to delete.public void deleteSubnet(DeleteSubnetRequest deleteSubnetRequest)
deleteSubnetRequest - the request containing all options for deleting own's subnet.public void modifySubnetAttributes(String subnetId, String name)
subnetId - The id of the subnetname - The name of the subnet after modifyingpublic void modifySubnetAttributes(ModifySubnetAttributesRequest modifySubnetAttributesRequest)
modifySubnetAttributesRequest - The request containing all options for modifying own's subnet.Copyright © 2023. All rights reserved.