|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object java.io.Writer java.io.FilterWriter org.geotools.io.NumberedLineWriter
A writer that put line number in front of every line.
Field Summary | |
static java.io.PrintWriter |
OUT
A default numbered line writer to the standard output stream. |
Fields inherited from class java.io.FilterWriter |
out |
Fields inherited from class java.io.Writer |
lock |
Constructor Summary | |
NumberedLineWriter(java.io.Writer out)
Constructs a stream which will write line number in front of each line. |
Method Summary | |
int |
getLineNumber()
Returns the current line number. |
void |
setLineNumber(int line)
Sets the current line number. |
void |
write(char[] buffer,
int offset,
int length)
Writes a portion of an array of characters. |
void |
write(int c)
Writes a single character. |
void |
write(java.lang.String string,
int offset,
int length)
Writes a portion of a string. |
Methods inherited from class java.io.FilterWriter |
close, flush |
Methods inherited from class java.io.Writer |
write, write |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final java.io.PrintWriter OUT
FilterWriter.close()
method on this stream will only flush it without closing it.
Constructor Detail |
public NumberedLineWriter(java.io.Writer out)
out
- a Writer object to provide the underlying stream.Method Detail |
public int getLineNumber()
public void setLineNumber(int line)
line
- The current line number.public void write(int c) throws java.io.IOException
java.io.IOException
- If an I/O error occurspublic void write(char[] buffer, int offset, int length) throws java.io.IOException
buffer
- Buffer of characters to be writtenoffset
- Offset from which to start reading characterslength
- Number of characters to be written
java.io.IOException
- If an I/O error occurspublic void write(java.lang.String string, int offset, int length) throws java.io.IOException
string
- String to be writtenoffset
- Offset from which to start reading characterslength
- Number of characters to be written
java.io.IOException
- If an I/O error occurs
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |