Documentation ¶
Index ¶
- type EventData
- type Notifier
- func (n *Notifier) IsStarted() bool
- func (n *Notifier) IsStopped() bool
- func (n *Notifier) OnError(callback OnError) *Notifier
- func (n *Notifier) Remove(path string) *Notifier
- func (n *Notifier) Start() *Notifier
- func (n *Notifier) Stop() *Notifier
- func (n *Notifier) Watch(path string, watchConfig WatchConfig) *Notifier
- type OnError
- type Op
- type WatchCallback
- type WatchConfig
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type EventData ¶
type EventData struct { // This is the path where it happened! Path string // This is the time when happened the event Time time.Time // This is the filtered Name Name string // This is the operation that happened Op Op }
This is the Event structure when we receive from the watcher
type WatchCallback ¶
type WatchCallback func(e EventData)
type WatchConfig ¶
type WatchConfig struct { // This is the callback which should be called! Callback WatchCallback // What operations should listen on! Op []Op }
This is the structure when we send the configuration to the watcher!
Click to show internal directories.
Click to hide internal directories.