27package org.jau.util.parallel;
29import java.io.PrintStream;
31import org.jau.lang.InterruptSource;
32import org.jau.lang.InterruptedRuntimeException;
66 final boolean waitUntilDone,
final Runnable
runnable) {
68 if( !waitUntilDone ) {
73 final Object sync =
new Object();
81 }
catch (
final InterruptedException ie) {
86 throw new RuntimeException(throwable);
121 tStarted = System.currentTimeMillis();
125 }
catch (
final Throwable t) {
143 }
catch (
final Throwable t) {
java.lang.Thread specialization implementing InterruptSource to track java.lang.Thread#interrupt() ca...
static Thread create(final ThreadGroup tg, final Runnable target, final String name)
Depending on whether name is null, either Thread(ThreadGroup, Runnable, String) or Thread(ThreadGroup...
Unchecked exception propagating an InterruptedException where handling of the latter is not desired.
Helper class to provide a Runnable queue implementation with a Runnable wrapper which notifies after ...
static RunnableTask invokeOnCurrentThread(final Runnable runnable)
Invokes runnable on the current Thread.
static RunnableTask invokeOnNewThread(final ThreadGroup tg, final String threadName, final boolean waitUntilDone, final Runnable runnable)
Invokes runnable on a new InterruptSource.Thread, see InterruptSource.Thread#Thread(ThreadGroup,...
RunnableTask(final Runnable runnable, final Object syncObject, final boolean catchExceptions, final PrintStream exceptionOut)
Create a RunnableTask object w/ synchronization, ie.
final Runnable getRunnable()
Return the user action.
Helper class to provide a Runnable queue implementation with a Runnable wrapper which notifies after ...
final Throwable getThrowable()
final String getExceptionOutIntro()
volatile Thread execThread
final boolean catchExceptions
volatile boolean isExecuted
final void printSourceTrace()
Throwable runnableException
final boolean isInQueue()
final PrintStream exceptionOut
Interface exposing java.lang.Thread#interrupt() source, intended for java.lang.Thread specializations...