public abstract class IterativeWorkerTaskFactory<T> extends Object implements ExecutorServices.TaskFactory<Void>
| Constructor and Description |
|---|
IterativeWorkerTaskFactory(Iterable<? extends T> iterable) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
cleanup()
Called after the computation finishes.
|
List<Callable<Void>> |
createTasks(int threadPoolSize)
Creates a list of tasks to be executed in a thread pool.
|
protected abstract void |
doWork(T item) |
Queue<T> |
getQueue() |
protected void |
init()
Called before the compilation begins.
|
public List<Callable<Void>> createTasks(int threadPoolSize)
ExecutorServices.TaskFactorycreateTasks in interface ExecutorServices.TaskFactory<Void>threadPoolSize - the size of the underlying thread poolprotected void init()
protected void cleanup()
protected abstract void doWork(T item)
Copyright © 2013 Seam Framework. All Rights Reserved.