edu.cuny.cat.server
Class EventBasedClockController
java.lang.Object
edu.cuny.cat.server.ClockController
edu.cuny.cat.server.EventBasedClockController
- All Implemented Interfaces:
- AuctionEventListener, edu.cuny.event.RichEventListener, java.util.EventListener
public class EventBasedClockController
- extends ClockController
- implements edu.cuny.event.RichEventListener
A clock controller that controls the clock based upon
RichEvent
s sent from an external source. It enables a
human user to control the simulation through a graphical or command line
interface.
- Version:
- $Revision: 1.4 $
- Author:
- Jinzhong Niu
- See Also:
GuiConsole
,
TelnetConsole
Field Summary |
static java.lang.String |
PAUSE
|
static java.lang.String |
QUIT
|
static java.lang.String |
RESUME
|
static java.lang.String |
START
|
Method Summary |
void |
eventOccurred(edu.cuny.event.RichEvent te)
|
void |
start()
starts the game clock, or asks an external source to decide when to start. |
void |
stop()
stops the game clock. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
START
public static java.lang.String START
PAUSE
public static java.lang.String PAUSE
RESUME
public static java.lang.String RESUME
QUIT
public static java.lang.String QUIT
EventBasedClockController
public EventBasedClockController()
start
public void start()
- Description copied from class:
ClockController
- starts the game clock, or asks an external source to decide when to start.
- Overrides:
start
in class ClockController
stop
public void stop()
- Description copied from class:
ClockController
- stops the game clock. When this method will be called is up to the child
class that extends this class.
- Overrides:
stop
in class ClockController
eventOccurred
public void eventOccurred(edu.cuny.event.RichEvent te)
- Specified by:
eventOccurred
in interface edu.cuny.event.RichEventListener