Interface Task
-
- All Known Implementing Classes:
AbstractTask,ContinuousQueryTask,CreateTask,DeleteTask,PartialQueryTask,QueryTask,ReadTask,UpdateTask
public interface TaskRepresents a Task which can be performed by a the implementation. Each task is intended to be self contained and should be intialised with enough state to be processed by the Task Processor.- See Also:
SeriesTaskExecutorThread
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidexecute(TokenStorageAdapter adapter)Perform the task.voidprocessError(DataLayerException error)Set the task error.
-
-
-
Method Detail
-
execute
void execute(TokenStorageAdapter adapter) throws DataLayerException
Perform the task.- Parameters:
adapter- Connection-coupled utility functions to perform the task with.- Throws:
DataLayerException- If there was a problem processing the task.
-
processError
void processError(DataLayerException error)
Set the task error. Used for setting the error response without executing the task. If the task can't be executed, this method is called.- Parameters:
error- the problem that happened before processing the task.
-
-