Class ThreadEx<V>

java.lang.Object
java.lang.Thread
com.pnfsoftware.jeb.util.concurrent.ThreadEx<V>
Type Parameters:
V -
All Implemented Interfaces:
Runnable

public final class ThreadEx<V> extends Thread
An extension of Thread supporting the execution of Callable as well as Runnable. Two additional get() and get(timeout) methods, not unlike Future's get(), allow querying and waiting for the execution result. When executing a Runnable, get() will always return null. An exception occurring during the execution of the thread is collected and re-thrown inside an ExecutionException object.