Documentation
¶
Index ¶
- func CreateURL(c *gophercloud.ServiceClient) string
- func DeleteURL(c *gophercloud.ServiceClient, vpcId string) string
- func GetURL(c *gophercloud.ServiceClient, vpcId string) string
- func List(client *gophercloud.ServiceClient, opts ListOptsBuilder) pagination.Pager
- func ListURL(c *gophercloud.ServiceClient) string
- func UpdateURL(c *gophercloud.ServiceClient, vpcId string) string
- type CreateOpts
- type CreateOptsBuilder
- type CreateResult
- type DeleteResult
- type GetResult
- type ListOpts
- type ListOptsBuilder
- type Route
- type UpdateOpts
- type UpdateOptsBuilder
- type UpdateResult
- type VPC
- type VpcPage
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CreateURL ¶
func CreateURL(c *gophercloud.ServiceClient) string
func DeleteURL ¶
func DeleteURL(c *gophercloud.ServiceClient, vpcId string) string
func GetURL ¶
func GetURL(c *gophercloud.ServiceClient, vpcId string) string
func List ¶
func List(client *gophercloud.ServiceClient, opts ListOptsBuilder) pagination.Pager
func ListURL ¶
func ListURL(c *gophercloud.ServiceClient) string
func UpdateURL ¶
func UpdateURL(c *gophercloud.ServiceClient, vpcId string) string
Types ¶
type CreateOpts ¶
type CreateOpts struct {
// Specifies the name of the VPC. The name must be unique for a
// tenant. The value is a string of no more than 64 characters and can contain digits,
// letters, underscores (_), and hyphens (-).
Name string `json:"name,omitempty"`
// Specifies the VPC description. The value is a string of 0 to 255
// characters and cannot contain "<" or ">".
Description string `json:"description,omitempty"`
// Specifies the range of available subnets in the VPC. The value
// must be in CIDR format, for example, 192.168.0.0/16. The value ranges from 10.0.0.0/8
// to 10.255.255.0/24, 172.16.0.0/12 to 172.31.255.0/24, or 192.168.0.0/16 to
// 192.168.255.0/24.
Cidr string `json:"cidr,omitempty"`
// Specifies the enterprise project ID. This field can be used to
// filter out the VPCs associated with a specified enterprise project.
EnterpriseProjectId string `json:"enterprise_project_id,omitempty"`
}
func (CreateOpts) ToVPCCreateMap ¶
func (opts CreateOpts) ToVPCCreateMap() (map[string]interface{}, error)
type CreateOptsBuilder ¶
type CreateResult ¶
type CreateResult struct {
// contains filtered or unexported fields
}
func Create ¶
func Create(client *gophercloud.ServiceClient, opts CreateOptsBuilder) (r CreateResult)
func (CreateResult) Extract ¶
func (r CreateResult) Extract() (*VPC, error)
type DeleteResult ¶
type DeleteResult struct {
gophercloud.ErrResult
}
func Delete ¶
func Delete(client *gophercloud.ServiceClient, vpcId string) (r DeleteResult)
type GetResult ¶
type GetResult struct {
// contains filtered or unexported fields
}
func Get ¶
func Get(client *gophercloud.ServiceClient, vpcId string) (r GetResult)
type ListOpts ¶
type ListOpts struct {
// Specifies the resource ID of pagination query. If the parameter
// is left blank, only resources on the first page are queried.
Marker string `q:"marker"`
// Specifies the number of records returned on each page.
Limit int `q:"limit"`
//The value can contain a maximum of 36 characters.
//It is string "0" or in UUID format with hyphens (-). Value
//"0" indicates the default enterprise project.Specifies the enterprise project ID.
//This field can be used to filter the security groups of an enterprise project.
EnterpriseProjectID string `q:"enterprise_project_id"`
}
func (ListOpts) ToVPCListQuery ¶
type ListOptsBuilder ¶
type UpdateOpts ¶
type UpdateOpts struct {
// Specifies the name of the VPC. The name must be unique for a
// tenant. The value is a string of no more than 64 characters and can contain digits,
// letters, underscores (_), and hyphens (-).
Name string `json:"name,omitempty"`
// Specifies the VPC description. The value is a string of 0 to 255
// characters and cannot contain "<" or ">".
Description string `json:"description,omitempty"`
// Specifies the range of available subnets in the VPC. The value
// must be in CIDR format, for example, 192.168.0.0/16. The value ranges from 10.0.0.0/8
// to 10.255.255.0/24, 172.16.0.0/12 to 172.31.255.0/24, or 192.168.0.0/16 to
// 192.168.255.0/24.
Cidr string `json:"cidr,omitempty"`
}
func (UpdateOpts) ToVPCUpdateMap ¶
func (opts UpdateOpts) ToVPCUpdateMap() (map[string]interface{}, error)
type UpdateOptsBuilder ¶
type UpdateResult ¶
type UpdateResult struct {
// contains filtered or unexported fields
}
func Update ¶
func Update(client *gophercloud.ServiceClient, vpcId string, opts UpdateOptsBuilder) (r UpdateResult)
func (UpdateResult) Extract ¶
func (r UpdateResult) Extract() (*VPC, error)
type VPC ¶
type VPC struct {
// Specifies a resource ID in UUID format.
ID string `json:"id"`
// Specifies the name of the VPC. The name must be unique for a
// tenant. The value is a string of no more than 64 characters and can contain digits,
// letters, underscores (_), and hyphens (-).
Name string `json:"name,omitempty"`
// Specifies the VPC description. The value is a string of 0 to 255
// characters and cannot contain "<" or ">".
Description string `json:"description,omitempty"`
// Specifies the range of available subnets in the VPC. The value
// must be in CIDR format, for example, 192.168.0.0/16. The value ranges from 10.0.0.0/8
// to 10.255.255.0/24, 172.16.0.0/12 to 172.31.255.0/24, or 192.168.0.0/16 to
// 192.168.255.0/24.
Cidr string `json:"cidr,omitempty"`
// Specifies the status of the VPC. The value can be CREATING, OK,
// DOWN, PENDING_UPDATE, PENDING_DELETE, or ERROR.
Status string `json:"status"`
// Specifies the route information.
Routes []Route `json:"routes"`
// Specifies the enterprise project ID. This field can be used to
// filter out the VPCs associated with a specified enterprise project.
EnterpriseProjectId string `json:"enterprise_project_id"`
}
func ExtractVpcs ¶
func ExtractVpcs(r pagination.Page) ([]VPC, error)
type VpcPage ¶
type VpcPage struct {
pagination.LinkedPageBase
}
func (VpcPage) NextPageURL ¶
Click to show internal directories.
Click to hide internal directories.