A validator for lucene query syntax