LUCENE-1486: Move ComplexPhraseQueryParser to contrib

git-svn-id: https://svn.apache.org/repos/asf/lucene/java/trunk@800193 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Mark Robert Miller 2009-08-03 04:06:22 +00:00
parent e8ef5a0b9a
commit 5aaf5b0167
4 changed files with 18 additions and 14 deletions

View File

@ -621,18 +621,12 @@ New features
All standard parsers now also implement Serializable and enforce
their singleton status. (Uwe Schindler, Mike McCandless)
31. LUCENE-1486: Added ComplexPhraseQueryParser, an extension of QueryParser
that allows a subset of the Lucene query language to be embedded in
PhraseQuerys. Wildcard, Range, and Fuzzy queries, as well as limited
boolean logic, can be used within quote operators with this parser, ie:
"(jo* -john) smyth~". (Mark Harwood via Mark Miller)
32. LUCENE-1741: User configureable maximum chunk size in MMapDirectory.
31. LUCENE-1741: User configureable maximum chunk size in MMapDirectory.
On 32 bit platforms, the address space can be very fragmented, so
one big ByteBuffer for the whole file may not fit into address space.
(Eks Dev via Uwe Schindler)
33. LUCENE-1644: Enable 4 rewrite modes for queries deriving from
32. LUCENE-1644: Enable 4 rewrite modes for queries deriving from
MultiTermQuery (WildcardQuery, PrefixQuery, TermRangeQuery,
NumericRangeQuery): CONSTANT_SCORE_FILTER_REWRITE first creates a
filter and then assigns constant score (boost) to docs;
@ -642,7 +636,7 @@ New features
CONSTANT_SCORE_AUTO_REWRITE tries to pick the most performant
constant-score rewrite method. (Mike McCandless)
34. LUCENE-1448: Added TokenStream.end(), to perform end-of-stream
33. LUCENE-1448: Added TokenStream.end(), to perform end-of-stream
operations. This is currently used to fix offset problems when
multiple fields with the same name are added to a document.
(Mike McCandless, Mark Miller, Michael Busch)

View File

@ -106,6 +106,13 @@ New features
3.0 and will then replace the current core QueryParser, which
has been deprecated with this patch.
(Luis Alves and Adriano Campos via Michael Busch)
13. LUCENE-1486: Added ComplexPhraseQueryParser, an extension of QueryParser
that allows a subset of the Lucene query language to be embedded in
PhraseQuerys. Wildcard, Range, and Fuzzy queries, as well as limited
boolean logic, can be used within quote operators with this parser, ie:
"(jo* -john) smyth~". (Mark Harwood via Mark Miller)
Optimizations

View File

@ -1,4 +1,4 @@
package org.apache.lucene.queryParser;
package org.apache.lucene.queryParser.complexPhrase;
/**
* Licensed to the Apache Software Foundation (ASF) under one or more
@ -25,11 +25,13 @@ import java.util.List;
import org.apache.lucene.analysis.Analyzer;
import org.apache.lucene.index.IndexReader;
import org.apache.lucene.index.Term;
import org.apache.lucene.queryParser.ParseException;
import org.apache.lucene.queryParser.QueryParser;
import org.apache.lucene.search.BooleanClause;
import org.apache.lucene.search.BooleanQuery;
import org.apache.lucene.search.MultiTermQuery;
import org.apache.lucene.search.Query;
import org.apache.lucene.search.TermQuery;
import org.apache.lucene.search.MultiTermQuery;
import org.apache.lucene.search.TermRangeQuery;
import org.apache.lucene.search.spans.SpanNearQuery;
import org.apache.lucene.search.spans.SpanNotQuery;
@ -54,8 +56,8 @@ import org.apache.lucene.search.spans.SpanTermQuery;
* currently simply feeds all phrase content through an analyzer to select
* phrase terms - any "special" syntax such as * ~ * etc are not given special
* status
*
* @deprecated use new the flexible query parser instead
*
*
*/
public class ComplexPhraseQueryParser extends QueryParser {
private ArrayList/*<ComplexPhraseQuery>*/complexPhrases = null;

View File

@ -1,4 +1,4 @@
package org.apache.lucene.queryParser;
package org.apache.lucene.queryParser.complexPhrase;
/**
* Licensed to the Apache Software Foundation (ASF) under one or more
@ -27,6 +27,7 @@ import org.apache.lucene.document.Document;
import org.apache.lucene.document.Field;
import org.apache.lucene.index.IndexWriter;
import org.apache.lucene.index.IndexWriter.MaxFieldLength;
import org.apache.lucene.queryParser.QueryParser;
import org.apache.lucene.search.IndexSearcher;
import org.apache.lucene.search.Query;
import org.apache.lucene.search.ScoreDoc;