Back to godoc.org

Package ticker

v0.0.0-...-7f75649
Latest Go to latest

The latest major version is .

Published: Jun 11, 2019 | Licenses: Apache-2.0 , Apache-2.0 | Module: github.com/bsed/trace

Index

type Task

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

Task 任务

type Ticker

type Ticker struct {
	sync.RWMutex
	// contains filtered or unexported fields
}

Ticker 定时器

type Tickers

type Tickers struct {
	sync.Mutex
	// contains filtered or unexported fields
}

Tickers 定时器集合

func NewTickers

func NewTickers(tickerNum int, tickerTime int64, l *zap.Logger) *Tickers

NewTickers ...

func (*Tickers) AddTask

func (t *Tickers) AddTask(id int64, channel chan bool)

AddTask 添加任务

func (*Tickers) NewID

func (t *Tickers) NewID() int64

NewID 申请ID

func (*Tickers) RemoveTask

func (t *Tickers) RemoveTask(id int64)

RemoveTask 添加任务

Package Files

Documentation was rendered with GOOS=linux and GOARCH=amd64.

Jump to identifier

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to identifier