ostream.writeInt(nsSymbols.size()); for (Iterator i = nsSymbols.entrySet().iterator(); i.hasNext();) { final Object2IntMap.Entry entry = (Object2IntMap.Entry) i.next(); ostream.writeUTF((String) entry.getKey()); ostream.writeShort((short) entry.getIntValue()); } ostream.writeInt(defaultMappings.size()); String prefix; short nsId; for (Iterator i = defaultMappings.keySet().iterator(); i.hasNext();) { prefix = (String) i.next(); nsId = defaultMappings.getShort(prefix); ostream.writeUTF(prefix); ostream.writeShort(nsId); }
	protected synchronized void write(final DataOutput ostream)		throws IOException {		ostream.writeShort(max);		ostream.writeShort(nextPartition);		ostream.writeInt(symbols.size());		for (Iterator i = symbols.entrySet().iterator(); i.hasNext();) {			final Object2IntMap.Entry entry = (Object2IntMap.Entry) i.next();			ostream.writeUTF((String) entry.getKey());			ostream.writeShort((short) entry.getIntValue());		}		//        symbols.forEachEntry(new TObjectIntProcedure() {		//            public boolean execute(Object key, int val) {		//                try {		//                    ostream.writeUTF((String) key);		//                    ostream.writeShort((short) val);		//                } catch (IOException ioe) {		//                    return false;		//                }		//                return true;		//            }		//        });		changed = false;	}