aim4.gui
Class Viewer.SimThread

java.lang.Object
  extended by aim4.gui.Viewer.SimThread
All Implemented Interfaces:
Runnable
Enclosing class:
Viewer

public class Viewer.SimThread
extends Object
implements Runnable

The simulation thread that holds the simulation process.


Constructor Summary
Viewer.SimThread(boolean isTurboMode, long timeDelay)
          Create a simulation thread.
 
Method Summary
 boolean isPaused()
          Whether the thread is stopped.
 boolean isTurboMode()
          Whether the thread is in the turbo mode.
 void pause()
          Pause this simulation thread
 void resume()
          Resume this simulation thread
 void run()
          
 void setSteppingMode(boolean isSteppingMode)
          Set whether the stepping mode is on
 void setTimeDelay(long timeDelay)
          Set the time delay.
 void setTurboMode(boolean isTurboMode)
          Set whether the turbo mode is on
 void start()
          Start the simulation thread.
 void terminate()
          Terminate/Kill this simulation thread.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Viewer.SimThread

public Viewer.SimThread(boolean isTurboMode,
                        long timeDelay)
Create a simulation thread.

Parameters:
isTurboMode - Whether the turbo mode is on
timeDelay - The time delay
Method Detail

isPaused

public boolean isPaused()
Whether the thread is stopped.

Returns:
Whether the thread is stopped.

isTurboMode

public boolean isTurboMode()
Whether the thread is in the turbo mode.

Returns:
Whether the thread is in the turbo mode.

setTurboMode

public void setTurboMode(boolean isTurboMode)
Set whether the turbo mode is on

Parameters:
isTurboMode - Whether the turbo mode is on

setSteppingMode

public void setSteppingMode(boolean isSteppingMode)
Set whether the stepping mode is on

Parameters:
isSteppingMode - Whether the stepping mode is on

setTimeDelay

public void setTimeDelay(long timeDelay)
Set the time delay.

Parameters:
timeDelay - the time delay.

start

public void start()
Start the simulation thread.


terminate

public void terminate()
Terminate/Kill this simulation thread.


pause

public void pause()
Pause this simulation thread


resume

public void resume()
Resume this simulation thread


run

public void run()

Specified by:
run in interface Runnable


Copyright © 2011. All Rights Reserved.