edu.rice.cs.plt.concurrent
Class TaskController.State

java.lang.Object
  extended by edu.rice.cs.plt.concurrent.TaskController.State
Direct Known Subclasses:
TaskController.CanceledState, TaskController.ComputingState, TaskController.FinishedState, TaskController.WaitingState
Enclosing class:
TaskController<R>

protected abstract class TaskController.State
extends Object

An internal state for the controller, implementing the controller's core behavior.


Constructor Summary
protected TaskController.State()
           
 
Method Summary
abstract  boolean cancel(boolean stopRunning)
           
abstract  R get()
           
abstract  R get(long timeout, TimeUnit u)
           
abstract  void start()
           
abstract  TaskController.Status status()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TaskController.State

protected TaskController.State()
Method Detail

status

public abstract TaskController.Status status()

start

public abstract void start()

cancel

public abstract boolean cancel(boolean stopRunning)

get

public abstract R get()
               throws InterruptedException,
                      ExecutionException
Throws:
InterruptedException
ExecutionException

get

public abstract R get(long timeout,
                      TimeUnit u)
               throws InterruptedException,
                      ExecutionException,
                      TimeoutException
Throws:
InterruptedException
ExecutionException
TimeoutException