Package com.impossibl.postgres.jdbc
Class PGBufferBlob
- java.lang.Object
-
- com.impossibl.postgres.jdbc.PGBufferBlob
-
-
Constructor Summary
Constructors Constructor Description PGBufferBlob(io.netty.buffer.ByteBuf buffer)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
free()
InputStream
getBinaryStream()
InputStream
getBinaryStream(long pos, long length)
byte[]
getBytes(long pos, int length)
long
length()
long
position(byte[] pattern, long start)
long
position(Blob pattern, long start)
OutputStream
setBinaryStream(long pos)
int
setBytes(long pos, byte[] bytes)
int
setBytes(long pos, byte[] bytes, int bytesOff, int bytesLen)
void
truncate(long len)
-
-
-
Method Detail
-
length
public long length() throws SQLException
- Specified by:
length
in interfaceBlob
- Throws:
SQLException
-
getBytes
public byte[] getBytes(long pos, int length) throws SQLException
- Specified by:
getBytes
in interfaceBlob
- Throws:
SQLException
-
getBinaryStream
public InputStream getBinaryStream() throws SQLException
- Specified by:
getBinaryStream
in interfaceBlob
- Throws:
SQLException
-
position
public long position(byte[] pattern, long start) throws SQLException
- Specified by:
position
in interfaceBlob
- Throws:
SQLException
-
position
public long position(Blob pattern, long start) throws SQLException
- Specified by:
position
in interfaceBlob
- Throws:
SQLException
-
setBytes
public int setBytes(long pos, byte[] bytes) throws SQLException
- Specified by:
setBytes
in interfaceBlob
- Throws:
SQLException
-
setBytes
public int setBytes(long pos, byte[] bytes, int bytesOff, int bytesLen) throws SQLException
- Specified by:
setBytes
in interfaceBlob
- Throws:
SQLException
-
setBinaryStream
public OutputStream setBinaryStream(long pos) throws SQLException
- Specified by:
setBinaryStream
in interfaceBlob
- Throws:
SQLException
-
truncate
public void truncate(long len) throws SQLException
- Specified by:
truncate
in interfaceBlob
- Throws:
SQLException
-
getBinaryStream
public InputStream getBinaryStream(long pos, long length) throws SQLException
- Specified by:
getBinaryStream
in interfaceBlob
- Throws:
SQLException
-
-