Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type FileWatcher ¶
type FileWatcher struct {
// contains filtered or unexported fields
}
FileWatcher the file fswatcher struct
func (*FileWatcher) AddHandler ¶
func (fw *FileWatcher) AddHandler(handler Handler) error
AddHandler add file fswatcher handler
func (*FileWatcher) AddWatch ¶
func (fw *FileWatcher) AddWatch(path string, subDir bool) error
AddWatch add path to watch path: the path to watch subDir: true to watch the sub directory; false to not watch the sub directory
func (*FileWatcher) RemoveWatch ¶
func (fw *FileWatcher) RemoveWatch(path string) error
RemoveWatch remove the path from fswatcher. And then, the system will stop watching the changes.
func (*FileWatcher) SetErrorHandler ¶
func (fw *FileWatcher) SetErrorHandler(h ErrorHandler)
SetErrorHandler set the fsnotify error handler
func (*FileWatcher) Stop ¶
func (fw *FileWatcher) Stop()
Click to show internal directories.
Click to hide internal directories.