timing

package
v0.17.0 Latest Latest
Warning

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

Go to latest
Published: Jul 7, 2023 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Collector

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

func NewDurationCollector

func NewDurationCollector(capacity int) *Collector

func (*Collector) Durations

func (d *Collector) Durations() []time.Duration

func (*Collector) Start

func (d *Collector) Start()

func (*Collector) Stop

func (d *Collector) Stop()

type Timer

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

Timer tracks the duration between invocations to Start and Stop.

func (*Timer) Elapsed

func (s *Timer) Elapsed() time.Duration

func (*Timer) Start

func (s *Timer) Start()

func (*Timer) Stop

func (s *Timer) Stop()

Jump to

Keyboard shortcuts

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