Documentation ¶
Overview ¶
*Copyright 2015 Huawei Technologies Co., Ltd. All rights reserved. * eSDK is licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License.
*Copyright 2015 Huawei Technologies Co., Ltd. All rights reserved. * eSDK is licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License.
Index ¶
- type BandwidthCreate
- type CreatePublicIpReq
- type CreatePublicIpResp
- type CreateSecurityGroupReq
- type CreateSecurityGroupResp
- type CreateSubnetReq
- func (createSubnetReq *CreateSubnetReq) GetBodyContent() string
- func (createSubnetReq *CreateSubnetReq) Init(name, cidr, gateway_ip, availability_zone, vpc_id string)
- func (createSubnetReq *CreateSubnetReq) SetDhcpEnable(dhcp_enable bool)
- func (createSubnetReq *CreateSubnetReq) SetPrimaryDNS(primary_dns string)
- func (createSubnetReq *CreateSubnetReq) SetSecondaryDNS(secondary_dns string)
- type CreateSubnetResp
- type CreateVpcReq
- type CreateVpcResp
- type DeletePublicIpResp
- type DeleteSubnetResp
- type DeleteVpcResp
- type ListBandwidthsResp
- type ListSecurityGroupsResp
- type ListSubnetsResp
- type PublicipCreate
- type PublicipUpdate
- type ShowSubnetResp
- type ShowVpcResp
- type UpdateBandwidthReq
- type UpdateBandwidthResp
- type UpdatePublicIpReq
- type UpdatePublicIpResp
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BandwidthCreate ¶
type BandwidthCreate struct {
// contains filtered or unexported fields
}
Specifies the bandwidth objects.
func (*BandwidthCreate) Init ¶
func (bandwidthCreate *BandwidthCreate) Init(name string, size int, share_type string)
* @fn func (publicipCreate *PublicipCreate) SetType(Type string) * @brief Initialize * @param[in] name: Specifies the name of the bandwidth. * @param[in] size: Specifies the bandwidth capacity. * @param[in] share_type: The value is PER, indicating that the bandwidth is exclusive. * @param[out] * @return
func (*BandwidthCreate) SetChargeMode ¶
func (bandwidthCreate *BandwidthCreate) SetChargeMode(charge_mode string)
* @fn func (bandwidthCreate *BandwidthCreate) SetChargeMode(charge_mode string) * @brief Set the charging mode * @param[in] charge_mode: The value is traffic, indicating the charging is based on traffic. * @param[out] * @return
type CreatePublicIpReq ¶
type CreatePublicIpReq struct {
// contains filtered or unexported fields
}
The request of applying for an elastic ip address
func (*CreatePublicIpReq) GetBodyContent ¶
func (createPublicIpReq *CreatePublicIpReq) GetBodyContent() string
* @fn func (createPublicIpReq *CreatePublicIpReq) GetBodyContent() string * @brief Get the string of json format * @param[in] * @param[out] * @return string
func (*CreatePublicIpReq) Init ¶
func (createPublicIpReq *CreatePublicIpReq) Init(publicipCreate *PublicipCreate, bandwidthCreate *BandwidthCreate)
* @fn func (createPublicIpReq *CreatePublicIpReq) Init(publicipCreate *PublicipCreate, bandwidthCreate *BandwidthCreate) * @brief Initialize * @param[in] publicipCreate: Specifies the elastic IP address objects. * @param[in] bandwidthCreate: Specifies the bandwidth objects. * @param[out] * @return
type CreatePublicIpResp ¶
type CreatePublicIpResp struct { ResponseCode int modules.ErrorInfo modules.PublicipCreateData }
The response of applying for an elastic IP address
type CreateSecurityGroupReq ¶
type CreateSecurityGroupReq struct {
// contains filtered or unexported fields
}
The request of creating a security group
func (*CreateSecurityGroupReq) GetBodyContent ¶
func (createSecurityGroupReq *CreateSecurityGroupReq) GetBodyContent() string
* @fn func (createSecurityGroupReq *CreateSecurityGroupReq) GetBodyContent() string * @brief Get the string of json format * @param[in] * @param[out] * @return string
func (*CreateSecurityGroupReq) Init ¶
func (createSecurityGroupReq *CreateSecurityGroupReq) Init(name, vpc_id string)
* @fn func (createSecurityGroupReq *CreateSecurityGroupReq) Init(name, vpc_id string) * @brief Initialize * @param[in] name: Specifies the name of the security group. * @param[in] vpc_id: Specifies the resource ID of the VPC to which the security group belongs. * @param[out] * @return
type CreateSecurityGroupResp ¶
type CreateSecurityGroupResp struct { ResponseCode int modules.ErrorInfo modules.SecurityGroup }
The response of creating a security group
type CreateSubnetReq ¶
type CreateSubnetReq struct {
// contains filtered or unexported fields
}
The request of creating a subnet
func (*CreateSubnetReq) GetBodyContent ¶
func (createSubnetReq *CreateSubnetReq) GetBodyContent() string
* @fn func (createSubnetReq *CreateSubnetReq) GetBodyContent() string * @brief Get the string of json format * @param[in] * @param[out] * @return string
func (*CreateSubnetReq) Init ¶
func (createSubnetReq *CreateSubnetReq) Init(name, cidr, gateway_ip, availability_zone, vpc_id string)
* @fn func (createSubnetReq *CreateSubnetReq) Init(name, cidr, gateway_ip, availability_zone, vpc_id string) * @brief Initialize * @param[in] name: Specifies the name of the subnet. * @param[in] cidr: Specifies the network segment on which the subnet resides. * @param[in] gateway_ip: Specifies the gateway of the subnet. * @param[in] availability_zone: Specifies the ID of the availability zone (AZ) to which the subnet belongs. * @param[out] * @return
func (*CreateSubnetReq) SetDhcpEnable ¶
func (createSubnetReq *CreateSubnetReq) SetDhcpEnable(dhcp_enable bool)
- @fn func (createSubnetReq *CreateSubnetReq) SetDhcpEnable(dhcp_enable bool)
- @brief Specifies whether the DHCP function is enabled for the subnet.
- @param[in] dhcp_enable: Specifies whether the DHCP function is enabled for the subnet. The value can be true or false. If this parameter is left blank, it is set to true by default.
- @param[out]
- @return
func (*CreateSubnetReq) SetPrimaryDNS ¶
func (createSubnetReq *CreateSubnetReq) SetPrimaryDNS(primary_dns string)
- @fn func (createSubnetReq *CreateSubnetReq) SetPrimaryDNS(primary_dns string)
- @brief Specifies the primary IP address of the DNS server on the subnet.
- @param[in] primary_dns: Specifies the primary IP address of the DNS server on the subnet. The value must be a valid IP address.
- @param[out]
- @return
func (*CreateSubnetReq) SetSecondaryDNS ¶
func (createSubnetReq *CreateSubnetReq) SetSecondaryDNS(secondary_dns string)
- @fn func (createSubnetReq *CreateSubnetReq) SetSecondaryDNS(secondary_dns string)
- @brief Specifies the secondary IP address of the DNS server on the subnet.
- @param[in] secondary_dns: Specifies the secondary IP address of the DNS server on the subnet. The value must be a valid IP address.
- @param[out]
- @return
type CreateSubnetResp ¶
The response of creating a subnet
type CreateVpcReq ¶
type CreateVpcReq struct {
// contains filtered or unexported fields
}
The request of creating a VPC
func (*CreateVpcReq) GetBodyContent ¶
func (createVpcReq *CreateVpcReq) GetBodyContent() string
* @fn func (createVpcReq *CreateVpcReq) GetBodyContent() string * @brief Get the string of json format * @param[in] * @param[out] * @return string
func (*CreateVpcReq) Init ¶
func (createVpcReq *CreateVpcReq) Init(name, cidr string)
* @fn func (createVpcReq *CreateVpcReq) Init(name, cidr string) * @brief Initialize * @param[in] name: Specifies the name of the VPC. * @param[in] cidr: Specifies the range of available subnets in the VPC. * @param[out] * @return
type CreateVpcResp ¶
The response of creating a VPC
type DeletePublicIpResp ¶
The response of deleting an elastic IP address
type DeleteSubnetResp ¶
The response of deleting a subnet
type DeleteVpcResp ¶
The response of deleting a vpc
type ListBandwidthsResp ¶
type ListBandwidthsResp struct { ResponseCode int modules.ErrorInfo Bandwidths []modules.Bandwidth }
The response of querying bandwidths
type ListSecurityGroupsResp ¶
type ListSecurityGroupsResp struct { ResponseCode int modules.ErrorInfo SecurityGroups []modules.SecurityGroup }
The response of querying security groups
type ListSubnetsResp ¶
type PublicipCreate ¶
type PublicipCreate struct {
// contains filtered or unexported fields
}
Specifies the elastic IP address objects.
func (*PublicipCreate) SetType ¶
func (publicipCreate *PublicipCreate) SetType(Type string)
- @fn func (publicipCreate *PublicipCreate) SetType(Type string)
- @brief Specifies the elastic IP address type.
- @param[in] Type: Specifies the elastic IP address type. The value must be a type supported by the system. The value is 5_bgp.
- @param[out]
- @return
type PublicipUpdate ¶
type PublicipUpdate struct {
// contains filtered or unexported fields
}
Specifies the elastic IP address objects.
func (*PublicipUpdate) SetPortId ¶
func (publicipUpdate *PublicipUpdate) SetPortId(port_id string)
- @fn func (publicipUpdate *PublicipUpdate) SetPortId(port_id string)
- @brief Specifies the ID of the VM NIC.
- @param[in] port_id: Specifies the ID of the VM NIC. The parameter must be an existing NIC ID. If this parameter is not specified, this command unbinds the elastic IP address from the NIC.
- @param[out]
- @return
type ShowSubnetResp ¶
The response of querying subnet details
type ShowVpcResp ¶
The response of querying VPC details
type UpdateBandwidthReq ¶
type UpdateBandwidthReq struct {
// contains filtered or unexported fields
}
The request of updating bandwidth information
func (*UpdateBandwidthReq) GetBodyContent ¶
func (updateBandwidthReq *UpdateBandwidthReq) GetBodyContent() string
* @fn func (updateBandwidthReq *UpdateBandwidthReq) GetBodyContent() string * @brief Get the string of json format * @param[in] * @param[out] * @return string
func (*UpdateBandwidthReq) SetName ¶
func (updateBandwidthReq *UpdateBandwidthReq) SetName(name string)
* @fn func (updateBandwidthReq *UpdateBandwidthReq) SetName(name string) * @brief Specifies the name of the bandwidth. * @param[in] name: The name of the bandwidth. * @param[out] * @return
func (*UpdateBandwidthReq) SetSize ¶
func (updateBandwidthReq *UpdateBandwidthReq) SetSize(size int)
* @fn func (updateBandwidthReq *UpdateBandwidthReq) SetSize(size int) * @brief Specifies the bandwidth capacity. * @param[in] size: The bandwidth capacity. * @param[out] * @return
type UpdateBandwidthResp ¶
The response of updating bandwidth information
type UpdatePublicIpReq ¶
type UpdatePublicIpReq struct {
// contains filtered or unexported fields
}
The request of updating elastic ip address information
func (*UpdatePublicIpReq) GetBodyContent ¶
func (updatePublicIpReq *UpdatePublicIpReq) GetBodyContent() string
* @fn func (updatePublicIpReq *UpdatePublicIpReq) GetBodyContent() string * @brief Get the string of json format * @param[in] * @param[out] * @return string
func (*UpdatePublicIpReq) SetPublicip ¶
func (updatePublicIpReq *UpdatePublicIpReq) SetPublicip(publicipUpdate *PublicipUpdate)
* @fn func (updatePublicIpReq *UpdatePublicIpReq) SetPublicip(publicipUpdate *PublicipUpdate) * @brief Specifies the elastic IP address objects. * @param[in] publicipUpdate: Specifies the elastic IP address objects. * @param[out] * @return
type UpdatePublicIpResp ¶
type UpdatePublicIpResp struct { ResponseCode int modules.ErrorInfo modules.PublicipUpdateData }
The response of updating elastic IP address information