package fsnotify
Import Path
github.com/fsnotify/fsnotify (on go.dev)
Dependency Relation
imports 10 packages, and imported by one package
Involved Source Files
Package fsnotify provides a platform-independent interface for file system notifications.
inotify.go
inotify_poller.go
Package-Level Type Names (total 5, in which 3 are exported)
Event represents a single file system notification.
// Relative path to the file or directory.
// File operation that triggered the event.
String returns a string representation of the event in the form
"file: REMOVE|WRITE|..."
Certain types of events can be "ignored" and not sent over the Events
channel. Such as events marked ignore by the kernel, or MODIFY events
against files that do not exist.
T : fmt.Stringer
T : context.stringer
T : os/signal.stringer
T : runtime.stringer
func newEvent(name string, mask uint32) Event
Op describes a set of file operations.
( T) String() string
T : fmt.Stringer
T : context.stringer
T : os/signal.stringer
T : runtime.stringer
const Chmod
const Create
const Remove
const Rename
const Write
Watcher watches a set of files, delivering events to a channel.
Errors chan error
Events chan Event
// Channel for sending a "quit message" to the reader goroutine
// Channel to respond to Close
fd int
// Map access
// Map of watched paths (key: watch descriptor)
poller *fdPoller
// Map of inotify watches (key: path)
Add starts watching the named file or directory (non-recursively).
Close removes all watches and closes the events channel.
Remove stops watching the named file or directory (non-recursively).
(*T) isClosed() bool
readEvents reads from the inotify file descriptor, converts the
received events into Event objects and sends them via the Events channel
*T : io.Closer
func NewWatcher() (*Watcher, error)
func github.com/spf13/viper.newWatcher() (*viper.watcher, error)
Package-Level Functions (total 4, in which 1 are exported)
NewWatcher establishes a new watcher with the underlying OS and begins waiting for events.
Package-Level Variables (only one, which is exported)
Common errors that can be reported by a watcher
Package-Level Constants (total 5, all are exported)
These are the generalized file operations that can trigger a notification.
These are the generalized file operations that can trigger a notification.
These are the generalized file operations that can trigger a notification.
These are the generalized file operations that can trigger a notification.
These are the generalized file operations that can trigger a notification.
The pages are generated with Golds v0.3.2. (GOOS=linux GOARCH=amd64) Golds is a Go 101 project developed by Tapir Liu. PR and bug reports are welcome and can be submitted to the issue list. Please follow @Go100and1 (reachable from the left QR code) to get the latest news of Golds. |