ContLineReaderpublic abstract class ContLineReader extends LineNumberReader Subclass of LineNumberReader, parent of others, to allow reading of
continued lines using the readLine() method. The other Reader methods
(readInt()) etc.) must not be used. Must subclass to provide the actual
implementation of readLine(). |
Fields Summary |
---|
protected int | firstLineNumberLine number of first line in current (possibly continued) line | protected boolean | doContinueTrue if handling continuations, false if not; false == "PRE" mode |
Constructors Summary |
---|
public ContLineReader(Reader in)Construct a ContLineReader with the default input-buffer size.
super(in);
| public ContLineReader(Reader in, int sz)Construct a ContLineReader using the given input-buffer size.
super(in, sz);
|
Methods Summary |
---|
public boolean | getContinuationMode()Get the continuation mode
return doContinue;
| public boolean | markSupported()
return false;
| public int | read()Read a single character, returned as an int.
return super.read();
| public int | read(char[] cbuf, int off, int len)Read characters into a portion of an array.
return super.read(cbuf, off, len);
| public abstract java.lang.String | readLine()Read one (possibly continued) line, stripping out the \ that
marks the end of each line but the last in a sequence.
| public java.lang.String | readPhysicalLine()Read one real line. Provided as a convenience for the
subclasses, so they don't embarass themselves trying to
call "super.readLine()" which isn't very practical...
return super.readLine();
| public void | setContinuationMode(boolean b)Set the continuation mode
doContinue = b;
|
|