cpumutex

package
v0.0.0-...-5d70bd9 Latest Latest
Warning

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

Go to latest
Published: Mar 22, 2021 License: BSD-3-Clause Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type M

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

A mutex for limit the number of parralelism process. Zero value is valid.

func (*M) Init

func (m *M) Init(max int)

Init m, if max is less 0, max will be the number of CPU.

func (*M) Lock

func (m *M) Lock()

func (*M) Unlock

func (m *M) Unlock()

Jump to

Keyboard shortcuts

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