protected class MultiLockFairBlockingQueue.ItemFuture<T> extends Object implements Future<T>
Modifier and Type | Field and Description |
---|---|
protected boolean |
canceled |
protected T |
item |
protected MultiLockFairBlockingQueue.ExchangeCountDownLatch<T> |
latch |
Constructor and Description |
---|
ItemFuture(MultiLockFairBlockingQueue.ExchangeCountDownLatch<T> latch) |
ItemFuture(T item) |
Modifier and Type | Method and Description |
---|---|
boolean |
cancel(boolean mayInterruptIfRunning) |
T |
get() |
T |
get(long timeout,
TimeUnit unit) |
boolean |
isCancelled() |
boolean |
isDone() |
protected volatile T item
protected volatile MultiLockFairBlockingQueue.ExchangeCountDownLatch<T> latch
protected volatile boolean canceled
public ItemFuture(T item)
public ItemFuture(MultiLockFairBlockingQueue.ExchangeCountDownLatch<T> latch)
public boolean cancel(boolean mayInterruptIfRunning)
public T get() throws InterruptedException, ExecutionException
get
in interface Future<T>
InterruptedException
ExecutionException
public T get(long timeout, TimeUnit unit) throws InterruptedException, ExecutionException, TimeoutException
get
in interface Future<T>
InterruptedException
ExecutionException
TimeoutException
public boolean isCancelled()
isCancelled
in interface Future<T>
Copyright © 2000-2016 Apache Software Foundation. All Rights Reserved.