org.javasimon.callback.async
Class Executors.AsyncCallbackExecutor<T>
java.lang.Object
org.javasimon.callback.async.Executors.AsyncCallbackExecutor<T>
- All Implemented Interfaces:
- Executor<T>
- Enclosing class:
- Executors
private static class Executors.AsyncCallbackExecutor<T>
- extends Object
- implements Executor<T>
Asynchronous, different thread executor
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
executorService
private final ExecutorService executorService
- Used executor service
Executors.AsyncCallbackExecutor
public Executors.AsyncCallbackExecutor(ExecutorService executorService)
execute
public T execute(Callable<T> callable)
throws Throwable
- Description copied from interface:
Executor
- Main method of the executor
- Specified by:
execute in interface Executor<T>
- Parameters:
callable - Piece of code to execute
- Returns:
- Result of the execution
- Throws:
Throwable - Raised when execution failed
Copyright © 2013. All Rights Reserved.