mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2025-10-15 20:06:19 +08:00
a correct implementation of filer
This commit is contained in:
18
go/filer/directory.go
Normal file
18
go/filer/directory.go
Normal file
@@ -0,0 +1,18 @@
|
||||
package filer
|
||||
|
||||
import ()
|
||||
|
||||
type DirectoryId int32
|
||||
|
||||
type DirectoryEntry struct {
|
||||
Name string //dir name without path
|
||||
Id DirectoryId
|
||||
}
|
||||
|
||||
type DirectoryManager interface {
|
||||
FindDirectory(dirPath string) (DirectoryId, error)
|
||||
ListDirectories(dirPath string) (dirNames []DirectoryEntry, err error)
|
||||
MakeDirectory(currentDirPath string, dirName string) (DirectoryId, error)
|
||||
MoveUnderDirectory(oldDirPath string, newParentDirPath string) error
|
||||
DeleteDirectory(dirPath string) error
|
||||
}
|
Reference in New Issue
Block a user