MCPcopy
hub / github.com/dgraph-io/dgraph / NewFileHandler

Function NewFileHandler

worker/backup_handler.go:153–157  ·  view source on GitHub ↗
(uri *url.URL)

Source from the content-addressed store, hash-verified

151}
152
153func NewFileHandler(uri *url.URL) *fileHandler {
154 h := &fileHandler{}
155 h.rootDir, h.prefix = filepath.Split(uri.Path)
156 return h
157}
158
159func (h *fileHandler) DirExists(path string) bool { return pathExist(h.JoinPath(path)) }
160func (h *fileHandler) FileExists(path string) bool { return pathExist(h.JoinPath(path)) }

Callers 2

testFileHandlerForDirFunction · 0.85
NewUriHandlerFunction · 0.85

Calls

no outgoing calls

Tested by 1

testFileHandlerForDirFunction · 0.68