MCPcopy Create free account
hub / github.com/cloudfoundry/java-buildpack / Get

Method Get

src/java/jres/jre.go:109–116  ·  view source on GitHub ↗

Get returns the JRE whose Name() matches the given name, or nil if not found. Used by the finalize phase to resolve a JRE by the name stored in config.yml.

(name string)

Source from the content-addressed store, hash-verified

107// Get returns the JRE whose Name() matches the given name, or nil if not found.
108// Used by the finalize phase to resolve a JRE by the name stored in config.yml.
109func (r *Registry) Get(name string) JRE {
110 for _, jre := range r.providers {
111 if jre.Name() == name {
112 return jre
113 }
114 }
115 return nil
116}
117
118// Detect finds the JRE provider that should be used
119// If a JRE is explicitly configured, it uses that JRE and fails if detection errors

Callers 4

resolveContainerFunction · 0.95
resolveJREFunction · 0.95
downloadAgentMethod · 0.45

Calls 1

NameMethod · 0.65

Tested by

no test coverage detected