public class Tuple2Future<E,F> extends IntermediateFuture<TupleResult> implements ITuple2Future<E,F>
IForwardCommandFuture.Type
DEBUG, EMPTY, NO_STACK_COMPACTION, STACK
DONE
Constructor and Description |
---|
Tuple2Future()
Create a future that is already done.
|
Tuple2Future(E result1,
F result2)
Create a future that is already done.
|
Tuple2Future(Exception exception)
Create a future that is already done (failed).
|
Modifier and Type | Method and Description |
---|---|
E |
getFirstResult()
Get the first result.
|
E |
getFirstResult(ISuspendable caller)
Get the first result.
|
F |
getSecondResult()
Get the second result.
|
F |
getSecondResult(ISuspendable caller)
Get the second result.
|
void |
setFirstResult(E result)
Set the result.
|
void |
setSecondResult(F result)
Set the result.
|
addIntermediateResult, addIntermediateResultIfUndone, addResultListener, getIntermediateResults, getNextIntermediateResult, getNextIntermediateResult, hasNextIntermediateResult, setFinished, setFinishedIfUndone, setResult, setResultIfUndone
abortGet, addForwardCommand, get, get, get, get, getEmptyFuture, getException, isDone, removeForwardCommand, sendForwardCommand, setException, setExceptionIfUndone
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getIntermediateResults, getNextIntermediateResult, hasNextIntermediateResult
addResultListener, get, get, get, get, getException, isDone
public Tuple2Future()
result
- The result, if any.public Tuple2Future(E result1, F result2)
result
- The result, if any.public Tuple2Future(Exception exception)
exception
- The exception.public E getFirstResult()
getFirstResult
in interface ITuple2Future<E,F>
NoSuchElementException,
- when there are no more intermediate results and the future is finished.public E getFirstResult(ISuspendable caller)
getFirstResult
in interface ITuple2Future<E,F>
NoSuchElementException,
- when there are no more intermediate results and the future is finished.public F getSecondResult()
getSecondResult
in interface ITuple2Future<E,F>
NoSuchElementException,
- when there are no more intermediate results and the future is finished.public F getSecondResult(ISuspendable caller)
getSecondResult
in interface ITuple2Future<E,F>
NoSuchElementException,
- when there are no more intermediate results and the future is finished.public void setFirstResult(E result)
result
- The result.public void setSecondResult(F result)
result
- The result.Copyright © 2013. All Rights Reserved.