task

package
v0.1.4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 21, 2026 License: AGPL-3.0 Imports: 9 Imported by: 0

Documentation

Overview

Package task

Index

Constants

This section is empty.

Variables

View Source
var Module = fx.Module(
	"task",
	fx.Provide(NewManager),
)

Functions

This section is empty.

Types

type Task

type Task struct {
	// contains filtered or unexported fields
}

type TaskManager

type TaskManager struct {
	// contains filtered or unexported fields
}

func NewManager

func NewManager(kv kv.KV) *TaskManager

func (*TaskManager) Add

func (manager *TaskManager) Add(name, spec string, f func() error) (*Task, error)

Add cron "秒 分 时 d日 m月 w周几 @...ly"

func (*TaskManager) MustAdd

func (manager *TaskManager) MustAdd(name, spec string, f func() error)

MustAdd cron "秒 分 时 d日 m月 w周几 @...ly"

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL