Class Parser
java.lang.Object
Parser
public class Parser
- extends Object
Constructor Summary |
Parser(String[] commands)
Create a parser to read from the terminal window. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Parser
public Parser(String[] commands)
- Create a parser to read from the terminal window.
getCommand
public Command getCommand()
- Returns:
- The next command from the user.
showCommands
public String showCommands()
- Print out a list of valid command words.