Package org.postgresql.core
Class FixedLengthOutputStream
- java.lang.Object
-
- java.io.OutputStream
-
- org.postgresql.core.FixedLengthOutputStream
-
- All Implemented Interfaces:
java.io.Closeable
,java.io.Flushable
,java.lang.AutoCloseable
public class FixedLengthOutputStream extends java.io.OutputStream
A stream that refuses to write more than a maximum number of bytes.
-
-
Constructor Summary
Constructors Constructor Description FixedLengthOutputStream(int size, java.io.OutputStream target)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
remaining()
void
write(byte[] buf, int offset, int len)
void
write(int b)
-
-
-
Method Detail
-
write
public void write(int b) throws java.io.IOException
- Specified by:
write
in classjava.io.OutputStream
- Throws:
java.io.IOException
-
write
public void write(byte[] buf, int offset, int len) throws java.io.IOException
- Overrides:
write
in classjava.io.OutputStream
- Throws:
java.io.IOException
-
remaining
public int remaining()
-
-