concurrent

package
v1.1.0 Latest Latest
Warning

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

Go to latest
Published: May 31, 2019 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Concurrent

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

Concurrent for simple concurrency control

func New

func New(limit int) *Concurrent

New is used to initial a concurrent control object

func (*Concurrent) Add

func (c *Concurrent) Add(n int)

Add is used to add a task

func (*Concurrent) Done

func (c *Concurrent) Done()

Done is used to accomplish a task

func (*Concurrent) Wait

func (c *Concurrent) Wait()

Wait is used to wait for all tasks to be completed

Jump to

Keyboard shortcuts

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