Documentation ¶
Index ¶
- Constants
- func IterateInParallel(items []interface{}, iterator func(order interface{}))
- func NewAsyncBuffer(executionCallback func([]interface{}), config ...int) *asyncBuffer
- func NewFlag() system.Flag
- func Parallel(functions ...func())
- func StartSingleThreadScheduledExecutor()
- type IAsyncTask
- type IAsyncTaskPool
Constants ¶
View Source
const ( DefaultBufferSize = 10000 DefaultAutoFlushTimeout = 5 * time.Second )
Variables ¶
This section is empty.
Functions ¶
func IterateInParallel ¶
func IterateInParallel(items []interface{}, iterator func(order interface{}))
func NewAsyncBuffer ¶
func NewAsyncBuffer(executionCallback func([]interface{}), config ...int) *asyncBuffer
func StartSingleThreadScheduledExecutor ¶
func StartSingleThreadScheduledExecutor()
Types ¶
type IAsyncTask ¶
type IAsyncTask interface {
Run()
}
func NewAsyncTask ¶
func NewAsyncTask(runnable func()) IAsyncTask
type IAsyncTaskPool ¶
type IAsyncTaskPool interface { Submit(tasks ...func()) IAsyncTaskPool Run() IAsyncTaskPool Join() }
func CreateAsyncTaskPool ¶
func CreateAsyncTaskPool(lockOSThread bool) IAsyncTaskPool
func NewAsyncTaskPool ¶
func NewAsyncTaskPool() IAsyncTaskPool
Click to show internal directories.
Click to hide internal directories.