public class CommandMapper
extends java.lang.Object
| Constructor | Description |
|---|---|
CommandMapper() |
| Modifier and Type | Method | Description |
|---|---|---|
static java.lang.String |
allCommands() |
|
static Response |
getResponse(java.lang.String cmdWord) |
Return the command associated with a command word.
|
static void |
init(Game game,
java.lang.String helpIntroStr) |
Initialize the command response mapping
|
static boolean |
isCommand(java.lang.String aString) |
Check whether a given String is a valid command word.
|
public static void init(Game game, java.lang.String helpIntroStr)
game - The game being played.helpIntroStr - World data for help intro.public static boolean isCommand(java.lang.String aString)
aString - The possible command word.public static Response getResponse(java.lang.String cmdWord)
cmdWord - The command word.public static java.lang.String allCommands()