Documentation
¶
Overview ¶
* * @Author: xhzhang * @Date: 2019/9/24 13:39
Index ¶
- type CronClient
- func (c *CronClient) AddFunction(spec string, execFun func()) (cron.EntryID, error)
- func (c *CronClient) AddJob(spec string, job cron.Job) (cron.EntryID, error)
- func (c *CronClient) GetEntrys() []cron.Entry
- func (c *CronClient) RemoveJob(id cron.EntryID)
- func (c *CronClient) StartCron()
- func (c *CronClient) StopCron()
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CronClient ¶
type CronClient struct {
Client *cron.Cron
}
func NewCronClient ¶
func NewCronClient() CronClient
func (*CronClient) AddFunction ¶
func (c *CronClient) AddFunction(spec string, execFun func()) (cron.EntryID, error)
func (*CronClient) AddJob ¶
func (c *CronClient) AddJob(spec string, job cron.Job) (cron.EntryID, error)
func (*CronClient) GetEntrys ¶
func (c *CronClient) GetEntrys() []cron.Entry
func (*CronClient) RemoveJob ¶
func (c *CronClient) RemoveJob(id cron.EntryID)
func (*CronClient) StartCron ¶
func (c *CronClient) StartCron()
func (*CronClient) StopCron ¶
func (c *CronClient) StopCron()
Click to show internal directories.
Click to hide internal directories.