refactoring

This commit is contained in:
Chris Lu
2020-01-19 23:59:46 -08:00
parent 2f15e93466
commit 1b0bfbaf59
12 changed files with 92 additions and 85 deletions

View File

@@ -3,6 +3,8 @@ package filer2
import (
"path/filepath"
"strings"
"github.com/chrislusf/seaweedfs/weed/util"
)
type FullPath string
@@ -34,3 +36,7 @@ func (fp FullPath) Child(name string) FullPath {
}
return FullPath(dir + "/" + name)
}
func (fp FullPath) AsInode() uint64 {
return uint64(util.HashStringToLong(string(fp)))
}