com.hammurapi.util.concurrent
Class OneOffCallable<T>
java.lang.Object
com.hammurapi.util.concurrent.OneOffCallable<T>
- Type Parameters:
T -
- All Implemented Interfaces:
- Callable<T>
public abstract class OneOffCallable<T>
- extends Object
- implements Callable<T>
Callable which callInternal() method is invoked only once.
- Author:
- Pavel Vlasov
|
Method Summary |
T |
call()
|
protected abstract T |
callInternal()
This method is invoked once by the call() method. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
OneOffCallable
public OneOffCallable()
call
public T call()
throws Exception
- Specified by:
call in interface Callable<T>
- Throws:
Exception
callInternal
protected abstract T callInternal()
throws Exception
- This method is invoked once by the call() method.
- Returns:
-
- Throws:
Exception