public void readIn(DataInputStream din) throws IOException { Iterator it = allConversations.iterator(); while (it.hasNext()) { Conversation conv = (Conversation) it.next(); conv.setUsed(false); } int count = din.readInt(); for (int i = 0; i < count; i++) { readConv.readIn(din); Conversation existing = findConversation(readConv.getRmt_ip(), readConv.getLcl_port(), readConv.getRmt_port()); existing.setUsed(true); existing.setInfo(readConv); } removeUnused(); }