Example #1
0
func (s *Scheduler) Restart(jobs []*Job) {
	s.Cron.Stop()
	s.Cron = cron.New()
	s.Start(jobs)
}
Example #2
0
func NewScheduler() *Scheduler {
	c := cron.New()
	return &Scheduler{Cron: c, Started: false}
}