4 public Room(String n) {
6 participants=new HashSet();
9 synchronized void addParticipant(ChatThread cs) {
14 synchronized void sendToRoom(ChatThread caller, byte [] message) {
15 HashMapIterator hmi=participants.iterator();
16 while(hmi.hasNext()) {
17 ChatThread cs=(ChatThread) hmi.next();
19 cs.sock.write(message);