LUCENE-7382: Fix bug introduced by LUCENE-7355 that used the wrong default AttributeFactory for new Tokenizers

This commit is contained in:
Uwe Schindler 2016-07-16 10:09:40 +02:00
parent 833c8ee152
commit 2585c9f3ff
2 changed files with 6 additions and 2 deletions

View File

@ -65,6 +65,10 @@ Bug Fixes
* LUCENE-7340: MemoryIndex.toString() could throw NPE; fixed. Renamed to toStringDebug().
(Daniel Collins, David Smiley)
* LUCENE-7382: Fix bug introduced by LUCENE-7355 that used the
wrong default AttributeFactory for new Tokenizers.
(Terry Smith, Uwe Schindler)
Improvements
* LUCENE-7323: Compound file writing now verifies the incoming

View File

@ -287,9 +287,9 @@ public abstract class Analyzer implements Closeable {
/** Return the {@link AttributeFactory} to be used for
* {@link #tokenStream analysis} and
* {@link #normalize(String, String) normalization}. The default
* implementation returns {@link AttributeFactory#DEFAULT_ATTRIBUTE_FACTORY}. */
* implementation returns {@link TokenStream#DEFAULT_TOKEN_ATTRIBUTE_FACTORY}. */
protected AttributeFactory attributeFactory() {
return AttributeFactory.DEFAULT_ATTRIBUTE_FACTORY;
return TokenStream.DEFAULT_TOKEN_ATTRIBUTE_FACTORY;
}
/**