public class JdbcBlob extends TraceObject implements Blob
ARRAY, BLOB, CALLABLE_STATEMENT, CLOB, CONNECTION, DATA_SOURCE, DATABASE_META_DATA, PARAMETER_META_DATA, PREPARED_STATEMENT, RESULT_SET, RESULT_SET_META_DATA, SAVEPOINT, SQL_EXCEPTION, STATEMENT, trace, XA_DATA_SOURCE, XA_RESOURCE, XID| Constructor and Description |
|---|
JdbcBlob(JdbcConnection conn,
Value value,
int id)
INTERNAL
|
| Modifier and Type | Method and Description |
|---|---|
void |
free()
Release all resources of this object.
|
InputStream |
getBinaryStream()
Returns the input stream.
|
InputStream |
getBinaryStream(long pos,
long length)
[Not supported] Returns the input stream, starting from an offset.
|
byte[] |
getBytes(long pos,
int length)
Returns some bytes of the object.
|
long |
length()
Returns the length.
|
long |
position(Blob blobPattern,
long start)
[Not supported] Searches a pattern and return the position.
|
long |
position(byte[] pattern,
long start)
[Not supported] Searches a pattern and return the position.
|
OutputStream |
setBinaryStream(long pos)
Get a writer to update the Blob.
|
int |
setBytes(long pos,
byte[] bytes)
Fills the Blob.
|
int |
setBytes(long pos,
byte[] bytes,
int offset,
int len)
[Not supported] Sets some bytes of the object.
|
String |
toString()
INTERNAL
|
void |
truncate(long len)
[Not supported] Truncates the object.
|
debugCode, debugCodeAssign, debugCodeCall, debugCodeCall, debugCodeCall, getNextId, getTrace, getTraceId, getTraceObjectName, isDebugEnabled, isInfoEnabled, logAndConvert, quote, quoteArray, quoteBigDecimal, quoteBytes, quoteDate, quoteIntArray, quoteMap, quoteTime, quoteTimestamp, setTrace, unsupportedpublic JdbcBlob(JdbcConnection conn, Value value, int id)
public long length()
throws SQLException
length in interface BlobSQLExceptionpublic void truncate(long len)
throws SQLException
truncate in interface Bloblen - the new lengthSQLExceptionpublic byte[] getBytes(long pos,
int length)
throws SQLException
getBytes in interface Blobpos - the index, the first byte is at position 1length - the number of bytesSQLExceptionpublic int setBytes(long pos,
byte[] bytes)
throws SQLException
setBytes in interface Blobpos - where to start writing (the first byte is at position 1)bytes - the bytes to setSQLExceptionpublic int setBytes(long pos,
byte[] bytes,
int offset,
int len)
throws SQLException
setBytes in interface Blobpos - the write positionbytes - the bytes to setoffset - the bytes offsetlen - the number of bytes to writeSQLExceptionpublic InputStream getBinaryStream() throws SQLException
getBinaryStream in interface BlobSQLExceptionpublic OutputStream setBinaryStream(long pos) throws SQLException
setBinaryStream in interface Blobpos - where to start writing (the first byte is at position 1)SQLExceptionpublic long position(byte[] pattern,
long start)
throws SQLException
position in interface Blobpattern - the pattern to searchstart - the index, the first byte is at position 1SQLExceptionpublic long position(Blob blobPattern, long start) throws SQLException
position in interface BlobblobPattern - the pattern to searchstart - the index, the first byte is at position 1SQLExceptionpublic InputStream getBinaryStream(long pos, long length) throws SQLException
getBinaryStream in interface Blobpos - where to start readinglength - the number of bytes that will be readSQLExceptionCopyright © 2012 JBoss by Red Hat. All Rights Reserved.