timer

package
v1.1.3 Latest Latest
Warning

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

Go to latest
Published: Jul 18, 2023 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func After

func After(d time.Duration) <-chan time.Time

Types

type Timer

type Timer interface {
	Done() <-chan time.Time
	Stop()
	Reset(d time.Duration)
}

func AfterFunc

func AfterFunc(d time.Duration, f func()) Timer

func NewTimer

func NewTimer(d time.Duration) Timer

func NewWrapper

func NewWrapper(t *time.Timer) Timer

type Wrapper

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

Wrapper for time.Timer.

func (*Wrapper) Done

func (t *Wrapper) Done() <-chan time.Time

func (*Wrapper) Reset

func (t *Wrapper) Reset(d time.Duration)

func (*Wrapper) Stop

func (t *Wrapper) Stop()

Jump to

Keyboard shortcuts

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