Package org.insa.graphs.gui
Class ThreadWrapper
java.lang.Object
org.insa.graphs.gui.ThreadWrapper
- All Implemented Interfaces:
RunningAction
public class ThreadWrapper extends java.lang.Object implements RunningAction
-
Constructor Summary
Constructors Constructor Description ThreadWrapper(MainWindow mainWindow) -
Method Summary
Modifier and Type Method Description java.time.DurationgetDuration()java.lang.StringgetInformation()java.time.InstantgetStartingTime()java.lang.ThreadgetThread()voidinterrupt()Interrupt this action.booleanisRunning()voidsetThread(java.lang.Thread thread)voidstartThread()
-
Constructor Details
-
Method Details
-
setThread
public void setThread(java.lang.Thread thread) -
startThread
public void startThread() -
getThread
public java.lang.Thread getThread() -
isRunning
public boolean isRunning()- Specified by:
isRunningin interfaceRunningAction- Returns:
- true if this action is running.
-
interrupt
public void interrupt()Description copied from interface:RunningActionInterrupt this action.- Specified by:
interruptin interfaceRunningAction
-
getStartingTime
public java.time.Instant getStartingTime()- Specified by:
getStartingTimein interfaceRunningAction- Returns:
- Starting time of this action.
-
getDuration
public java.time.Duration getDuration()- Specified by:
getDurationin interfaceRunningAction- Returns:
- Current duration of this action.
-
getInformation
public java.lang.String getInformation()- Specified by:
getInformationin interfaceRunningAction- Returns:
- Information for this action.
-