Package se.datadosen.jalbum
Class SlowOperation
java.lang.Object
java.lang.Thread
se.datadosen.jalbum.SlowOperation
- All Implemented Interfaces:
Runnable
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Thread
Thread.BuilderPREVIEW, Thread.State, Thread.UncaughtExceptionHandler
-
Field Summary
Modifier and TypeFieldDescriptionprotected Action
protected JSmartDialog
protected JProgressSpinner
Fields inherited from class java.lang.Thread
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY
-
Constructor Summary
-
Method Summary
Methods inherited from class java.lang.Thread
activeCount, checkAccess, clone, countStackFrames, currentThread, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, isVirtual, join, join, join, join, ofPlatform, ofVirtual, onSpinWait, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, sleep, start, startVirtualThread, stop, suspend, threadId, toString, yield
-
Field Details
-
dialog
-
spinner
-
abortAction
-
-
Constructor Details
-
SlowOperation
public SlowOperation()
-
-
Method Details
-
launch
Launch slow process and pop up dialog window during the process- Returns:
- boolean true if process finished normally (was not aborted)
- Throws:
Throwable
-
launch
public boolean launch(Window parent, JLabel messageLabel, Icon altIcon, String title) throws Throwable - Throws:
Throwable
-
getMessageLabel
-
getThrowable
-
setResult
-
getResult
-
isDone
public boolean isDone() -
run
public void run() -
operation
- Throws:
Throwable
-
abort
public abstract void abort()A call to abort should make the run method to exit
-