public class InlineListenableFuture extends Object implements ListenableFuture<Object>
Constructor and Description |
---|
InlineListenableFuture() |
Modifier and Type | Method and Description |
---|---|
void |
addListener(Runnable listener)
register a listener to be run on completion or immediately if complete
any exceptions will be caught and logged
|
Object |
call() |
boolean |
cancel(boolean mayInterruptIfRunning) |
Object |
get() |
Object |
get(long timeout,
TimeUnit unit) |
boolean |
isCancelled() |
boolean |
isDone() |
public InlineListenableFuture()
public void addListener(Runnable listener)
ListenableFuture
addListener
in interface ListenableFuture<Object>
public boolean cancel(boolean mayInterruptIfRunning)
public boolean isCancelled()
isCancelled
in interface Future<Object>
public Object get() throws InterruptedException, ExecutionException
get
in interface Future<Object>
InterruptedException
ExecutionException
public Object get(long timeout, TimeUnit unit) throws InterruptedException, ExecutionException, TimeoutException
get
in interface Future<Object>
InterruptedException
ExecutionException
TimeoutException
Copyright © 2005–2020 FuseSource, Corp.. All rights reserved.