public class NullOutputStream extends OutputStream
| Constructor and Description |
|---|
NullOutputStream()
Construct a null output stream.
|
| Modifier and Type | Method and Description |
|---|---|
void |
close()
Close an output stream.
|
void |
flush()
Flush an output stream, which does nothing.
|
void |
write(byte[] a,
int offset,
int length)
Write a byte array to the output stream, which is thrown away.
|
void |
write(int b)
Write a byte to the output stream, which is thrown away.
|
writepublic void write(int b)
throws IOException
write in class OutputStreamb - The byte to toss.IOException - If the stream is closed.public void write(byte[] a,
int offset,
int length)
throws IOException
write in class OutputStreama - The array to write.offset - Where in the array to ignore bytes to write.length - How many bytes to ignore.IOException - If the stream is closed.public void flush()
throws IOException
flush in interface Flushableflush in class OutputStreamIOException - If the stream is closed.public void close()
throws IOException
close in interface Closeableclose in interface AutoCloseableclose in class OutputStreamIOException - If the stream is already closed.Copyright © 1999–2017 Apache OODT. All rights reserved.