Documentation
¶
Index ¶
- Constants
- func ArrayUnique(arr []string) []string
- func CopyFile(src, dst string) (int64, error)
- func DirCHeckAndMk(dir string)
- func ExistFile(path string) bool
- func FileExist(filePath string) bool
- func GetMd5(filePath string) string
- func GetPath() string
- func GetWd() string
- func IntToBytes(n int) []byte
- func StrToBytes(s string) []byte
- func StrToMd5(str string) string
- func Tmd5() string
- func Walk(dirPath string) []string
- type FileHandler
Constants ¶
View Source
const FILEDIR = "/data/index/"
Variables ¶
This section is empty.
Functions ¶
func ArrayUnique ¶
func DirCHeckAndMk ¶
func DirCHeckAndMk(dir string)
func IntToBytes ¶
func StrToBytes ¶
Types ¶
type FileHandler ¶
type FileHandler struct {
// contains filtered or unexported fields
}
func (*FileHandler) ReadDocIdsArray ¶ added in v0.1.1
func (fh *FileHandler) ReadDocIdsArray(start, len int64) []int64
ReadDocIdsArray 从start下标读取len个int64
func (*FileHandler) ReadInt64 ¶
func (fh *FileHandler) ReadInt64(start int64) int64
ReadInt64 从指定的位置读取一个int64
func (*FileHandler) WriteInt64 ¶
func (fh *FileHandler) WriteInt64(value, start int64) int64
WriteInt64 指定的地方写入int64,不传就获取文件最后的下标
Click to show internal directories.
Click to hide internal directories.