watcher

package
v0.0.0-...-3244a0f Latest Latest
Warning

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

Go to latest
Published: Mar 27, 2014 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Event

type Event struct {
	Name string
	// contains filtered or unexported fields
}

This is a stupid file modification watcher, I expect to use fsnotify once it becomes consistent among all platforms.

func (*Event) IsModify

func (self *Event) IsModify() bool

type Watcher

type Watcher struct {
	Files map[string]*WatcherFile
	Event chan (*Event)
	// contains filtered or unexported fields
}

func New

func New() (*Watcher, error)

func (*Watcher) Close

func (self *Watcher) Close()

func (*Watcher) RemoveWatch

func (self *Watcher) RemoveWatch(file string) error

func (*Watcher) Watch

func (self *Watcher) Watch(file string) error

type WatcherFile

type WatcherFile struct {
	Filemtime time.Time
}

Jump to

Keyboard shortcuts

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