|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Object
|
+--java.io.OutputStream
|
+--org.metastatic.rsync.v2.MultiplexedOutputStream
Multiplexed output for servers.
| Field Summary | |
|---|---|
protected Statistics |
stats
|
| Fields inherited from interface org.metastatic.rsync.v2.MultiplexedIO |
|---|
FERROR, FINFO, FLOG, FNONE, MPLEX_BASE |
| Constructor Summary | |
|---|---|
MultiplexedOutputStream(OutputStream out,
boolean multiplex)
|
|
| Method Summary | |
|---|---|
void |
flush()
Write any buffered bytes to the stream. |
Statistics |
getStats()
|
void |
setMultiplex(boolean multiplex)
Set multiplexing value. |
void |
setStats(Statistics stats)
|
void |
write(byte[] buf)
Writes a byte array to the stream. |
void |
write(byte[] buf,
int off,
int len)
Writes a portion of a byte array to the stream. |
void |
write(int b)
Write a single byte to the stream. |
protected void |
write(int logcode,
byte[] buf)
|
protected void |
write(int logcode,
byte[] buf,
int off,
int len)
|
void |
writeInt(int i)
Write a four-byte integer to the stream in little-endian byte order. |
void |
writeLong(long l)
Write a long integer to the stream, in little-endian order, writing four bytes if the value fits into four bytes, otherwise writing eight bytes. |
void |
writeMessage(int logcode,
String message)
Write a message to the multiplexed error stream. |
void |
writeString(String s)
|
| Methods inherited from class java.io.OutputStream |
|---|
close |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
protected Statistics stats
| Constructor Detail |
public MultiplexedOutputStream(OutputStream out,
boolean multiplex)
| Method Detail |
public void setStats(Statistics stats)
public Statistics getStats()
public void setMultiplex(boolean multiplex)
multiplex - The new multiplex value.
public void writeMessage(int logcode,
String message)
throws IOException
logcode - The log code.message - The message.
IOException - If an I/O error occurs.
public void flush()
throws IOException
flush in class OutputStreamIOException - If an I/O error occurs.
public void write(byte[] buf)
throws IOException
write in class OutputStreambuf - The bytes to write.
IOException - If an I/O error occurs.
public void write(byte[] buf,
int off,
int len)
throws IOException
write in class OutputStreambuf - The bytes to write.off - The offset from whence to begin.len - The number of bytes to write.
IOException - If an I/O error occurs.
public void write(int b)
throws IOException
write in class OutputStreamIOException - If an I/O error occurs.
public void writeInt(int i)
throws IOException
i - The integer to write.
IOException - If an I/O error occurs.
public void writeLong(long l)
throws IOException
l - The long integer to write.
IOException - If an I/O error occurs.
public void writeString(String s)
throws IOException
IOException
protected void write(int logcode,
byte[] buf)
throws IOException
IOException
protected void write(int logcode,
byte[] buf,
int off,
int len)
throws IOException
IOException
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||