sync

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Dec 4, 2019 License: Apache-2.0, MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewRWLock

func NewRWLock() *rwlock

func Test

func Test()

func Test1

func Test1()

func Test2

func Test2()

func Test3

func Test3()

func Test4

func Test4()

func Test5

func Test5()

Types

type Env

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

func NewEnv

func NewEnv() *Env

func (Env) Locker

func (e Env) Locker(notify chan<- struct{}) TestLocker

func (*Env) NewRunner

func (e *Env) NewRunner(name string, locker func(notify chan<- struct{}) TestLocker) *Runner

func (Env) RLocker

func (e Env) RLocker(notify chan<- struct{}) TestLocker

func (*Env) TestSeq

func (e *Env) TestSeq(name string, step ...func() error) bool

type Locker

type Locker interface {
	Lock()
	Unlock()
}

type RWLock

type RWLock interface {
	Locker
	RLock()
	RUnlock()

	TestAndLock() bool
	TestAndRLock() bool

	RLocker() TestLocker
}

type Runner

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

func (*Runner) Blocked

func (r *Runner) Blocked() error

func (*Runner) Locked

func (r *Runner) Locked() error

func (*Runner) NoLock

func (r *Runner) NoLock() error

func (*Runner) Step

func (r *Runner) Step() error

type TestLocker

type TestLocker interface {
	Locker
	TestAndLock() bool
}

Jump to

Keyboard shortcuts

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