Package jadex.future
Interface ITuple2Future<E,F>
- All Superinterfaces:
IFuture<Collection<TupleResult>>
,IIntermediateFuture<TupleResult>
,Supplier<Collection<TupleResult>>
- All Known Implementing Classes:
Tuple2Future
A tuple future has a defined number of results of possibly different types.
The future is considered as finished when all tuple elements have been set.
-
Field Summary
Fields inherited from interface jadex.future.IIntermediateFuture
DONE
-
Method Summary
Modifier and TypeMethodDescriptionGet the first result.getFirstResult
(long timeout) Get the first result.getFirstResult
(long timeout, boolean realtime) Get the first result.Deprecated.- From 3.0.Get the second result.getSecondResult
(long timeout) Get the second result.getSecondResult
(long timeout, boolean realtime) Get the second result.Methods inherited from interface jadex.future.IFuture
addResultListener, catchEx, catchEx, catchEx, delegate, delegateTo, get, get, get, get, get, getException, isDone, printOnEx, then, thenApply, thenApply, thenCompose, thenCompose
Methods inherited from interface jadex.future.IIntermediateFuture
asStream, asStream, done, finished, getIntermediateResults, getNextIntermediateResult, getNextIntermediateResult, hasNextIntermediateResult, hasNextIntermediateResult, max, next
-
Method Details
-
getFirstResult
Deprecated.- From 3.0. Use method without suspendable. Get the first result.- Returns:
- The next intermediate result.
- Throws:
NoSuchElementException
- when there are no more intermediate results and the future is finished.
-
getFirstResult
E getFirstResult()Get the first result.- Returns:
- The next intermediate result.
- Throws:
NoSuchElementException
- when there are no more intermediate results and the future is finished.
-
getSecondResult
F getSecondResult()Get the second result.- Returns:
- The next intermediate result.
- Throws:
NoSuchElementException
- when there are no more intermediate results and the future is finished.
-
getFirstResult
Get the first result.- Parameters:
timeout
- The timeout in millis.- Returns:
- The next intermediate result.
- Throws:
NoSuchElementException
- when there are no more intermediate results and the future is finished.
-
getSecondResult
Get the second result.- Parameters:
timeout
- The timeout in millis.- Returns:
- The next intermediate result.
- Throws:
NoSuchElementException
- when there are no more intermediate results and the future is finished.
-
getFirstResult
Get the first result.- Parameters:
timeout
- The timeout in millis.realtime
- Flag if wait should be realtime (in contrast to simulation time).- Returns:
- The next intermediate result.
- Throws:
NoSuchElementException
- when there are no more intermediate results and the future is finished.
-
getSecondResult
Get the second result.- Parameters:
timeout
- The timeout in millis.realtime
- Flag if wait should be realtime (in contrast to simulation time).- Returns:
- The next intermediate result.
- Throws:
NoSuchElementException
- when there are no more intermediate results and the future is finished.
-