public class PgBufferedOutputStream
extends java.io.FilterOutputStream
BufferedOutputStream is that
PgBufferedOutputStream does not perform synchronization.
This is an internal class, and it is not meant to be used as a public API.| Modifier and Type | Field and Description |
|---|---|
protected byte[] |
buf
Buffer for the data
|
protected int |
count
Number of bytes stored in the buffer
|
| Constructor and Description |
|---|
PgBufferedOutputStream(java.io.OutputStream out,
int bufferSize) |
| Modifier and Type | Method and Description |
|---|---|
void |
flush() |
protected void |
flushBuffer() |
void |
write(byte[] b,
int off,
int len) |
void |
write(java.io.InputStream inStream,
int remaining)
Writes the given amount of bytes from an input stream to this buffered stream.
|
void |
write(int b) |
void |
writeInt2(int val) |
void |
writeInt4(int val) |
void |
writeZeros(int len)
Writes the required number of zero bytes to the output stream.
|
protected final byte[] buf
protected int count
public PgBufferedOutputStream(java.io.OutputStream out,
int bufferSize)
protected void flushBuffer()
throws java.io.IOException
java.io.IOExceptionpublic void flush()
throws java.io.IOException
flush in interface java.io.Flushableflush in class java.io.FilterOutputStreamjava.io.IOExceptionpublic void writeInt2(int val)
throws java.io.IOException
java.io.IOExceptionpublic void writeInt4(int val)
throws java.io.IOException
java.io.IOExceptionpublic void write(int b)
throws java.io.IOException
write in class java.io.FilterOutputStreamjava.io.IOExceptionpublic void write(byte[] b,
int off,
int len)
throws java.io.IOException
write in class java.io.FilterOutputStreamjava.io.IOExceptionpublic void write(java.io.InputStream inStream,
int remaining)
throws java.io.IOException
inStream - input dataremaining - the number of bytes to transferjava.io.IOException - in case writing to the output stream failsSourceStreamIOException - in case reading from the source stream failspublic void writeZeros(int len)
throws java.io.IOException
len - number of bytes to writejava.io.IOException - in case writing to the underlying stream failsCopyright © 2025 PostgreSQL Global Development Group. All rights reserved.