MCPcopy Create free account
hub / github.com/cloudfoundry/multiapps-cli-plugin / getPropertyOrDefault

Function getPropertyOrDefault

configuration/configuration.go:70–76  ·  view source on GitHub ↗
(property properties.ConfigurableProperty)

Source from the content-addressed store, hash-verified

68}
69
70func getPropertyOrDefault(property properties.ConfigurableProperty) interface{} {
71 value := getPropertyWithNameOrDefaultIfInvalid(property, property.Name)
72 if value != nil {
73 return value
74 }
75 return property.DefaultValue
76}
77
78func getPropertyWithNameOrDefaultIfInvalid(property properties.ConfigurableProperty, name string) interface{} {
79 propertyValue, err := getPropertyWithName(name, property.Parser)

Callers 3

getStringPropertyFunction · 0.85
getUint64PropertyFunction · 0.85
getBoolPropertyFunction · 0.85

Tested by

no test coverage detected