public class LocationTrackingReader
extends java.io.Reader
Constructor and Description |
---|
LocationTrackingReader(java.io.Reader delegate) |
LocationTrackingReader(java.io.Reader delegate,
int bufferSize) |
Modifier and Type | Method and Description |
---|---|
void |
close() |
int |
getLineNumber()
get the 0-based line number of the last line read.
|
int |
getLineOffset()
Get the character offset of the first character of the last line read.
|
int |
getOffset()
Get the character offset of the last character read.
|
int |
read() |
int |
read(char[] cbuf,
int off,
int len) |
java.lang.String |
readLine()
Read a line of text, omitting the line delimiters.
|
public LocationTrackingReader(java.io.Reader delegate)
public LocationTrackingReader(java.io.Reader delegate, int bufferSize)
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(char[] cbuf, int off, int len) throws java.io.IOException
read
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 java.lang.String readLine() throws java.io.IOException
java.io.IOException
getLineOffset()
public int getOffset()
public int getLineOffset()
readLine()
.readLine()
public int getLineNumber()
readLine()
.readLine()
Copyright © 2007, 2013 David Green and others.
All rights reserved. This program and the accompanying materials
are made available under the terms of the Eclipse Public License v1.0
which accompanies this distribution, and is available at
http://www.eclipse.org/legal/epl-v10.html