Class Command

java.lang.Object
  extended by Command
Direct Known Subclasses:
Go, Help, Quit

public class Command
extends Object

Type of any valid command of the game. An object of this class is the Unkown command, a command the game does not understand. All commands are subclasses of this class.

Version:
28/1/2015
Author:
Olaf Chitil

Constructor Summary
Command()
           
 
Method Summary
 String process(GameMain ui, Game game)
          Process, that is, execute the command in the game.
 
Methods inherited from class
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Command

public Command()
Method Detail

process

public String process(GameMain ui,
                      Game game)
Process, that is, execute the command in the game.

Parameters:
game - The actual game.
Returns:
Message to the player.