Documentation
¶
Overview ¶
Package stopwatch is used to time things. Create a stopwatch with Start, then on success record the timing with Finish.
It's recommended you do not record errors, since they can have vastly different timings (maybe we add an Error method in the future and record a different event).
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type FinishOpts ¶
type LapOpts ¶
type LapOpts FinishOpts
type Stopwatch ¶
type Stopwatch struct {
// contains filtered or unexported fields
}
func (*Stopwatch) FinishWith ¶
func (sw *Stopwatch) FinishWith(ctx context.Context, opts FinishOpts)
Click to show internal directories.
Click to hide internal directories.