|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectes.ucm.fdi.hysteria.console.command.Command
es.ucm.fdi.hysteria.console.command.CloseCommand
public class CloseCommand
Field Summary | |
---|---|
protected Game.Direction |
_dir
The movement direction |
protected java.lang.String |
_item
|
protected boolean |
_withItem
|
Fields inherited from class es.ucm.fdi.hysteria.console.command.Command |
---|
_config, _executed, _game, _parsed, _result, _successful |
Constructor Summary | |
---|---|
CloseCommand(Game theGame)
MoveCommand constructor. |
|
CloseCommand(Game theGame,
java.util.Properties config)
MoveCommand constructor. |
Method Summary | |
---|---|
java.lang.Object |
clone()
Returns a clone of this command. |
boolean |
execute()
Executes the command. |
java.lang.String |
getHelp()
Creates a string with the information about the command. |
boolean |
parse(java.lang.String line)
Tries to configure the command with the information contained in a string. |
java.lang.String |
toString()
|
Methods inherited from class es.ucm.fdi.hysteria.console.command.Command |
---|
getResult, hasResult, setConfig, setGame |
Methods inherited from class java.lang.Object |
---|
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected Game.Direction _dir
protected boolean _withItem
protected java.lang.String _item
Constructor Detail |
---|
public CloseCommand(Game theGame) throws java.lang.IllegalArgumentException
theGame
- Reference to main Game
java.lang.IllegalArgumentException
public CloseCommand(Game theGame, java.util.Properties config) throws java.lang.IllegalArgumentException
theGame
- Reference to main Game
java.lang.IllegalArgumentException
Method Detail |
---|
public boolean execute() throws UnparsedCommandException
Command
execute
in class Command
UnparsedCommandException
public java.lang.String getHelp()
Command
getHelp
in class Command
public boolean parse(java.lang.String line)
Command
parse
in class Command
line
- Order to parse
public java.lang.String toString()
toString
in class Command
public java.lang.Object clone()
Command
clone
in class Command
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |