Jon Perritt | 24270c4 | 2014-10-21 21:11:04 -0500 | [diff] [blame] | 1 | package networks |
| 2 | |
| 3 | import "github.com/rackspace/gophercloud" |
| 4 | |
| 5 | func resourceURL(c *gophercloud.ServiceClient, id string) string { |
Jon Perritt | 44b1ea2 | 2014-10-22 00:13:23 -0500 | [diff] [blame] | 6 | return c.ServiceURL("os-networksv2", id) |
Jon Perritt | 24270c4 | 2014-10-21 21:11:04 -0500 | [diff] [blame] | 7 | } |
| 8 | |
| 9 | func rootURL(c *gophercloud.ServiceClient) string { |
Jon Perritt | 44b1ea2 | 2014-10-22 00:13:23 -0500 | [diff] [blame] | 10 | return c.ServiceURL("os-networksv2") |
Jon Perritt | 24270c4 | 2014-10-21 21:11:04 -0500 | [diff] [blame] | 11 | } |
| 12 | |
| 13 | func getURL(c *gophercloud.ServiceClient, id string) string { |
Jon Perritt | 44b1ea2 | 2014-10-22 00:13:23 -0500 | [diff] [blame] | 14 | return resourceURL(c, id) |
Jon Perritt | 24270c4 | 2014-10-21 21:11:04 -0500 | [diff] [blame] | 15 | } |
| 16 | |
| 17 | func listURL(c *gophercloud.ServiceClient) string { |
Jon Perritt | 44b1ea2 | 2014-10-22 00:13:23 -0500 | [diff] [blame] | 18 | return rootURL(c) |
Jon Perritt | 24270c4 | 2014-10-21 21:11:04 -0500 | [diff] [blame] | 19 | } |
| 20 | |
| 21 | func createURL(c *gophercloud.ServiceClient) string { |
Jon Perritt | 44b1ea2 | 2014-10-22 00:13:23 -0500 | [diff] [blame] | 22 | return rootURL(c) |
Jon Perritt | 24270c4 | 2014-10-21 21:11:04 -0500 | [diff] [blame] | 23 | } |
| 24 | |
| 25 | func deleteURL(c *gophercloud.ServiceClient, id string) string { |
Jon Perritt | 44b1ea2 | 2014-10-22 00:13:23 -0500 | [diff] [blame] | 26 | return resourceURL(c, id) |
Jon Perritt | 24270c4 | 2014-10-21 21:11:04 -0500 | [diff] [blame] | 27 | } |