63 lines
1.8 KiB
Go
63 lines
1.8 KiB
Go
//Code is generated by ucloud code generator, don't modify it by hand, it will cause undefined behaviors.
|
||
//go:generate ucloud-gen-go-api UNet UpdateEIPAttribute
|
||
|
||
package unet
|
||
|
||
import (
|
||
"github.com/ucloud/ucloud-sdk-go/ucloud/request"
|
||
"github.com/ucloud/ucloud-sdk-go/ucloud/response"
|
||
)
|
||
|
||
// UpdateEIPAttributeRequest is request schema for UpdateEIPAttribute action
|
||
type UpdateEIPAttributeRequest struct {
|
||
request.CommonBase
|
||
|
||
// [公共参数] 地域。 参见 [地域和可用区列表](../summary/regionlist.html)
|
||
// Region *string `required:"true"`
|
||
|
||
// [公共参数] 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html)
|
||
// ProjectId *string `required:"false"`
|
||
|
||
// EIP资源ID
|
||
EIPId *string `required:"true"`
|
||
|
||
// 名字(Name Tag Remark都为空则报错)
|
||
Name *string `required:"false"`
|
||
|
||
// 业务
|
||
Tag *string `required:"false"`
|
||
|
||
// 备注
|
||
Remark *string `required:"false"`
|
||
}
|
||
|
||
// UpdateEIPAttributeResponse is response schema for UpdateEIPAttribute action
|
||
type UpdateEIPAttributeResponse struct {
|
||
response.CommonBase
|
||
}
|
||
|
||
// NewUpdateEIPAttributeRequest will create request of UpdateEIPAttribute action.
|
||
func (c *UNetClient) NewUpdateEIPAttributeRequest() *UpdateEIPAttributeRequest {
|
||
req := &UpdateEIPAttributeRequest{}
|
||
|
||
// setup request with client config
|
||
c.Client.SetupRequest(req)
|
||
|
||
// setup retryable with default retry policy (retry for non-create action and common error)
|
||
req.SetRetryable(true)
|
||
return req
|
||
}
|
||
|
||
// UpdateEIPAttribute - 更新弹性IP名称,业务组,备注等属性字段
|
||
func (c *UNetClient) UpdateEIPAttribute(req *UpdateEIPAttributeRequest) (*UpdateEIPAttributeResponse, error) {
|
||
var err error
|
||
var res UpdateEIPAttributeResponse
|
||
|
||
err = c.Client.InvokeAction("UpdateEIPAttribute", req, &res)
|
||
if err != nil {
|
||
return &res, err
|
||
}
|
||
|
||
return &res, nil
|
||
}
|