Documentation
¶
Index ¶
- func AddDurationFunc(cmd func(), duration time.Duration) (cron.EntryID, error)
- func AddEveryDayFunc(cmd func(), hour, minutes, seconds int) (cron.EntryID, error)
- func AddEveryHourFunc(cmd func(), minute, second int) (cron.EntryID, error)
- func AddFunc(spec string, cmd func()) (cron.EntryID, error)
- func AddJob(spec string, cmd cron.Job) (cron.EntryID, error)
- func Entries() []cron.Entry
- func Entry(id cron.EntryID) cron.Entry
- func Init(opts ...cron.Option)
- func Location() *time.Location
- func RegisterComponent(opts ...cron.Option)
- func Remove(id cron.EntryID)
- func Run()
- func Schedule(schedule cron.Schedule, cmd cron.Job) cron.EntryID
- func Start()
- func Stop()
- type CronLogger
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AddDurationFunc ¶ added in v1.1.26
AddDurationFunc 每间隔x秒执行一次
func AddEveryDayFunc ¶
AddEveryDayFunc 每天的x时x分x秒执行一次(每天1次)
func AddEveryHourFunc ¶
AddEveryHourFunc 每小时的x分x秒执行一次(每天24次)
func RegisterComponent ¶
Types ¶
type CronLogger ¶
type CronLogger struct{}
func (CronLogger) Error ¶
func (CronLogger) Error(err error, _ string, _ ...interface{})
func (CronLogger) Info ¶
func (CronLogger) Info(msg string, keysAndValues ...interface{})
Click to show internal directories.
Click to hide internal directories.