ini.trakem2.parallel
Class TaskFactory<I,O>

java.lang.Object
  extended by ini.trakem2.parallel.TaskFactory<I,O>

public abstract class TaskFactory<I,O>
extends java.lang.Object


Constructor Summary
TaskFactory()
           
 
Method Summary
 java.util.concurrent.Callable<O> create(I input)
          Generates a Callable task for an ExecutorService to process @param input.
 O process(I input)
          The actual processing on the given @param input; override to define a task to be performed over @param input.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TaskFactory

public TaskFactory()
Method Detail

create

public java.util.concurrent.Callable<O> create(I input)
Generates a Callable task for an ExecutorService to process @param input. Unless overriden, will simply call process(input);


process

public O process(I input)
The actual processing on the given @param input; override to define a task to be performed over @param input. By default does nothing and returns null.