MCPcopy
hub / github.com/google/go-containerregistry / IsIndex

Method IsIndex

pkg/v1/types/types.go:67–73  ·  view source on GitHub ↗

IsIndex returns true if the mediaType represents an index, as opposed to something else, like an image.

()

Source from the content-addressed store, hash-verified

65
66// IsIndex returns true if the mediaType represents an index, as opposed to something else, like an image.
67func (m MediaType) IsIndex() bool {
68 switch m {
69 case OCIImageIndex, DockerManifestList:
70 return true
71 }
72 return false
73}
74
75// IsConfig returns true if the mediaType represents a config, as opposed to something else, like an image.
76func (m MediaType) IsConfig() bool {

Callers 15

handleMethod · 0.80
TestCopyWithPlatformFunction · 0.80
TestIsIndexFunction · 0.80
taggableToManifestFunction · 0.80
FindIndexesFunction · 0.80
ComputeManifestsFunction · 0.80
DigestFunction · 0.80
NewCmdRebaseFunction · 0.80
NewCmdIndexListFunction · 0.80
NewCmdIndexFilterFunction · 0.80
appendLocalFunction · 0.80

Calls

no outgoing calls

Tested by 2

TestCopyWithPlatformFunction · 0.64
TestIsIndexFunction · 0.64