blob: fc547cde5f4c9f9d865577dd412d7189bdf9bd14 [file] [log] [blame]
Jamie Hannaford2aaf1a62014-10-16 12:55:50 +02001package extensions
2
3import (
4 "github.com/rackspace/gophercloud"
5 common "github.com/rackspace/gophercloud/openstack/common/extensions"
6 "github.com/rackspace/gophercloud/pagination"
7)
8
9// ExtractExtensions accepts a Page struct, specifically an ExtensionPage struct, and extracts the
10// elements into a slice of os.Extension structs.
11func ExtractExtensions(page pagination.Page) ([]common.Extension, error) {
12 return common.ExtractExtensions(page)
13}
14
15// Get retrieves information for a specific extension using its alias.
16func Get(c *gophercloud.ServiceClient, alias string) common.GetResult {
17 return common.Get(c, alias)
18}
19
20// List returns a Pager which allows you to iterate over the full collection of extensions.
21// It does not accept query parameters.
22func List(c *gophercloud.ServiceClient) pagination.Pager {
23 return common.List(c)
24}