public class MockCharFilter extends CharStream
Constructor and Description |
---|
MockCharFilter(java.io.Reader in) |
MockCharFilter(java.io.Reader in,
int remainder) |
Modifier and Type | Method and Description |
---|---|
protected void |
addOffCorrectMap(int off,
int cumulativeDiff) |
void |
close() |
int |
correctOffset(int currentOff)
Called by CharFilter(s) and Tokenizer to correct token offset.
|
int |
read() |
int |
read(char[] cbuf,
int off,
int len) |
public MockCharFilter(java.io.Reader in, int remainder)
public MockCharFilter(java.io.Reader in)
public void close() throws java.io.IOException
close
in interface java.io.Closeable
close
in interface java.lang.AutoCloseable
close
in class java.io.Reader
java.io.IOException
public int read() throws java.io.IOException
read
in class java.io.Reader
java.io.IOException
public int read(char[] cbuf, int off, int len) throws java.io.IOException
read
in class java.io.Reader
java.io.IOException
public int correctOffset(int currentOff)
CharStream
correctOffset
in class CharStream
currentOff
- offset as seen in the outputprotected void addOffCorrectMap(int off, int cumulativeDiff)
Copyright © 2000-2019 Apache Software Foundation. All Rights Reserved.