| org.quickserver.net.qsadmin.CommandPlugin
All known Subclasses: ftpserver.QSAdminCommandPlugin,
CommandPlugin | public interface CommandPlugin (Code) | | This interface defines the methods that should be implemented by
any class that wants to override default protocol of QsAdminServer
or add new command specific to your application.
Recommendations to be followed when implementing ClientCommandHandler
- Should be thread safe.
- It should not store any client data that may be needed in the
implementation.
- If any client data is need to be saved from the client session,
it should be saved to a
ClientData class, which can be retrieved
using handler.getClientData() method.
- Should have a default constructor - If QsAdminSupport is needed.
If you need to access the QuickServer you can use the code given below
QuickServer myserver = (QuickServer) handler.getServer().getStoreObjects()[0];
See Also: QSAdminServer.startServer author: Akshathkumar Shetty |
Method Summary | |
public boolean | handleCommand(ClientHandler handler, String command) Method called every time client sends a command to QsAdminServer.
Should be used to handle the command sent and send any
requested data. |
handleCommand | public boolean handleCommand(ClientHandler handler, String command) throws SocketTimeoutException, IOException(Code) | | Method called every time client sends a command to QsAdminServer.
Should be used to handle the command sent and send any
requested data.
If the comand is handled by the plugin it should
return true else it should return false
indicating qsadmin.CommandHandler to take any
default action for the command.
This method can be used to override default protocol of
QsAdminServer or add new command specific to your application.
exception: java.net.SocketTimeoutException - if socket times out exception: java.io.IOException - if io error in socket |
|
|