MCPcopy Create free account
hub / github.com/cloudfoundry/cli / Rename

Method Rename

cf/api/service_brokers.go:107–111  ·  view source on GitHub ↗
(guid, name string)

Source from the content-addressed store, hash-verified

105}
106
107func (repo CloudControllerServiceBrokerRepository) Rename(guid, name string) (apiErr error) {
108 path := fmt.Sprintf("/v2/service_brokers/%s", guid)
109 body := fmt.Sprintf(`{"name":"%s"}`, name)
110 return repo.gateway.UpdateResource(repo.config.APIEndpoint(), path, strings.NewReader(body))
111}
112
113func (repo CloudControllerServiceBrokerRepository) Delete(guid string) (apiErr error) {
114 path := fmt.Sprintf("/v2/service_brokers/%s", guid)

Callers

nothing calls this directly

Calls 2

UpdateResourceMethod · 0.80
APIEndpointMethod · 0.65

Tested by

no test coverage detected