github.com/huaweicloud/golangsdk@v0.0.0-20210831081626-d823fe11ceba/openstack/vbs/v2/policies/urls.go (about) 1 package policies 2 3 import "github.com/huaweicloud/golangsdk" 4 5 const ( 6 backupRootPath = "backuppolicy" 7 policyResourcePath = "backuppolicyresources" 8 ) 9 10 func commonURL(c *golangsdk.ServiceClient) string { 11 return c.ServiceURL(backupRootPath) 12 } 13 14 func resourceURL(c *golangsdk.ServiceClient, policyID string) string { 15 return c.ServiceURL(backupRootPath, policyID) 16 } 17 18 func associateURL(c *golangsdk.ServiceClient) string { 19 return c.ServiceURL(policyResourcePath) 20 } 21 22 func disassociateURL(c *golangsdk.ServiceClient, policyID string) string { 23 return c.ServiceURL(policyResourcePath, policyID, "deleted_resources") 24 }