cronparser

package
v0.2.1 Latest Latest
Warning

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

Go to latest
Published: Aug 30, 2021 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Parser

type Parser struct {
	Timezone string
	SetTime  time.Time
	// contains filtered or unexported fields
}

func New

func New(p *Parser) Parser

New to create a new instance

func (*Parser) Parse

func (p *Parser) Parse(expr []string) (Schedule, error)

Parse to parsing cron format

func (*Parser) SetCurrentTime

func (p *Parser) SetCurrentTime(t time.Time) *Parser

type Schedule

type Schedule struct {
	// Next returns the next activation time, later than the given time.
	// Next is invoked initially, and then each time the job is run.
	Next time.Time
}

Schedule describes a job's duty cycle.

Jump to

Keyboard shortcuts

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