/*
* CDDL HEADER START
*
* The contents of this file are subject to the terms of the
* Common Development and Distribution License (the "License").
* You may not use this file except in compliance with the License.
*
* See LICENSE.txt included in this distribution for the specific
* language governing permissions and limitations under the License.
*
* When distributing Covered Code, include this CDDL HEADER in each
* file and include the License file at LICENSE.txt.
* If applicable, add the following below this CDDL HEADER, with the
* fields enclosed by brackets "[]" replaced with your own identifying
* information: Portions Copyright [yyyy] [name of copyright owner]
*
* CDDL HEADER END
*/
/*
*
* Portions Copyright 2011 Jens Elkner.
*/
/**
* @author Chandan slightly rewritten by Lubos Kosco
*/
public final class Results {
private Results() {
// Util class, should not be constructed
}
/**
* Create a has map keyed by the directory of the document found.
* @param searcher searcher to use.
* @param hits hits produced by the given searcher's search
* @param startIdx the index of the first hit to check
* @param stopIdx the index of the last hit to check
* @return a (directory, hitDocument) hashmap
* @throws CorruptIndexException
* @throws IOException
*/
throws CorruptIndexException, IOException
{
}
}
return dirHash;
}
@SuppressWarnings("resource")
// Grrrrrrrrrrrrr - TagFilter takes Readers, only!!!!
// Why? Is it CS sensible?
try {
if (isXref) {
} else {
}
} catch (Exception e) {
+ e.getMessage());
} finally {
}
return "";
}
/**
* Prints out results in html form. The following search helper fields are
* required to be properly initialized:
* <ul>
* <li>{@link SearchHelper#dataRoot}</li>
* <li>{@link SearchHelper#contextPath}</li>
* <li>{@link SearchHelper#searcher}</li>
* <li>{@link SearchHelper#hits}</li>
* <li>{@link SearchHelper#historyContext} (ignored if {@code null})</li>
* <li>{@link SearchHelper#sourceContext} (ignored if {@code null})</li>
* <li>{@link SearchHelper#summerizer} (if sourceContext is not {@code null})</li>
* <li>{@link SearchHelper#sourceRoot} (if sourceContext or historyContext
* is not {@code null})</li>
* </ul>
*
* @param out write destination
* @param sh search helper which has all required fields set
* @param start index of the first hit to print
* @param end index of the last hit to print
* @throws HistoryException
* @throws IOException
* @throws ClassNotFoundException
*/
int end)
{
{
}
}
// FIXME use Highlighter from lucene contrib here,
// instead of summarizer, we'd also get rid of
// apache lucene in whole source ...
} else {
@SuppressWarnings("resource")
: null;
}
}
}
}
}
}
}