org.teiid.dqp.internal.process
Class DQPCore.FutureWork<T>

java.lang.Object
  extended by java.util.concurrent.FutureTask<T>
      extended by org.teiid.dqp.internal.process.DQPCore.FutureWork<T>
All Implemented Interfaces:
java.lang.Runnable, java.util.concurrent.Future<T>, java.util.concurrent.RunnableFuture<T>, javax.resource.spi.work.Work, ThreadReuseExecutor.PrioritizedRunnable
Enclosing class:
DQPCore

public static final class DQPCore.FutureWork<T>
extends java.util.concurrent.FutureTask<T>
implements ThreadReuseExecutor.PrioritizedRunnable, javax.resource.spi.work.Work


Field Summary
 
Fields inherited from interface org.teiid.dqp.internal.process.ThreadReuseExecutor.PrioritizedRunnable
NO_WAIT_PRIORITY
 
Constructor Summary
DQPCore.FutureWork(java.util.concurrent.Callable<T> processor, int priority)
           
DQPCore.FutureWork(java.lang.Runnable processor, T result, int priority)
           
 
Method Summary
protected  void done()
           
 long getCreationTime()
           
 DQPWorkContext getDqpWorkContext()
           
 int getPriority()
           
 void release()
           
 void run()
           
 
Methods inherited from class java.util.concurrent.FutureTask
cancel, get, get, isCancelled, isDone, runAndReset, set, setException
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DQPCore.FutureWork

public DQPCore.FutureWork(java.util.concurrent.Callable<T> processor,
                          int priority)

DQPCore.FutureWork

public DQPCore.FutureWork(java.lang.Runnable processor,
                          T result,
                          int priority)
Method Detail

run

public void run()
Specified by:
run in interface java.lang.Runnable
Specified by:
run in interface java.util.concurrent.RunnableFuture<T>
Overrides:
run in class java.util.concurrent.FutureTask<T>

getPriority

public int getPriority()
Specified by:
getPriority in interface ThreadReuseExecutor.PrioritizedRunnable

getCreationTime

public long getCreationTime()
Specified by:
getCreationTime in interface ThreadReuseExecutor.PrioritizedRunnable

getDqpWorkContext

public DQPWorkContext getDqpWorkContext()
Specified by:
getDqpWorkContext in interface ThreadReuseExecutor.PrioritizedRunnable

release

public void release()
Specified by:
release in interface javax.resource.spi.work.Work

done

protected void done()
Overrides:
done in class java.util.concurrent.FutureTask<T>


Copyright © 2011. All Rights Reserved.