Documentation
¶
Index ¶
Constants ¶
View Source
const (
DefaultMaxRoutineNum = 100
)
Variables ¶
View Source
var ErrorClosed = errors.New("pool is closed")
Functions ¶
This section is empty.
Types ¶
type RoutinePool ¶
type RoutinePool struct {
// contains filtered or unexported fields
}
func NewRoutinePool ¶
func NewRoutinePool(maxRoutineNum int) *RoutinePool
func (*RoutinePool) RunningNum ¶
func (p *RoutinePool) RunningNum() int32
func (*RoutinePool) Submit ¶
func (p *RoutinePool) Submit(task func()) (int, error)
func (*RoutinePool) WaitAndClose ¶
func (p *RoutinePool) WaitAndClose()
Click to show internal directories.
Click to hide internal directories.