for (int i = 0; i < queryLength; i++) {
//get the entry statistics - perhaps this came from "far away"
EntryStatistics entryStats = queryTerms.getStatistics(queryTermStrings[i]);
//we seek the query term in the lexicon
LexiconEntry lEntry = lexicon.getLexiconEntry(queryTermStrings[i]);
if (entryStats == null)
entryStats = lEntry;
//and if it is not found, we continue with the next term
if (lEntry==null)
{
//logger.info("Term Not Found: "+queryTermStrings[i]);
continue;
}
queryTerms.setTermProperty(queryTermStrings[i], lEntry);
logger.debug((i + 1) + ": " + queryTermStrings[i].trim() + " with " + entryStats.getDocumentFrequency()
+ " documents (TF is " + entryStats.getFrequency() + ").");
//check if the IDF is very low.
if (IGNORE_LOW_IDF_TERMS && collectionStatistics.getNumberOfDocuments() < lEntry.getFrequency()) {
logger.debug("query term " + queryTermStrings[i] + " has low idf - ignored from scoring.");
continue;