R - the result typepublic interface GrizzlyFuture<R> extends Future<R>, Cacheable
Future implementation. Users can register additional CompletionHandlers using
addCompletionHandler(org.glassfish.grizzly.CompletionHandler) to be notified once the asynchronous
computation, represented by this Future, is complete.
A GrizzlyFuture instance can be recycled and reused.| Modifier and Type | Method and Description |
|---|---|
void |
addCompletionHandler(CompletionHandler<R> completionHandler)
Adds a
CompletionHandler, which will be notified once the asynchronous computation, represented by this
Future, is complete. |
void |
markForRecycle(boolean recycleResult)
Deprecated.
|
void |
recycle(boolean recycleResult)
Recycle GrizzlyFuture now.
|
void addCompletionHandler(CompletionHandler<R> completionHandler)
CompletionHandler, which will be notified once the asynchronous computation, represented by this
Future, is complete.completionHandler - CompletionHandler@Deprecated void markForRecycle(boolean recycleResult)
recycleResult - if true - the GrizzlyFuture result, if it support recyclable mechanism, will
be also recycled together with this GrizzlyFuture object.void recycle(boolean recycleResult)
recycleResult - if true - the GrizzlyFuture result, if it support recyclable mechanism, will
be also recycled together with this GrizzlyFuture object.Copyright © 2017–2020 Oracle Corporation. All rights reserved.