Documentation
¶
Index ¶
- func CleanPathContent(dirPath string)
- func CopyPath(srcPath, dstPath string) error
- func Exist(path string) bool
- func IsDir(path string) bool
- func IsDirEmpty(dirPath string) (bool, error)
- func IsSubPath(topPath, subPath string) bool
- func ListPath(filePath string, filterPattern string, recursive bool) ([]string, error)
- func SplitParentDir(dirPath string) string
- func WalkPath(filePath string) ([]string, error)
- type Event
- type Monitor
- func (s *Monitor) AddIgnore(ignores fu.StringSet)
- func (s *Monitor) AddObserver(observer Observer)
- func (s *Monitor) AddPath(path string) error
- func (s *Monitor) RemoveObserver(observer Observer)
- func (s *Monitor) RemovePath(path string) error
- func (s *Monitor) Start() error
- func (s *Monitor) Stop() error
- type Observer
- type Op
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CleanPathContent ¶ added in v1.4.0
func CleanPathContent(dirPath string)
func CopyPath ¶ added in v1.4.0
CopyPath 深度复制目录结构及内容 特性: - 保留文件权限和修改时间 - 并行文件复制(最大4并发) - 自动创建目标目录 - 完善的错误处理链
func IsDirEmpty ¶ added in v1.3.65
IsDirEmpty 判断目录是否为空
func SplitParentDir ¶ added in v1.3.67
Types ¶
type Monitor ¶ added in v1.4.5
type Monitor struct {
// contains filtered or unexported fields
}
监控指定目录及其子目录下的文件变化 包括新增、删除和修改
func (*Monitor) AddObserver ¶ added in v1.4.5
func (*Monitor) RemoveObserver ¶ added in v1.4.5
func (*Monitor) RemovePath ¶ added in v1.4.5
Click to show internal directories.
Click to hide internal directories.