spinlock

package
v0.0.0-...-eb12069 Latest Latest
Warning

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

Go to latest
Published: Jul 5, 2023 License: BSD-3-Clause Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrTimedOut = errors.New("timed out waiting for condition")

Functions

func Wait

func Wait(timeoutDur time.Duration, cond func() bool) error

Wait blocks execution until condition is satisfied or until it times out.

func WaitWithInterval

func WaitWithInterval(timeoutDur, checkIntervalDur time.Duration, cond func() bool) error

WaitWithInterval blocks execution until condition is satisfied or until it times out. Condition is checked on specified checkIntervalDur.

Types

This section is empty.

Jump to

Keyboard shortcuts

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