timespec

package
v8.7.0+incompatible Latest Latest
Warning

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

Go to latest
Published: Mar 10, 2020 License: MIT Imports: 6 Imported by: 4

Documentation

Index

Constants

View Source
const AFTER = 57363
View Source
const AM = 57355
View Source
const AT = 57353
View Source
const DAILY = 57349
View Source
const DAY = 57359
View Source
const EVERY = 57358
View Source
const FRIDAY = 57370
View Source
const FROM = 57352
View Source
const HALF = 57357
View Source
const HOUR = 57361
View Source
const HOURLY = 57348
View Source
const MINUTE = 57360
View Source
const MONDAY = 57366
View Source
const MONTHLY = 57351
View Source
const NUMBER = 57346
View Source
const ON = 57354
View Source
const ORDINAL = 57347
View Source
const PM = 57356
View Source
const QUARTER = 57362
View Source
const SATURDAY = 57371
View Source
const SUNDAY = 57365
View Source
const THURSDAY = 57369
View Source
const TIL = 57364
View Source
const TUESDAY = 57367
View Source
const WEDNESDAY = 57368
View Source
const WEEKLY = 57350

Variables

This section is empty.

Functions

func LexerForFile

func LexerForFile(filename string) *yyLex

func LexerForString

func LexerForString(s string) *yyLex

func Next

func Next(s string) (time.Time, error)

Types

type Interval

type Interval uint
const (
	Minutely Interval = iota
	Hourly
	Daily
	Weekly
	Monthly
)

type Spec

type Spec struct {
	Error error

	Interval    Interval
	TimeOfDay   int
	TimeOfHour  int
	DayOfWeek   time.Weekday
	DayOfMonth  int
	Week        int
	Cardinality float32
}

func Parse

func Parse(s string) (*Spec, error)

func (*Spec) KeepN

func (s *Spec) KeepN(days int) int

func (*Spec) Next

func (s *Spec) Next(t time.Time) (time.Time, error)

func (*Spec) String

func (s *Spec) String() string

Jump to

Keyboard shortcuts

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