

InternalCommands is internal class implementing command handler for some basic and necessary actions which requires access to internal connection data such as 'quit' command, 'who', 'close'.
for details look in help() method content.
Definition at line 280 of file ConnectionServer.java.
Public Methods | |
| String | handleCommand (String comm) |
handleCommand handle and process given command as a String here. | |
| String | help () |
help method should return string containing help for all commands provided by this command handler. | |
| String | help (String command) |
help method should return string describing in detail command given as a parameter or empty string if there is no such command in this command handler. | |
| CommandHandlerIfc | getInstance () |
getInstance method should return instance of defined implementation for this instance. | |
Protected Methods | |
| String | buildFileString (File ff) |
| String | setForTrueOrFalse (boolean cond, String for_true, String for_false) |
Protected Attributes | |
| String | last_command = null |
|
|
Common implementation should lookds like following: public class MyCommandHandler implements remotecons.ifc.CommandHandlerIfc { (... other methods definition ...) public remotecons.ifc.CommandHandlerIfc getInstance() { return new MyCommandHandler(); } }It is necessary for cases when you create commands handlers which are inner classes. Maybe it is not good practice but very useful for developing and debuging applications which works long time.
Implements CommandHandlerIfc. Definition at line 461 of file ConnectionServer.java. |
|
|
If you will return
To get next command prompt on user side you must return string ended with "
Implements CommandHandlerIfc. Definition at line 284 of file ConnectionServer.java. |
|
|
Implements CommandHandlerIfc. Definition at line 457 of file ConnectionServer.java. |
|
|
Implements CommandHandlerIfc. Definition at line 444 of file ConnectionServer.java. |
1.3-rc2