cron

package
v0.0.0-...-50a2d83 Latest Latest
Warning

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

Go to latest
Published: Mar 1, 2023 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Cron

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

func New

func New(movements []dsd.PtzAutoMovement) (*Cron, error)

func (*Cron) Default

func (c *Cron) Default() error

func (*Cron) InfoCh

func (c *Cron) InfoCh() <-chan ScheduleInfo

func (*Cron) List

func (c *Cron) List() []dsd.PtzAutoMovement

func (*Cron) Quit

func (c *Cron) Quit()

func (*Cron) QuitCh

func (c *Cron) QuitCh() <-chan struct{}

func (*Cron) Run

func (c *Cron) Run()

func (*Cron) Set

func (c *Cron) Set(movement *dsd.PtzAutoMovement) error

func (*Cron) Start

func (c *Cron) Start()

func (*Cron) Stop

func (c *Cron) Stop()

type Function

type Function int

Function 定时功能

const (
	None       Function = iota // None
	Preset                     // 预置点
	Cruise                     // 巡航
	Trace                      // 巡迹
	LineScan                   // 线性扫描
	RegionScan                 // 区域扫描
)

func (Function) Validate

func (f Function) Validate() error

type ScheduleInfo

type ScheduleInfo struct {
	CronID   int
	Function Function
	FuncID   int
	// contains filtered or unexported fields
}

Jump to

Keyboard shortcuts

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