Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Callback ¶
type Callback struct {
Func func()
Event JobEvent
}
Callback defines a function that is meant to be run each time the specified JobEvent occurs
type JobEvent ¶
type JobEvent int
JobEvent defines the kind of event upon which the PoolCallback is executed
type Pool ¶
type Pool struct {
// contains filtered or unexported fields
}
Pool defines a worker pool
func New ¶
New creates a new worker pool with a goroutine limit and a job function to execute on the incoming data
func (*Pool) RegisterCallback ¶
RegisterCallback registers a callback to be triggered by the pool
Click to show internal directories.
Click to hide internal directories.