public class IndexValidator
extends Object
| Modifier and Type | Class and Description |
|---|---|
static class |
IndexValidator.ValidationError
Internal exception for quickly passing errors up the call chain.
|
| Modifier and Type | Field and Description |
|---|---|
private TestableCrossQuery |
crossQuery |
private TestableDynaXML |
dynaXML |
private int |
nErrs |
| Constructor and Description |
|---|
IndexValidator() |
| Modifier and Type | Method and Description |
|---|---|
private void |
traverse(EasyNode node,
int level)
Traverse the validation specification document, visiting each node.
|
boolean |
validate(String baseDir,
String indexPath,
IndexReader indexReader)
Run validations for the given index.
|
private void |
visit(EasyNode node,
int level)
Process one node of the validation specification document.
|
private TestableCrossQuery crossQuery
private TestableDynaXML dynaXML
private int nErrs
public boolean validate(String baseDir,
String indexPath,
IndexReader indexReader)
throws IOException
baseDir - XTF home directoryindexPath - path to the index dataindexReader - Lucene reader for the indexIOException - if the index can't be readprivate void traverse(EasyNode node, int level) throws IndexValidator.ValidationError, ServletException, IOException
IndexValidator.ValidationErrorServletExceptionIOExceptionprivate void visit(EasyNode node, int level) throws IndexValidator.ValidationError, ServletException, IOException
IndexValidator.ValidationErrorServletExceptionIOException