29package com.jogamp.common.util;
31import java.io.PrintStream;
33import com.jogamp.common.JogampRuntimeException;
80 if( !waitUntilDone ) {
86 final Object sync =
new Object();
95 }
catch (
final InterruptedException ie) {
168 tStarted = System.currentTimeMillis();
172 }
catch (
final Throwable t) {
190 }
catch (
final Throwable t) {
A generic unchecked exception for Jogamp errors used throughout the binding as a substitute for Runti...
Helper class to provide a Runnable queue implementation with a Runnable wrapper which notifies after ...
static< U, V > FunctionTask< U, V > invokeOnNewThread(final ThreadGroup tg, final String threadName, final boolean waitUntilDone, final Function< U, V > func, final V... args)
Invokes func on a new InterruptSource.Thread, see InterruptSource.Thread#Thread(ThreadGroup,...
final R eval(final A... args)
Implementation may compute variable args list and returns a result.
FunctionTask(final Function< R, A > runnable, final Object syncObject, final boolean catchExceptions, final PrintStream exceptionOut)
Create a RunnableTask object w/ synchronization, ie.
final void setArgs(final A... args)
Sets the arguments for run().
Function< R, A > runnable
final R getResult()
Retrieves the cached result of run() and is cleared within this method.
static< U, V > FunctionTask< U, V > invokeOnCurrentThread(final Function< U, V > func, final V... args)
Invokes func on the current Thread.
final Function< R, A > getRunnable()
Return the user action.
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 ...
final void printSourceTrace()
Throwable runnableException
final String getExceptionOutIntro()
final Throwable getThrowable()
final boolean isInQueue()
final boolean catchExceptions
volatile Thread execThread
volatile boolean isExecuted
final PrintStream exceptionOut
Generic function interface to perform an action w/ given optional arguments producing an optional res...
Interface exposing java.lang.Thread#interrupt() source, intended for java.lang.Thread specializations...