Documentation ¶
Index ¶
Constants ¶
View Source
const ( CREATE = 0 MODIFY = 1 DELETE = 2 )
Variables ¶
This section is empty.
Functions ¶
func CreateLocalStateChange ¶
func CreateLocalStateChange(path string, eventType int) (change structs.StateChange, err error)
func Subfolders ¶
Subfolders returns a slice of subfolders (recursive), including the folder provided.
Types ¶
type RecursiveWatcher ¶
type RecursiveWatcher struct { *fsnotify.Watcher Files chan structs.StateChange Folders chan string }
func NewRecursiveWatcher ¶
func NewRecursiveWatcher(path string) (*RecursiveWatcher, error)
func (*RecursiveWatcher) AddFolder ¶
func (watcher *RecursiveWatcher) AddFolder(folder string)
func (*RecursiveWatcher) Run ¶
func (watcher *RecursiveWatcher) Run(initScanDone <-chan struct{}, debug bool)
Click to show internal directories.
Click to hide internal directories.