mirror of
https://github.com/yusing/godoxy.git
synced 2025-05-20 04:42:33 +02:00
17 lines
290 B
Go
17 lines
290 B
Go
package watcher
|
|
|
|
import (
|
|
"context"
|
|
|
|
E "github.com/yusing/go-proxy/internal/error"
|
|
)
|
|
|
|
type fileWatcher struct {
|
|
relPath string
|
|
eventCh chan Event
|
|
errCh chan E.Error
|
|
}
|
|
|
|
func (fw *fileWatcher) Events(ctx context.Context) (<-chan Event, <-chan E.Error) {
|
|
return fw.eventCh, fw.errCh
|
|
}
|