org.gvsig.remoteclient.taskplanning
Interface ITaskPlanner

All Known Implementing Classes:
FIFOTaskPlanner

public interface ITaskPlanner

ITaskPlanner provides an interface to program your own task planning. It gives you operations for pick a task from the queue according on the criteria that you designed.

The simplest implementation of ITaskPlanner would be a FIFO task planner (see FIFOTaskPlanner.java) which takes jobs from a task queue in the same order they were put. But any kind of planner is possible (SJF, LIFO, RoundRobin, etc.).

Author:
jaume dominguez faus - jaume.dominguez@iver.es

Method Summary
 IRunnableTask nextTask()
          Takes the next task to be executed.
 IRunnableTask previousTask()
          Deprecated. (probably this is unuseful and i'll remove it)
 

Method Detail

nextTask

IRunnableTask nextTask()
Takes the next task to be executed.

Returns:
IRunnableTask representing the next task to be executed

previousTask

IRunnableTask previousTask()
Deprecated. (probably this is unuseful and i'll remove it)

Takes the previous executed task. Notice that it may or may not have sense for specific implementations. For example, in a FIFO-like planner, the task is taken from the queue, executed until it is finished and removed from the queue. So, there is no previous task.

Returns:
IRunnableTask representing the previous executed task, or null if none.


Copyright © 2004-2013 gvSIG. All Rights Reserved.