Mercurial > hg > RemoteEditor > REPSessionManager
diff rep/handler/Dispatcher.java @ 387:6f356d160e58
IPv6 any address
author | one@firefly.cr.ie.u-ryukyu.ac.jp |
---|---|
date | Mon, 10 Nov 2008 22:21:52 +0900 |
parents | bba62c4ac323 |
children |
line wrap: on
line diff
--- a/rep/handler/Dispatcher.java Mon Nov 10 22:19:34 2008 +0900 +++ b/rep/handler/Dispatcher.java Mon Nov 10 22:21:52 2008 +0900 @@ -17,8 +17,10 @@ */ public class Dispatcher extends Forwarder { - public Dispatcher(SessionManager manager) { - super(manager); + + public Dispatcher(SessionManager manager, + REPSocketChannel<REPCommand> channel) { + super(manager, channel); } public void setQuit2(REPCommand cmd) { @@ -35,14 +37,13 @@ } - public void handle(REPSelectionKey<REPCommand> key) throws IOException { + @Override + public void handle(REPCommand command, REPSelectionKey<REPCommand> key) throws IOException { /* * SessionManagerから来たコマンドは、Editor関係のコマンドは、 * sessionとeidを判定して、そのeditorにforwardしてやれば良い。 * 残りは、manager.manage() で処理する。 */ - REPSocketChannel<REPCommand> channel = key.channel1(); - REPCommand command = channel.read(); ServerMainLoop.logger.writeLog("REPHandlerImpl.handle() : command = " + command); if (manager.sessionManage(this, command)) return;