try {
aRetArr[d] = new NewsMessageRecord(oTopDoc[d].score, oDoc.get("workarea"),
oDoc.get("guid"), oDoc.get("container"), oDoc.get("title"),
oDoc.get("author"), DateTools.stringToDate(oDoc.get("created")), oDoc.get("abstract"));
} catch (java.text.ParseException neverthrown) {
throw new ParseException("NewsMessageSearcher.search() Error parsing date "+oDoc.get("created")+" of document "+oDoc.get("guid"));
}
} // next
} else {
aRetArr = null;
}
} else {
Hits oHitSet = oSearch.search(oQrx);
int iHitCount = oHitSet.length();
if (iHitCount>0) {
aRetArr = new NewsMessageRecord[iHitCount];
for (int h=0; h<iHitCount; h++) {
oDoc = oHitSet.doc(h);
try {
aRetArr[h] = new NewsMessageRecord(oHitSet.score(h), oDoc.get("workarea"),
oDoc.get("guid"), oDoc.get("container"), oDoc.get("title"),
oDoc.get("author"), DateTools.stringToDate(oDoc.get("created")), oDoc.get("abstract"));
} catch (java.text.ParseException neverthrown) {
throw new ParseException("NewsMessageSearcher.search() Error parsing date "+oDoc.get("created")+" of document "+oDoc.get("guid"));
}
} // next
} else {
aRetArr = null;
}