Class TrustedListenableFutureTask.TrustedFutureInterruptibleAsyncTask
java.lang.Object
java.util.concurrent.atomic.AtomicReference<Runnable>
com.google.common.util.concurrent.InterruptibleTask<ListenableFuture<V>>
com.google.common.util.concurrent.TrustedListenableFutureTask.TrustedFutureInterruptibleAsyncTask
- All Implemented Interfaces:
Serializable
,Runnable
- Enclosing class:
TrustedListenableFutureTask<V>
private final class TrustedListenableFutureTask.TrustedFutureInterruptibleAsyncTask
extends InterruptibleTask<ListenableFuture<V>>
-
Nested Class Summary
Nested classes/interfaces inherited from class com.google.common.util.concurrent.InterruptibleTask
InterruptibleTask.Blocker
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription(package private) void
Any interruption that happens as a result of calling interruptTask will arrive before this method is called.(package private) void
Any interruption that happens as a result of calling interruptTask will arrive before this method is called.(package private) final boolean
isDone()
Called before runInterruptibly - if true, runInterruptibly and afterRanInterruptibly will not be called.(package private) ListenableFuture
<V> Do interruptible work here - do not complete Futures here, as their listeners could be interrupted.(package private) String
Methods inherited from class com.google.common.util.concurrent.InterruptibleTask
interruptTask, run, toString
Methods inherited from class java.util.concurrent.atomic.AtomicReference
accumulateAndGet, compareAndExchange, compareAndExchangeAcquire, compareAndExchangeRelease, compareAndSet, get, getAcquire, getAndAccumulate, getAndSet, getAndUpdate, getOpaque, getPlain, lazySet, set, setOpaque, setPlain, setRelease, updateAndGet, weakCompareAndSet, weakCompareAndSetAcquire, weakCompareAndSetPlain, weakCompareAndSetRelease, weakCompareAndSetVolatile
-
Field Details
-
callable
-
-
Constructor Details
-
TrustedFutureInterruptibleAsyncTask
TrustedFutureInterruptibleAsyncTask(AsyncCallable<V> callable)
-
-
Method Details
-
isDone
final boolean isDone()Description copied from class:InterruptibleTask
Called before runInterruptibly - if true, runInterruptibly and afterRanInterruptibly will not be called.- Specified by:
isDone
in classInterruptibleTask<ListenableFuture<V>>
-
runInterruptibly
Description copied from class:InterruptibleTask
Do interruptible work here - do not complete Futures here, as their listeners could be interrupted.- Specified by:
runInterruptibly
in classInterruptibleTask<ListenableFuture<V>>
- Throws:
Exception
-
afterRanInterruptiblySuccess
Description copied from class:InterruptibleTask
Any interruption that happens as a result of calling interruptTask will arrive before this method is called. Complete Futures here.- Specified by:
afterRanInterruptiblySuccess
in classInterruptibleTask<ListenableFuture<V>>
-
afterRanInterruptiblyFailure
Description copied from class:InterruptibleTask
Any interruption that happens as a result of calling interruptTask will arrive before this method is called. Complete Futures here.- Specified by:
afterRanInterruptiblyFailure
in classInterruptibleTask<ListenableFuture<V>>
-
toPendingString
String toPendingString()- Specified by:
toPendingString
in classInterruptibleTask<ListenableFuture<V>>
-