MCPcopy Create free account
hub / github.com/bufbuild/buf / GetFile

Method GetFile

private/bufpkg/bufimage/bufimage.go:243–243  ·  view source on GitHub ↗

GetFile gets the file for the root relative file path. If the file does not exist, nil is returned. The path is expected to be normalized and validated. Note that all values of GetDependency() can be used here.

(path string)

Source from the content-addressed store, hash-verified

241 // The path is expected to be normalized and validated.
242 // Note that all values of GetDependency() can be used here.
243 GetFile(path string) ImageFile
244 // Resolver returns a resolver backed by this image.
245 Resolver() protoencoding.Resolver
246

Callers 15

TestBasicFunction · 0.95
getImageForMessageRefMethod · 0.95
bootstrapResolverFunction · 0.95
runFunction · 0.65
NewHandlerFunction · 0.65
TestCloneImageFunction · 0.65
validateProtoImageFunction · 0.65
NewImageForProtoFunction · 0.65
ImageToProtoImageFunction · 0.65
reparseImageProtoFunction · 0.65

Implementers 1

imageprivate/bufpkg/bufimage/image.go

Calls

no outgoing calls

Tested by 8

TestBasicFunction · 0.76
TestCloneImageFunction · 0.52
TestMutateInPlaceFunction · 0.52
runSourceCodeInfoTestFunction · 0.52
TestModifyImageFunction · 0.52
TestModifyImageFileFunction · 0.52