Mercurial > hg > RemoteEditor > REPSessionManager
view rep/EditorList.java @ 452:d0d2449000f5
checkAck
author | one |
---|---|
date | Thu, 23 Sep 2010 21:19:28 +0900 |
parents | 3b0a5a55e3ee |
children |
line wrap: on
line source
package rep; import java.util.HashMap; import rep.channel.REPSocketChannel; import rep.handler.REPNode; public class EditorList extends HashMap<Integer,REPNode> { /** * */ private static final long serialVersionUID = 1L; private int eid_root=0; public void add(REPNode fw) { put(fw.getEID(),fw); } public int newEid() { return ++eid_root; } public boolean hasEid(int eid) { return containsKey(eid); } public REPNode editorByChannel(REPSocketChannel<REPCommand>channel) { for(REPNode e:this.values()) { if (e.channel==channel) return e; } return null; } }