Ignore:
Timestamp:
2008-07-17T16:20:14+12:00 (16 years ago)
Author:
mdewsnip
Message:

Changed the "id" attributes of "<Match>" tags returned so they don't necessarily have to be integers, in preparation for changing to return Greenstone docOIDs instead of the Lucene nodeIDs (for efficiency and to allow incremental building).

File:
1 edited

Legend:

Unmodified
Added
Removed
  • indexers/trunk/lucene-gs/src/org/greenstone/LuceneWrapper/GS2LuceneQuery.java

    r16015 r16443  
    187187        for (int i = start_results; i <= hits.length(); i++) {
    188188            Document doc = hits.doc(i - 1);
    189             lucene_query_result.addDoc(Long.parseLong(doc.get("nodeID").trim()), hits.score(i-1));
     189            lucene_query_result.addDoc(doc.get("nodeID").trim(), hits.score(i-1));
    190190        }
    191191        }
     
    203203        for (int i = start_results; (i <= hits.scoreDocs.length && i <= end_results); i++) {
    204204            Document doc = reader.document(hits.scoreDocs[i - 1].doc);
    205             lucene_query_result.addDoc(Long.parseLong(doc.get("nodeID").trim()), hits.scoreDocs[i-1].score);
     205            lucene_query_result.addDoc(doc.get("nodeID").trim(), hits.scoreDocs[i-1].score);
    206206        }
    207207        }
Note: See TracChangeset for help on using the changeset viewer.