|
SMILA (incubation) API documentation | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.eclipse.smila.processing.worker.ProcessingWorker
public abstract class ProcessingWorker
Common stuff for PipeletProcessorWorker and PipelineProcessorWorker.
| Field Summary | |
|---|---|
protected BlackboardFactory |
_blackboardFactory
blackboard factory. |
protected Log |
_log
protected log. |
protected boolean |
_tryToUseBinStorage
use bin storage? |
static java.lang.String |
INPUT_SLOT_NAME
the workers input slot name . |
static java.lang.String |
OUTPUT_SLOT_NAME
the workers output slot name . |
protected static boolean |
s_noBinStorageAvailableLogged
flag if the blackboard warning has already been logged to prevent excessive logging. |
| Constructor Summary | |
|---|---|
ProcessingWorker()
|
|
| Method Summary | |
|---|---|
protected Blackboard |
getBlackboard()
Creates a blackboard. |
abstract boolean |
perform(AnyMap parameters,
RecordInput recordInput,
RecordOutput recordOutput,
TaskContext taskContext)
|
void |
perform(TaskContext taskContext)
Performs a computation on the data available in the TaskContext, such as a task for this worker, input and
(if configured) output slots. |
void |
setBlackboardFactory(BlackboardFactory factory)
set blackboard factory reference (used by DS). |
void |
unsetBlackboardFactory(BlackboardFactory factory)
remove blackboard factory reference (used by DS). |
protected void |
writeResultRecords(Blackboard blackboard,
java.lang.String[] resultIds,
RecordOutput recordOutput,
TaskLog taskLog)
append the resulting records to the bulk. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface org.eclipse.smila.taskworker.Worker |
|---|
getName |
| Field Detail |
|---|
public static final java.lang.String INPUT_SLOT_NAME
public static final java.lang.String OUTPUT_SLOT_NAME
protected static boolean s_noBinStorageAvailableLogged
protected final Log _log
protected BlackboardFactory _blackboardFactory
protected boolean _tryToUseBinStorage
| Constructor Detail |
|---|
public ProcessingWorker()
| Method Detail |
|---|
public void perform(TaskContext taskContext)
throws java.lang.Exception
WorkerTaskContext, such as a task for this worker, input and
(if configured) output slots. An implementor must make sure, calls to this method must be thread-safe!
perform in interface WorkertaskContext - the TaskContext information with which this operation can be performed.
java.lang.Exception
public abstract boolean perform(AnyMap parameters,
RecordInput recordInput,
RecordOutput recordOutput,
TaskContext taskContext)
throws java.lang.Exception
parameters - task parameters, converted to an AnyMaprecordInput - input bulkrecordOutput - output bulk, can be nulltaskContext - task context
java.lang.Exception - bulk could not be processed
protected void writeResultRecords(Blackboard blackboard,
java.lang.String[] resultIds,
RecordOutput recordOutput,
TaskLog taskLog)
throws ObjectStoreException,
java.io.IOException
recordOutput - where to write the records. Can be null (is optional in worker description)
ObjectStoreException
java.io.IOException
protected Blackboard getBlackboard()
throws java.lang.Exception
java.lang.Exceptionpublic void setBlackboardFactory(BlackboardFactory factory)
public void unsetBlackboardFactory(BlackboardFactory factory)
|
SMILA (incubation) API documentation | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||