MCPcopy
hub / github.com/golang/tools / Dir

Method Dir

gopls/internal/protocol/uri.go:100–104  ·  view source on GitHub ↗

Dir returns the URI for the directory containing the receiver.

()

Source from the content-addressed store, hash-verified

98
99// Dir returns the URI for the directory containing the receiver.
100func (uri DocumentURI) Dir() DocumentURI {
101 // This function could be more efficiently implemented by avoiding any call
102 // to Path(), but at least consolidates URI manipulation.
103 return URIFromPath(uri.DirPath())
104}
105
106// DirPath returns the file path to the directory containing this URI, which
107// must be a file URI.

Callers 15

windowsCheckPathValidFunction · 0.80
goWorkModulesFunction · 0.80
goModModulesFunction · 0.80
addDirsMethod · 0.80
writeFilesFunction · 0.80
isWorkspacePackageLockedFunction · 0.80
RelevantViewsFunction · 0.80
depsErrorsFunction · 0.80
moduleForURIFunction · 0.80
darwinCheckPathValidFunction · 0.80

Calls 2

DirPathMethod · 0.95
URIFromPathFunction · 0.85

Tested by 15

writeFilesFunction · 0.64
TestIssue61208Function · 0.64
Test58382Function · 0.64
Test61208Function · 0.64
Test60663Function · 0.64
TestDeprecated70736Function · 0.64
fmtLocMethod · 0.64
TestBrokenSymlinkFunction · 0.64
writeTreeFunction · 0.64
TestVulncheckPreferenceFunction · 0.64