|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.io.OutputStream
com.caucho.vfs.OutputStreamWithBuffer
com.caucho.vfs.WriteStream
com.caucho.vfs.NullWriteStream
public class NullWriteStream
A WriteStream that writes to nothing.
Constructor Summary | |
---|---|
NullWriteStream()
|
Method Summary | |
---|---|
boolean |
canWrite()
Returns true if the buffer allows writes. |
void |
flush()
Flushes the buffer to the source. |
void |
write(byte[] buf)
Writes a byte array. |
void |
write(byte[] buf,
int offset,
int length)
Writes a byte array |
void |
write(int ch)
Writes a byte. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public NullWriteStream()
Method Detail |
---|
public boolean canWrite()
WriteStream
LogStreams, used for debugging, use this feature to
test if they should write with very little overhead.
if (dbg.canWrite())
dbg.log("some debug value " + expensiveDebugCalculation(foo));
canWrite
in class WriteStream
public void write(int ch) throws java.io.IOException
write
in interface ByteAppendable
write
in class WriteStream
java.io.IOException
public void write(byte[] buf, int offset, int length) throws java.io.IOException
write
in interface ByteAppendable
write
in class WriteStream
java.io.IOException
public void write(byte[] buf) throws java.io.IOException
write
in class WriteStream
java.io.IOException
public void flush() throws java.io.IOException
flush
in interface java.io.Flushable
flush
in class WriteStream
java.io.IOException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |