|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.mindbright.nio.NonBlockingOutput
public class NonBlockingOutput
A non-blocking output stream.
Constructor Summary | |
---|---|
|
NonBlockingOutput(java.nio.channels.Pipe pipe)
Creates a new NonBlockingOutput object which sends any output to a pipe. |
|
NonBlockingOutput(java.lang.String name)
Creates a new NonBlockingOutput object which sends any output to a file. |
protected |
NonBlockingOutput(Switchboard switchboard,
java.nio.channels.spi.AbstractInterruptibleChannel channel)
|
Method Summary | |
---|---|
protected void |
clearWriteWaiting()
|
void |
close()
Close the underlying stream. |
void |
flush()
Tries to flush any bytes to the underlying stream |
void |
write(byte[] data)
Writes all the bytes in the provided buffer to the stream |
void |
write(byte[] data,
int offset,
int length)
Writes the indicated part of the buffer to the stream |
void |
write(int data)
Writes the specified byte |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
protected NonBlockingOutput(Switchboard switchboard, java.nio.channels.spi.AbstractInterruptibleChannel channel) throws java.io.IOException
java.io.IOException
public NonBlockingOutput(java.nio.channels.Pipe pipe) throws java.io.IOException
pipe
- Pipe to send output to
java.io.IOException
public NonBlockingOutput(java.lang.String name) throws java.io.IOException
name
- Name of file to store data in
java.io.IOException
Method Detail |
---|
public void write(int data) throws java.io.IOException
java.io.IOException
public void write(byte[] data) throws java.io.IOException
java.io.IOException
public void write(byte[] data, int offset, int length) throws java.io.IOException
java.io.IOException
protected void clearWriteWaiting()
public void flush()
public void close() throws java.io.IOException
java.io.IOException
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |