fsnotify

package
v2.5.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 9, 2022 License: Apache-2.0 Imports: 6 Imported by: 8

Documentation

Index

Constants

View Source
const (
	Create = fsnotify.Create
	Remove = fsnotify.Remove
	Rename = fsnotify.Rename
	Chmod  = fsnotify.Chmod
	Write  = fsnotify.Write
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Event

type Event = fsnotify.Event

type Watcher

type Watcher struct {
	// contains filtered or unexported fields
}

func NewWatcher

func NewWatcher() (*Watcher, error)

NewWatcher creates a new Watcher. It's allows to watch a single file or a directory multiple times.

func (*Watcher) Add

func (w *Watcher) Add(name string) error

func (*Watcher) AddOnEventHandler

func (w *Watcher) AddOnEventHandler(onEventHandler *func(event fsnotify.Event))

func (*Watcher) Close

func (w *Watcher) Close() error

func (*Watcher) Remove

func (w *Watcher) Remove(name string) error

func (*Watcher) RemoveOnEventHandler

func (w *Watcher) RemoveOnEventHandler(onEventHandler *func(event fsnotify.Event))

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL