documents.put(p.doc.getFileName(), new Integer(hits.intValue() + 1));
documents.put(p.getDocument().getFileName(), new Integer(hits.intValue() + 1));
	private TreeMap scanResults(Sequence results) {		TreeMap collections = new TreeMap();		TreeMap documents;		Integer hits;		for (SequenceIterator i = results.iterate(); i.hasNext(); ) {			Item item = i.nextItem();			if(Type.subTypeOf(item.getType(), Type.NODE)) {				NodeValue node = (NodeValue)item;				if(node.getImplementationType() == NodeValue.PERSISTENT_NODE) {					NodeProxy p = (NodeProxy)node;					if ((documents = (TreeMap) collections.get(p.doc.getCollection().getName())) == null) {						documents = new TreeMap();						collections.put(p.doc.getCollection().getName(), documents);					}					if ((hits = (Integer) documents.get(p.doc.getFileName())) == null)						documents.put(p.doc.getFileName(), new Integer(1));					else						documents.put(p.doc.getFileName(), new Integer(hits.intValue() + 1));				}			}		}		return collections;	}