diff --git lucene/build.xml lucene/build.xml index 96be669..1990c72 100644 --- lucene/build.xml +++ lucene/build.xml @@ -326,7 +326,7 @@ - + @@ -557,6 +557,14 @@ + + + + + + + + + + + + @@ -550,6 +560,7 @@ + @@ -557,6 +568,7 @@ + Building from @{basedir} to @{destfile} @@ -571,6 +583,7 @@ diff --git lucene/core/src/java/org/apache/lucene/analysis/Analyzer.java lucene/core/src/java/org/apache/lucene/analysis/Analyzer.java index dbeeabe..f40305b 100644 --- lucene/core/src/java/org/apache/lucene/analysis/Analyzer.java +++ lucene/core/src/java/org/apache/lucene/analysis/Analyzer.java @@ -47,7 +47,7 @@ public abstract class Analyzer { /** * Creates a new {@link TokenStreamComponents} instance for this analyzer. - * + * * @param fieldName * the name of the fields content passed to the * {@link TokenStreamComponents} sink as a reader @@ -70,7 +70,7 @@ public abstract class Analyzer { * method will reuse the previously stored components after resetting them * through {@link TokenStreamComponents#setReader(Reader)}. *

- * + * * @param fieldName the name of the field the created TokenStream is used for * @param reader the reader the streams source reads from */ @@ -86,7 +86,7 @@ public abstract class Analyzer { } return components.getTokenStream(); } - + /** * Override this if you want to add a CharFilter chain. */ @@ -142,7 +142,7 @@ public abstract class Analyzer { /** * Creates a new {@link TokenStreamComponents} instance. - * + * * @param source * the analyzer's tokenizer * @param result @@ -153,10 +153,10 @@ public abstract class Analyzer { this.source = source; this.sink = result; } - + /** * Creates a new {@link TokenStreamComponents} instance. - * + * * @param source * the analyzer's tokenizer */ @@ -168,7 +168,7 @@ public abstract class Analyzer { /** * Resets the encapsulated components with the given reader. If the components * cannot be reset, an Exception should be thrown. - * + * * @param reader * a reader to reset the source component * @throws IOException @@ -180,7 +180,7 @@ public abstract class Analyzer { /** * Returns the sink {@link TokenStream} - * + * * @return the sink {@link TokenStream} */ public TokenStream getTokenStream() { diff --git lucene/core/src/java/org/apache/lucene/analysis/AnalyzerWrapper.java lucene/core/src/java/org/apache/lucene/analysis/AnalyzerWrapper.java index 261075c..6f28a44 100644 --- lucene/core/src/java/org/apache/lucene/analysis/AnalyzerWrapper.java +++ lucene/core/src/java/org/apache/lucene/analysis/AnalyzerWrapper.java @@ -17,6 +17,7 @@ package org.apache.lucene.analysis; * limitations under the License. */ + import java.io.Reader; /** diff --git lucene/core/src/java/org/apache/lucene/analysis/NumericTokenStream.java lucene/core/src/java/org/apache/lucene/analysis/NumericTokenStream.java index d347027..bacf671 100644 --- lucene/core/src/java/org/apache/lucene/analysis/NumericTokenStream.java +++ lucene/core/src/java/org/apache/lucene/analysis/NumericTokenStream.java @@ -21,12 +21,6 @@ import org.apache.lucene.analysis.tokenattributes.CharTermAttribute; import org.apache.lucene.analysis.tokenattributes.PositionIncrementAttribute; import org.apache.lucene.analysis.tokenattributes.TermToBytesRefAttribute; import org.apache.lucene.analysis.tokenattributes.TypeAttribute; -import org.apache.lucene.document.DoubleField; // for javadocs -import org.apache.lucene.document.FloatField; // for javadocs -import org.apache.lucene.document.IntField; // for javadocs -import org.apache.lucene.document.LongField; // for javadocs -import org.apache.lucene.search.NumericRangeFilter; // for javadocs -import org.apache.lucene.search.NumericRangeQuery; import org.apache.lucene.util.Attribute; import org.apache.lucene.util.AttributeImpl; import org.apache.lucene.util.AttributeReflector; @@ -35,11 +29,11 @@ import org.apache.lucene.util.NumericUtils; /** * Expert: This class provides a {@link TokenStream} - * for indexing numeric values that can be used by {@link - * NumericRangeQuery} or {@link NumericRangeFilter}. + * for indexing numeric values that can be used by + * NumericRangeQuery or NumericRangeFilter. * - *

Note that for simple usage, {@link IntField}, {@link - * LongField}, {@link FloatField} or {@link DoubleField} is + *

Note that for simple usage, IntField, + * LongField, FloatField or DoubleField is * recommended. These fields disable norms and * term freqs, as they are not usually needed during * searching. If you need to change these settings, you @@ -80,7 +74,7 @@ import org.apache.lucene.util.NumericUtils; * than one numeric field, use a separate NumericTokenStream * instance for each.

* - *

See {@link NumericRangeQuery} for more details on the + *

See NumericRangeQuery for more details on the * precisionStep * parameter as well as how numeric fields work under the hood.

diff --git lucene/core/src/java/org/apache/lucene/analysis/Token.java lucene/core/src/java/org/apache/lucene/analysis/Token.java index 7d33509..42b7ec0 100644 --- lucene/core/src/java/org/apache/lucene/analysis/Token.java +++ lucene/core/src/java/org/apache/lucene/analysis/Token.java @@ -24,7 +24,6 @@ import org.apache.lucene.analysis.tokenattributes.PayloadAttribute; import org.apache.lucene.analysis.tokenattributes.PositionIncrementAttribute; import org.apache.lucene.analysis.tokenattributes.PositionLengthAttribute; import org.apache.lucene.analysis.tokenattributes.TypeAttribute; -import org.apache.lucene.index.DocsAndPositionsEnum; // for javadoc import org.apache.lucene.util.Attribute; import org.apache.lucene.util.AttributeSource; import org.apache.lucene.util.AttributeImpl; @@ -47,7 +46,7 @@ import org.apache.lucene.util.BytesRef; with type "eos". The default token type is "word".

A Token can optionally have metadata (a.k.a. payload) in the form of a variable - length byte array. Use {@link DocsAndPositionsEnum#getPayload()} to retrieve the + length byte array. Use DocsAndPositionsEnum#getPayload() to retrieve the payloads from the index.

diff --git lucene/core/src/java/org/apache/lucene/analysis/TokenStream.java lucene/core/src/java/org/apache/lucene/analysis/TokenStream.java index 605b3cf..2cb8f7c 100644 --- lucene/core/src/java/org/apache/lucene/analysis/TokenStream.java +++ lucene/core/src/java/org/apache/lucene/analysis/TokenStream.java @@ -21,16 +21,12 @@ import java.io.IOException; import java.io.Closeable; import java.lang.reflect.Modifier; -import org.apache.lucene.document.Document; -import org.apache.lucene.document.Field; -import org.apache.lucene.index.IndexWriter; import org.apache.lucene.util.Attribute; import org.apache.lucene.util.AttributeImpl; import org.apache.lucene.util.AttributeSource; /** - * A TokenStream enumerates the sequence of tokens, either from - * {@link Field}s of a {@link Document} or from query text. + * A TokenStream enumerates the sequence of tokens from text. *

* This is an abstract class; concrete subclasses are: *

    @@ -124,7 +120,7 @@ public abstract class TokenStream extends AttributeSource implements Closeable { } /** - * Consumers (i.e., {@link IndexWriter}) use this method to advance the stream to + * Consumers (i.e., Lucene's IndexWriter) use this method to advance the stream to * the next token. Implementing classes must implement this method and update * the appropriate {@link AttributeImpl}s with the attributes of the next * token.