blob: 9d9d1786db3e499bcf9d59f0dc2fa7d9910a07ee [file] [log] [blame]
Joe Topjian520307e2015-02-07 05:22:12 +00001package volumeattach
2
3import "github.com/rackspace/gophercloud"
4
5const resourcePath = "os-volume_attachments"
6
7func resourceURL(c *gophercloud.ServiceClient, serverId string) string {
8 return c.ServiceURL("servers", serverId, resourcePath)
9}
10
11func listURL(c *gophercloud.ServiceClient, serverId string) string {
12 return resourceURL(c, serverId)
13}
14
15func createURL(c *gophercloud.ServiceClient, serverId string) string {
16 return resourceURL(c, serverId)
17}
18
19func getURL(c *gophercloud.ServiceClient, serverId, aId string) string {
20 return c.ServiceURL("servers", serverId, resourcePath, aId)
21}
22
23func deleteURL(c *gophercloud.ServiceClient, serverId, aId string) string {
24 return getURL(c, serverId, aId)
25}