public class LineBufferingOutputStream
extends java.io.OutputStream
| Constructor and Description |
|---|
LineBufferingOutputStream(Action<java.lang.String> action) |
LineBufferingOutputStream(Action<java.lang.String> action,
boolean includeEOL) |
LineBufferingOutputStream(Action<java.lang.String> action,
boolean includeEOL,
int bufferLength) |
| Modifier and Type | Method and Description |
|---|---|
void |
close()
Closes this output stream and releases any system resources associated with this stream.
|
void |
flush()
Flushes this output stream and forces any buffered output bytes to be written out.
|
void |
write(int b)
Writes the specified byte to this output stream.
|
public LineBufferingOutputStream(Action<java.lang.String> action)
public LineBufferingOutputStream(Action<java.lang.String> action, boolean includeEOL)
public LineBufferingOutputStream(Action<java.lang.String> action, boolean includeEOL, int bufferLength)
public void close()
throws java.io.IOException
close is that it closes the output stream. A closed stream cannot perform output operations and
cannot be reopened.close in interface java.io.Closeableclose in interface java.lang.AutoCloseableclose in class java.io.OutputStreamjava.io.IOExceptionpublic void write(int b)
throws java.io.IOException
write is that one byte is
written to the output stream. The byte to be written is the eight low-order bits of the argument b.
The 24 high-order bits of b are ignored.write in class java.io.OutputStreamb - the byte to writejava.io.IOException - if an I/O error occurs. In particular, an IOException may be thrown if
the output stream has been closed.public void flush()
flush is that calling it is an indication that, if any bytes previously written have been buffered
by the implementation of the output stream, such bytes should immediately be written to their intended
destination.flush in interface java.io.Flushableflush in class java.io.OutputStreamCopyright © 2013. All rights reserved