1 Star 0 Fork 0

zhuchance/kubernetes

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
delegate.go 1.58 KB
一键复制 编辑 原始数据 按行查看 历史
Masahiro Sano 提交于 2015-04-18 18:35 . Update gophercloud to latest
package ports
import (
"github.com/rackspace/gophercloud"
os "github.com/rackspace/gophercloud/openstack/networking/v2/ports"
"github.com/rackspace/gophercloud/pagination"
)
// List returns a Pager which allows you to iterate over a collection of
// ports. It accepts a ListOpts struct, which allows you to filter and sort
// the returned collection for greater efficiency.
//
// Default policy settings return only those ports that are owned by the tenant
// who submits the request, unless the request is submitted by a user with
// administrative rights.
func List(c *gophercloud.ServiceClient, opts os.ListOptsBuilder) pagination.Pager {
return os.List(c, opts)
}
// Get retrieves a specific port based on its unique ID.
func Get(c *gophercloud.ServiceClient, networkID string) os.GetResult {
return os.Get(c, networkID)
}
// Create accepts a CreateOpts struct and creates a new network using the values
// provided. You must remember to provide a NetworkID value.
//
// NOTE: Currently the SecurityGroup option is not implemented to work with
// Rackspace.
func Create(c *gophercloud.ServiceClient, opts os.CreateOptsBuilder) os.CreateResult {
return os.Create(c, opts)
}
// Update accepts a UpdateOpts struct and updates an existing port using the
// values provided.
func Update(c *gophercloud.ServiceClient, networkID string, opts os.UpdateOptsBuilder) os.UpdateResult {
return os.Update(c, networkID, opts)
}
// Delete accepts a unique ID and deletes the port associated with it.
func Delete(c *gophercloud.ServiceClient, networkID string) os.DeleteResult {
return os.Delete(c, networkID)
}
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
Go
1
https://gitee.com/meoom/kubernetes.git
git@gitee.com:meoom/kubernetes.git
meoom
kubernetes
kubernetes
v1.2.1-beta.0

搜索帮助

Cb406eda 1850385 E526c682 1850385