util-go/time/scheduler/storage/storage.go

19 lines
389 B
Go
Raw Permalink Normal View History

2018-04-28 12:39:55 +00:00
package storage
type TaskAttribute struct {
Hash string
Name string
LastRun string
NextRun string
Duration string
IsRecurring string
Params string
}
// TaskStorage is the interface to implement when adding custom task storage.
type TaskStorage interface {
Add(*TaskAttribute) error
Fetch() ([]*TaskAttribute, error)
Remove(*TaskAttribute) error
}