LUCENE-1804: allow Tokenizer to specify it's AttributeSource

git-svn-id: https://svn.apache.org/repos/asf/lucene/java/trunk@803668 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Yonik Seeley 2009-08-12 19:01:43 +00:00
parent f79712ce82
commit ab2afad0d1
1 changed files with 8 additions and 1 deletions

View File

@ -17,6 +17,8 @@ package org.apache.lucene.analysis;
* limitations under the License.
*/
import org.apache.lucene.util.AttributeSource;
import java.io.Reader;
import java.io.IOException;
@ -66,6 +68,11 @@ public abstract class Tokenizer extends TokenStream {
this.input = input;
}
/** Construct a token stream processing the given input using the given AttributeSource. */
protected Tokenizer(AttributeSource source) {
super(source);
}
/** By default, closes the input Reader. */
public void close() throws IOException {
input.close();