Documentation ¶
Overview ¶
eni.go - the eni APIs definition supported by the eni service
Index ¶
- Constants
- type AddPrivateIpResult
- type BindEniPublicIpArgs
- type Client
- func (c *Client) AddPrivateIp(args *EniPrivateIpArgs) (*AddPrivateIpResult, error)
- func (c *Client) AttachEniInstance(args *EniInstance) error
- func (c *Client) BindEniPublicIp(args *BindEniPublicIpArgs) error
- func (c *Client) CreateEni(args *CreateEniArgs) (*CreateEniResult, error)
- func (c *Client) DeleteEni(args *DeleteEniArgs) error
- func (c *Client) DeletePrivateIp(args *EniPrivateIpArgs) error
- func (c *Client) DetachEniInstance(args *EniInstance) error
- func (c *Client) GetEniDetail(eniId string) (*Eni, error)
- func (c *Client) GetEniQuota(args *EniQuoteArgs) (*EniQuoteInfo, error)
- func (c *Client) ListEni(args *ListEniArgs) (*ListEniResult, error)
- func (c *Client) UnBindEniPublicIp(args *UnBindEniPublicIpArgs) error
- func (c *Client) UpdateEni(args *UpdateEniArgs) error
- func (c *Client) UpdateEniSecurityGroup(args *UpdateEniSecurityGroupArgs) error
- type CreateEniArgs
- type CreateEniResult
- type DeleteEniArgs
- type Eni
- type EniInstance
- type EniPrivateIpArgs
- type EniQuoteArgs
- type EniQuoteInfo
- type ListEniArgs
- type ListEniResult
- type PrivateIp
- type UnBindEniPublicIpArgs
- type UpdateEniArgs
- type UpdateEniSecurityGroupArgs
Constants ¶
const ( URI_PREFIX = bce.URI_PREFIX + "v1" DEFAULT_ENI = "bcc." + bce.DEFAULT_REGION + ".baidubce.com" REQUEST_ENI_URL = "/eni" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AddPrivateIpResult ¶ added in v0.9.49
type AddPrivateIpResult struct {
PrivateIpAddress string `json:"privateIpAddress"`
}
type BindEniPublicIpArgs ¶
type Client ¶
Client of ENI service is a kind of BceClient, so derived from BceClient
func (*Client) AddPrivateIp ¶ added in v0.9.49
func (c *Client) AddPrivateIp(args *EniPrivateIpArgs) (*AddPrivateIpResult, error)
AddPrivateIp - add private ip
PARAMS:
- args: the arguments to add private ip
RETURNS:
- *AddPrivateIpResult: the private ip
- error: nil if success otherwise the specific error
func (*Client) AttachEniInstance ¶
func (c *Client) AttachEniInstance(args *EniInstance) error
AttachEniInstance - eni attach instance
PARAMS:
- args: the arguments to attach instance
RETURNS:
- error: nil if success otherwise the specific error
func (*Client) BindEniPublicIp ¶
func (c *Client) BindEniPublicIp(args *BindEniPublicIpArgs) error
BindEniPublicIp - eni bind public ip
PARAMS:
- args: the arguments to bind public ip
RETURNS:
- error: nil if success otherwise the specific error
func (*Client) CreateEni ¶
func (c *Client) CreateEni(args *CreateEniArgs) (*CreateEniResult, error)
CreateEni - create an eni with the specific parameters
PARAMS:
- args: the arguments to create an eni
RETURNS:
- *CreateEniResult: the result of create eni
- error: nil if success otherwise the specific error
func (*Client) DeleteEni ¶
func (c *Client) DeleteEni(args *DeleteEniArgs) error
DeleteEni - delete an eni
PARAMS:
- DeleteEniArgs: the arguments to delete an eni
RETURNS:
- error: nil if success otherwise the specific error
func (*Client) DeletePrivateIp ¶ added in v0.9.49
func (c *Client) DeletePrivateIp(args *EniPrivateIpArgs) error
DeletePrivateIp - delete private ip
PARAMS:
- args: the arguments to delete private ip
RETURNS:
- error: nil if success otherwise the specific error
func (*Client) DetachEniInstance ¶
func (c *Client) DetachEniInstance(args *EniInstance) error
DetachEniInstance - eni detach instance
PARAMS:
- args: the arguments to detach instance
RETURNS:
- error: nil if success otherwise the specific error
func (*Client) GetEniDetail ¶
GetEniDetail - get the eni detail
PARAMS:
- eniId: the specific eniId
RETURNS:
- *Eni: the eni
- error: nil if success otherwise the specific error
func (*Client) GetEniQuota ¶ added in v0.9.95
func (c *Client) GetEniQuota(args *EniQuoteArgs) (*EniQuoteInfo, error)
func (*Client) ListEni ¶
func (c *Client) ListEni(args *ListEniArgs) (*ListEniResult, error)
ListEnis - list all eni with the specific parameters
PARAMS:
- args: the arguments to list all eni
RETURNS:
- *ListEniResult: the result of list all eni
- error: nil if success otherwise the specific error
func (*Client) UnBindEniPublicIp ¶
func (c *Client) UnBindEniPublicIp(args *UnBindEniPublicIpArgs) error
UnBindEniPublicIp - eni unbind public ip
PARAMS:
- args: the arguments to bind public ip
RETURNS:
- error: nil if success otherwise the specific error
func (*Client) UpdateEni ¶
func (c *Client) UpdateEni(args *UpdateEniArgs) error
UpdateEni - update an eni
PARAMS:
- UpdateEniArgs: the arguments to update an eni
RETURNS:
- error: nil if success otherwise the specific error
func (*Client) UpdateEniSecurityGroup ¶
func (c *Client) UpdateEniSecurityGroup(args *UpdateEniSecurityGroupArgs) error
UpdateEniSecurityGroup - update eni sg
PARAMS:
- args: the arguments to update eni sg
RETURNS:
- error: nil if success otherwise the specific error
type CreateEniArgs ¶
type CreateEniResult ¶
type CreateEniResult struct {
EniId string `json:"eniId"`
}
type DeleteEniArgs ¶
type Eni ¶
type Eni struct { EniId string `json:"eniId"` Name string `json:"name"` ZoneName string `json:"zoneName"` Description string `json:"description"` InstanceId string `json:"instanceId"` MacAddress string `json:"macAddress"` VpcId string `json:"vpcId"` SubnetId string `json:"subnetId"` Status string `json:"status"` PrivateIpSet []PrivateIp `json:"privateIpSet"` SecurityGroupIds []string `json:"securityGroupIds"` CreatedTime string `json:"createdTime"` }