blob: 7374bde6cce844c63660219040ea2d8c4c07a7a7 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
|
package cache
import (
"github.com/silvasur/petrific/objects"
"time"
)
type Cache interface {
PathUpdated(path string) (mtime time.Time, id objects.ObjectId, ok bool)
SetPathUpdated(path string, mtime time.Time, id objects.ObjectId)
}
type NopCache struct{}
func (NopCache) PathUpdated(_ string) (_ time.Time, _ objects.ObjectId, ok bool) {
ok = false
return
}
func (NopCache) SetPathUpdated(_ string, _ time.Time, _ objects.ObjectId) {}
|