|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjava.util.concurrent.FutureTask<T>
com.bigdata.concurrent.FutureTaskMon<T>
com.bigdata.concurrent.NonBlockingLockManager.LockFutureTask<T>
T - The generic type of the outcome for the Future.protected class NonBlockingLockManager.LockFutureTask<T>
FutureTask which executes once it holds its locks.
| Constructor Summary | |
|---|---|
NonBlockingLockManager.LockFutureTask(R[] resource,
Callable<T> task,
long timeout,
int maxLockTries)
|
|
NonBlockingLockManager.LockFutureTask(R[] resources,
Runnable task,
T val,
long timeout,
int maxLockTries)
|
|
| Method Summary | |
|---|---|
boolean |
cancel(boolean mayInterruptIfRunning)
Extended signal NonBlockingLockManager.stateChanged when the
task completes and to track counters. |
long |
getLockLatency()
The elapsed nanoseconds the task waited to acquire its locks. |
long |
getLockTimeout()
The timeout (milliseconds) or ZERO (0L) for an infinite timeout. |
int |
getMaxLockTries()
The maximum #of times that the task will attempt to acquire its locks (positive integer). |
R[] |
getResource()
The resource(s) that are pre-declared by the task. |
protected boolean |
isTimeout()
True if the lockTimeout has expired when measured against
now. |
void |
run()
Extended signal NonBlockingLockManager.stateChanged when the
task completes and to track counters. |
protected void |
setException(Throwable t)
Extended signal NonBlockingLockManager.stateChanged when the
task completes, to track counters, and also exposed to the outer
class. |
String |
toString()
|
| Methods inherited from class java.util.concurrent.FutureTask |
|---|
done, get, get, isCancelled, isDone, runAndReset, set |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public NonBlockingLockManager.LockFutureTask(R[] resource,
Callable<T> task,
long timeout,
int maxLockTries)
public NonBlockingLockManager.LockFutureTask(R[] resources,
Runnable task,
T val,
long timeout,
int maxLockTries)
| Method Detail |
|---|
protected boolean isTimeout()
lockTimeout has expired when measured against
now.
public String toString()
toString in class Objectpublic R[] getResource()
#call()
will ensure that the task as a lock on these resources before it
invokes run() to execution the task.
public long getLockLatency()
public int getMaxLockTries()
public long getLockTimeout()
protected void setException(Throwable t)
NonBlockingLockManager.stateChanged when the
task completes, to track counters, and also exposed to the outer
class.
setException in class FutureTask<T>public boolean cancel(boolean mayInterruptIfRunning)
NonBlockingLockManager.stateChanged when the
task completes and to track counters.
cancel in interface Future<T>cancel in class FutureTaskMon<T>public void run()
NonBlockingLockManager.stateChanged when the
task completes and to track counters.
run in interface Runnablerun in interface RunnableFuture<T>run in class FutureTaskMon<T>
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||