blob: 3a66fcce04ca546e3079c38591243fd180af82b8 [file] [log] [blame]
Simon Murraya9d5de42016-11-03 15:06:44 +00001package hypervisors
2
3import (
4 "github.com/gophercloud/gophercloud"
5 "github.com/gophercloud/gophercloud/pagination"
6)
7
8// List makes a request against the API to list hypervisors.
9func List(client *gophercloud.ServiceClient) pagination.Pager {
10 return pagination.NewPager(client, hypervisorsListDetailURL(client), func(r pagination.PageResult) pagination.Page {
11 return HypervisorPage{pagination.SinglePageBase(r)}
12 })
13}
14
15
16func AggregateList(client *gophercloud.ServiceClient) pagination.Pager {
17 return pagination.NewPager(client, aggregatesListURL(client), func(r pagination.PageResult) pagination.Page {
18 return AggregatePage{pagination.SinglePageBase(r)}
19 })
20}
21