java.lang.Object
java.io.InputStream
org.postgresql.pljava.jdbc.BlobValue
- All Implemented Interfaces:
Closeable,AutoCloseable,Blob
Implementation of
Blob for the SPI connection.- Author:
- Thomas Hallgren
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionintvoidfree()getBinaryStream(long pos, long length) byte[]getBytes(long pos, int length) voidgetContents(ByteBuffer buf) Called from within...static intgetStreamLength(InputStream value) longlength()voidmark(int readLimit) booleanlongposition(byte[] pattern, long start) Not supported.longNot supported.intread()intread(byte[] b) intread(byte[] b, int off, int len) voidreset()setBinaryStream(long pos) In this method is not supported byBlobValueintsetBytes(long pos, byte[] bytes) In this method is not supported byBlobValueintsetBytes(long pos, byte[] bytes, int offset, int len) In this method is not supported byBlobValuelongskip(long nBytes) voidtruncate(long len) In this method is not supported byBlobValueMethods inherited from class java.io.InputStream
close, nullInputStream, readAllBytes, readNBytes, readNBytes, skipNBytes, transferTo
-
Constructor Details
-
BlobValue
public BlobValue(byte[] bytes) -
BlobValue
-
-
Method Details
-
getStreamLength
- Throws:
SQLException
-
available
- Overrides:
availablein classInputStream- Throws:
IOException
-
getBinaryStream
- Specified by:
getBinaryStreamin interfaceBlob
-
getBytes
- Specified by:
getBytesin interfaceBlob- Throws:
SQLException
-
getContents
Called from within...- Parameters:
buf- a buffer that reflects the internally allocated bytea buffer. This size of this buffer will be exactly the size returned by a call tolength().- Throws:
IOException
-
length
public long length() -
mark
public void mark(int readLimit) - Overrides:
markin classInputStream
-
markSupported
public boolean markSupported()- Overrides:
markSupportedin classInputStream
-
position
Not supported. -
position
public long position(byte[] pattern, long start) Not supported. -
read
- Specified by:
readin classInputStream- Throws:
IOException
-
read
- Overrides:
readin classInputStream- Throws:
IOException
-
read
- Overrides:
readin classInputStream- Throws:
IOException
-
reset
- Overrides:
resetin classInputStream- Throws:
IOException
-
setBinaryStream
In this method is not supported byBlobValue- Specified by:
setBinaryStreamin interfaceBlob
-
setBytes
public int setBytes(long pos, byte[] bytes) In this method is not supported byBlobValue -
setBytes
public int setBytes(long pos, byte[] bytes, int offset, int len) In this method is not supported byBlobValue -
skip
- Overrides:
skipin classInputStream- Throws:
IOException
-
truncate
public void truncate(long len) In this method is not supported byBlobValue -
getBinaryStream
- Specified by:
getBinaryStreamin interfaceBlob- Throws:
SQLException
-
free
- Specified by:
freein interfaceBlob- Throws:
SQLException
-