gophercloud: github.com/rackspace/gophercloud/openstack/common/extensions Index | Files

package extensions

import "github.com/rackspace/gophercloud/openstack/common/extensions"

Package extensions provides information and interaction with the different extensions available for an OpenStack service.

The purpose of OpenStack API extensions is to:

- Introduce new features in the API without requiring a version change. - Introduce vendor-specific niche functionality. - Act as a proving ground for experimental functionalities that might be included in a future

version of the API.

Extensions usually have tags that prevent conflicts with other extensions that define attributes or resources with the same names, and with core resources and attributes. Because an extension might not be supported by all plug-ins, its availability varies with deployments and the specific plug-in.

Index

Package Files

doc.go errors.go requests.go results.go urls.go

func ExtensionURL Uses

func ExtensionURL(c *gophercloud.ServiceClient, name string) string

ExtensionURL generates the URL for an extension resource by name.

func ExtractExtensions Uses

func ExtractExtensions(page pagination.Page) ([]Extension, error)

ExtractExtensions accepts a Page struct, specifically an ExtensionPage struct, and extracts the elements into a slice of Extension structs. In other words, a generic collection is mapped into a relevant slice.

func List Uses

func List(c *gophercloud.ServiceClient) pagination.Pager

List returns a Pager which allows you to iterate over the full collection of extensions. It does not accept query parameters.

func ListExtensionURL Uses

func ListExtensionURL(c *gophercloud.ServiceClient) string

ListExtensionURL generates the URL for the extensions resource collection.

type Extension Uses

type Extension struct {
    Updated     string        `json:"updated" mapstructure:"updated"`
    Name        string        `json:"name" mapstructure:"name"`
    Links       []interface{} `json:"links" mapstructure:"links"`
    Namespace   string        `json:"namespace" mapstructure:"namespace"`
    Alias       string        `json:"alias" mapstructure:"alias"`
    Description string        `json:"description" mapstructure:"description"`
}

Extension is a struct that represents an OpenStack extension.

type ExtensionPage Uses

type ExtensionPage struct {
    pagination.SinglePageBase
}

ExtensionPage is the page returned by a pager when traversing over a collection of extensions.

func (ExtensionPage) IsEmpty Uses

func (r ExtensionPage) IsEmpty() (bool, error)

IsEmpty checks whether an ExtensionPage struct is empty.

type GetResult Uses

type GetResult struct {
    gophercloud.Result
}

GetResult temporarily stores the result of a Get call. Use its Extract() method to interpret it as an Extension.

func Get Uses

func Get(c *gophercloud.ServiceClient, alias string) GetResult

Get retrieves information for a specific extension using its alias.

func (GetResult) Extract Uses

func (r GetResult) Extract() (*Extension, error)

Extract interprets a GetResult as an Extension.

Package extensions imports 3 packages (graph) and is imported by 8 packages. Updated 2016-07-14. Refresh now. Tools for package owners.