|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.io.OutputStream
java.io.FilterOutputStream
org.apache.activemq.transport.tcp.TcpBufferedOutputStream
public class TcpBufferedOutputStream
An optimized buffered outputstream for Tcp
Field Summary |
---|
Fields inherited from class java.io.FilterOutputStream |
---|
out |
Constructor Summary | |
---|---|
TcpBufferedOutputStream(java.io.OutputStream out)
Constructor |
|
TcpBufferedOutputStream(java.io.OutputStream out,
int size)
Creates a new buffered output stream to write data to the specified underlying output stream with the specified buffer size. |
Method Summary | |
---|---|
void |
close()
close this stream |
void |
flush()
flush the data to the output stream This doesn't call flush on the underlying outputstream, because Tcp is particularly efficent at doing this itself .... |
long |
getWriteTimestamp()
|
boolean |
isWriting()
|
void |
write(byte[] b,
int off,
int len)
write a byte array to the stream |
void |
write(int b)
write a byte on to the stream |
Methods inherited from class java.io.FilterOutputStream |
---|
write |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public TcpBufferedOutputStream(java.io.OutputStream out)
out
- public TcpBufferedOutputStream(java.io.OutputStream out, int size)
out
- the underlying output stream.size
- the buffer size.
java.lang.IllegalArgumentException
- if size <= 0.Method Detail |
---|
public void write(int b) throws java.io.IOException
write
in class java.io.FilterOutputStream
b
- - byte to write
java.io.IOException
public void write(byte[] b, int off, int len) throws java.io.IOException
write
in class java.io.FilterOutputStream
b
- the byte bufferoff
- the offset into the bufferlen
- the length of data to write
java.io.IOException
public void flush() throws java.io.IOException
flush
in interface java.io.Flushable
flush
in class java.io.FilterOutputStream
java.io.IOException
public void close() throws java.io.IOException
close
in interface java.io.Closeable
close
in class java.io.FilterOutputStream
java.io.IOException
public boolean isWriting()
isWriting
in interface TimeStampStream
public long getWriteTimestamp()
getWriteTimestamp
in interface TimeStampStream
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |