|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.atlassian.util.concurrent.AsyncCompleter.Builder
public static class AsyncCompleter.Builder
For creating instances of AsyncCompleter
.
Constructor Summary | |
---|---|
AsyncCompleter.Builder(Executor executor)
Create a Builder with the supplied Executor |
Method Summary | |
---|---|
AsyncCompleter |
build()
|
AsyncCompleter.Builder |
checkCompletionServiceFutureIdentity()
|
AsyncCompleter.Builder |
completionServiceFactory(AsyncCompleter.ExecutorCompletionServiceFactory completionServiceFactory)
|
AsyncCompleter.Builder |
handleExceptions(ExceptionPolicy policy)
|
AsyncCompleter.Builder |
ignoreExceptions()
Ignore exceptions thrown by any Callables , note will cause nulls
in the resulting iterable! |
AsyncCompleter |
limitParallelExecutionTo(int limit)
Create a AsyncCompleter that limits the number of jobs submitted
to the underlying executor to a hard limit. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public AsyncCompleter.Builder(@NotNull Executor executor)
executor
- Method Detail |
---|
public AsyncCompleter.Builder ignoreExceptions()
Callables
, note will cause nulls
in the resulting iterable!
public AsyncCompleter.Builder handleExceptions(ExceptionPolicy policy)
public AsyncCompleter.Builder completionServiceFactory(AsyncCompleter.ExecutorCompletionServiceFactory completionServiceFactory)
public AsyncCompleter.Builder checkCompletionServiceFutureIdentity()
public AsyncCompleter limitParallelExecutionTo(int limit)
AsyncCompleter
that limits the number of jobs submitted
to the underlying executor to a hard limit.
Note: this only makes sense if the underlying executor does not have a limit on the number of threads it will create, on the size of the queue submitted jobs will live in, or where the limit is much higher than this limit.
limit
- the number of parallel jobs to execute at any one timefor more discussion of how this limit is relevant
public AsyncCompleter build()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |