Class RetrieveQueue

java.lang.Object
org.gvsig.remoteclient.taskplanning.retrieving.RetrieveQueue
All Implemented Interfaces:
IQueue

public class RetrieveQueue extends Object implements IQueue
Author:
jaume dominguez faus - jaume.dominguez@iver.es Luis W. Sevilla (sevilla_lui@gva.es)
  • Constructor Details

    • RetrieveQueue

      public RetrieveQueue(String hName)
  • Method Details

    • put

      public IRunnableTask put(IRunnableTask task)
      Description copied from interface: IQueue
      Adds a new task to the queue. The place where the new task will be put its left to the concrete implementation of this interface.
      Specified by:
      put in interface IQueue
    • take

      public IRunnableTask take()
      Description copied from interface: IQueue
      Returns the next task by calling the task planner's nextTask() method.
      Specified by:
      take in interface IQueue
      Returns:
      IRunnableTask with the next task to be executed.
    • isEmpty

      public boolean isEmpty()
      Description copied from interface: IQueue
      Returns true if the Queue has no (more) jobs to do.
      Specified by:
      isEmpty in interface IQueue
      Returns:
    • getTaskPlanner

      public ITaskPlanner getTaskPlanner()
      Description copied from interface: IQueue
      Returns the task planner currently defined by this queue.
      Specified by:
      getTaskPlanner in interface IQueue
      Returns:
      ITaskPlanner
    • setTaskPlanner

      public void setTaskPlanner(ITaskPlanner planner)
      Description copied from interface: IQueue
      Sets the TaskPlanner that will decide which of the tasks in the queue will be executed next. A null value should represent a FIFO planner.
      Specified by:
      setTaskPlanner in interface IQueue
      Parameters:
      planner -
    • pause

      public void pause()
      Description copied from interface: IQueue
      Causes the execution of this queue to be paused. The task currently in execution finishes and after it the planner will not issue more tasks until resume() is invoked.
      Specified by:
      pause in interface IQueue
    • resume

      public void resume()
      Description copied from interface: IQueue
      Causes the execution of this queue to be resumed. The execution will continue with the next task issued by the planner. It has no effect if the queue was not paused yet.
      Specified by:
      resume in interface IQueue
    • getTasks

      public Vector getTasks()
      Description copied from interface: IQueue
      Returns the set of tasks in a Vector (thread-safe).
      Specified by:
      getTasks in interface IQueue
      Returns:
      Vector containing the tasks in this queue.
    • getURLPreviousRequest

      protected URLRetrieveTask getURLPreviousRequest(URLRequest request)