Mercurial > hg > RemoteEditor > REPSessionManager
diff rep/Session.java @ 315:20fb70068089
*** empty log message ***
author | kono |
---|---|
date | Mon, 06 Oct 2008 18:58:49 +0900 |
parents | 8f6b7a1890b2 |
children | 77f443f6dc9f |
line wrap: on
line diff
--- a/rep/Session.java Mon Oct 06 10:34:37 2008 +0900 +++ b/rep/Session.java Mon Oct 06 18:58:49 2008 +0900 @@ -2,7 +2,6 @@ import java.util.Iterator; import java.util.LinkedList; -import java.util.List; import rep.channel.REPSocketChannel; public class Session { @@ -87,16 +86,9 @@ } return null; } - public void translate(REPSocketChannel<REPCommand> channel, REPCommand command) { - Editor editor = getEditor(channel); - List<REPCommand> commandList = editor.translate(command); - Editor nextEditor = getNextEditor(editor); - - for(REPCommand cmd: commandList){ - nextEditor.send(cmd); - } - } - private Editor getNextEditor(Editor editor) { + + + Editor getNextEditor(Editor editor) { int eid = editor.getEID(); int neid = (eid+1)%editorList.size(); Editor nextEditor = editorList.get(neid);