blob: 7c3de2418f88576699389549f6fe5b01e8b01970 [file] [log] [blame]
Dan Kirkwoodceb84092016-03-01 13:58:34 -07001package quotas
2
3import (
4 "github.com/rackspace/gophercloud"
5 "github.com/rackspace/gophercloud/pagination"
6)
7
8func List(client *gophercloud.ServiceClient) pagination.Pager {
9 return pagination.NewPager(client, listURL(client), func(r pagination.PageResult) pagination.Page {
10 return QuotaPage{pagination.SinglePageBase(r)}
11 })
12}
13
14// Get returns public data about a previously created Quota.
15func Get(client *gophercloud.ServiceClient, name string) GetResult {
16 var res GetResult
17 _, res.Err = client.Get(getURL(client, name), &res.Body, nil)
18 return res
19}