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
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.time.Duration
getDuration()
java.lang.String
getInformation()
java.time.Instant
getStartingTime()
java.lang.Thread
getThread()
void
interrupt()
Interrupt this action.boolean
isRunning()
void
setThread(java.lang.Thread thread)
void
startThread()
-
-
-
Constructor Detail
-
ThreadWrapper
public ThreadWrapper(MainWindow mainWindow)
-
-
Method Detail
-
setThread
public void setThread(java.lang.Thread thread)
-
startThread
public void startThread()
-
getThread
public java.lang.Thread getThread()
-
isRunning
public boolean isRunning()
- Specified by:
isRunning
in interfaceRunningAction
- Returns:
- true if this action is running.
-
interrupt
public void interrupt()
Description copied from interface:RunningAction
Interrupt this action.- Specified by:
interrupt
in interfaceRunningAction
-
getStartingTime
public java.time.Instant getStartingTime()
- Specified by:
getStartingTime
in interfaceRunningAction
- Returns:
- Starting time of this action.
-
getDuration
public java.time.Duration getDuration()
- Specified by:
getDuration
in interfaceRunningAction
- Returns:
- Current duration of this action.
-
getInformation
public java.lang.String getInformation()
- Specified by:
getInformation
in interfaceRunningAction
- Returns:
- Information for this action.
-
-