forked from cloudfoundry/cli
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathservice_offering_resource.go
31 lines (27 loc) · 1.01 KB
/
service_offering_resource.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
package resources
import (
"code.cloudfoundry.org/cli/types"
"code.cloudfoundry.org/jsonry"
)
type ServiceOffering struct {
// GUID is a unique service offering identifier.
GUID string `json:"guid"`
// Name is the name of the service offering.
Name string `json:"name"`
// Description of the service offering
Description string `json:"description"`
// DocumentationURL of the service offering
DocumentationURL string `json:"documentation_url"`
// Tags are used by apps to identify service instances.
Tags types.OptionalStringSlice `jsonry:"tags"`
// ServiceBrokerGUID is the guid of the service broker
ServiceBrokerGUID string `jsonry:"relationships.service_broker.data.guid"`
// ServiceBrokerName is the name of the service broker
ServiceBrokerName string `json:"-"`
// Shareable if the offering support service instance sharing
AllowsInstanceSharing bool `json:"shareable"`
Metadata *Metadata `json:"metadata"`
}
func (s *ServiceOffering) UnmarshalJSON(data []byte) error {
return jsonry.Unmarshal(data, s)
}