Ash Wilson | 0482daf | 2014-10-22 11:24:40 -0400 | [diff] [blame] | 1 | package keypairs |
| 2 | |
Jon Perritt | 27249f4 | 2016-02-18 10:35:59 -0600 | [diff] [blame] | 3 | import "github.com/gophercloud/gophercloud" |
Ash Wilson | 0482daf | 2014-10-22 11:24:40 -0400 | [diff] [blame] | 4 | |
| 5 | const resourcePath = "os-keypairs" |
| 6 | |
| 7 | func resourceURL(c *gophercloud.ServiceClient) string { |
| 8 | return c.ServiceURL(resourcePath) |
| 9 | } |
| 10 | |
| 11 | func listURL(c *gophercloud.ServiceClient) string { |
| 12 | return resourceURL(c) |
| 13 | } |
| 14 | |
| 15 | func createURL(c *gophercloud.ServiceClient) string { |
| 16 | return resourceURL(c) |
| 17 | } |
| 18 | |
| 19 | func getURL(c *gophercloud.ServiceClient, name string) string { |
| 20 | return c.ServiceURL(resourcePath, name) |
| 21 | } |
| 22 | |
| 23 | func deleteURL(c *gophercloud.ServiceClient, name string) string { |
| 24 | return getURL(c, name) |
| 25 | } |