MCPcopy Create free account
hub / github.com/containers/image / StringWithinTransport

Method StringWithinTransport

storage/storage_reference.go:209–223  ·  view source on GitHub ↗

Return a name with a tag, prefixed with the graph root and driver name, to disambiguate between images which may be present in multiple stores and share only their names.

()

Source from the content-addressed store, hash-verified

207// disambiguate between images which may be present in multiple stores and
208// share only their names.
209func (s storageReference) StringWithinTransport() string {
210 optionsList := ""
211 options := s.transport.store.GraphOptions()
212 if len(options) > 0 {
213 optionsList = ":" + strings.Join(options, ",")
214 }
215 res := "[" + s.transport.store.GraphDriverName() + "@" + s.transport.store.GraphRoot() + "+" + s.transport.store.RunRoot() + optionsList + "]"
216 if s.named != nil {
217 res += s.named.String()
218 }
219 if s.id != "" {
220 res += "@" + s.id
221 }
222 return res
223}
224
225func (s storageReference) PolicyConfigurationIdentity() string {
226 res := "[" + s.transport.store.GraphDriverName() + "@" + s.transport.store.GraphRoot() + "]"

Callers 1

resolveImageMethod · 0.95

Calls 1

StringMethod · 0.65

Tested by

no test coverage detected