github.com/huaweicloud/golangsdk@v0.0.0-20210831081626-d823fe11ceba/openstack/networking/v2/extensions/lbaas/pools/urls.go (about) 1 package pools 2 3 import "github.com/huaweicloud/golangsdk" 4 5 const ( 6 rootPath = "lb" 7 resourcePath = "pools" 8 monitorPath = "health_monitors" 9 ) 10 11 func rootURL(c *golangsdk.ServiceClient) string { 12 return c.ServiceURL(rootPath, resourcePath) 13 } 14 15 func resourceURL(c *golangsdk.ServiceClient, id string) string { 16 return c.ServiceURL(rootPath, resourcePath, id) 17 } 18 19 func associateURL(c *golangsdk.ServiceClient, id string) string { 20 return c.ServiceURL(rootPath, resourcePath, id, monitorPath) 21 } 22 23 func disassociateURL(c *golangsdk.ServiceClient, poolID, monitorID string) string { 24 return c.ServiceURL(rootPath, resourcePath, poolID, monitorPath, monitorID) 25 }