Skip to content

Apache Lucene open-source search software

Deprecate static parse method, to be removed in 2.0. It causes more trouble than it is worth

Erik Hatcher77290bc28643
diff --git a/src/java/org/apache/lucene/queryParser/QueryParser.jj b/src/java/org/apache/lucene/queryParser/QueryParser.jj
index 1899539f61c..6ee8db01edc 100644
--- a/src/java/org/apache/lucene/queryParser/QueryParser.jj
+++ b/src/java/org/apache/lucene/queryParser/QueryParser.jj
@@ -118,6 +118,8 @@ public class QueryParser {
* @param field the default field for query terms.
* @param analyzer used to find terms in the query text.
* @throws ParseException if the parsing fails
+ *
+ * @deprecated Use an instance of QueryParser and the {@link #parse(String)} method instead.
*/
static public Query parse(String query, String field, Analyzer analyzer)
throws ParseException {