|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.datanucleus.store.rdbms.datatype.ClobImpl
public class ClobImpl
The mapping in the JavaTM programming language for the SQL CLOB type.
An SQL CLOB is a built-in type that stores a Character Large Object as a column value
in a row of a database table. By default drivers implement a Clob object using an SQL
locator(CLOB), which means that a Clob object contains a logical pointer to the
SQL CLOB data rather than the data itself. A Clob object is valid for the duration
of the transaction in which it was created.
The Clob interface provides methods for getting the length of an SQL CLOB
(Character Large Object) value, for materializing a CLOB value on the client, and for
searching for a substring or CLOB object within a CLOB value.
Methods in the interfaces ResultSet, CallableStatement, and PreparedStatement, such as
getClob and setClob allow a programmer to access an SQL CLOB value.
In addition, this interface has methods for updating a CLOB value.
| Constructor Summary | |
|---|---|
ClobImpl(String string)
Constructor taking a string. |
|
| Method Summary | |
|---|---|
void |
free()
Free the Blob object and releases the resources that it holds. |
InputStream |
getAsciiStream()
|
Reader |
getCharacterStream()
|
Reader |
getCharacterStream(long pos,
long length)
Returns a Reader object that contains a partial Clob value, starting with the character specified by pos, which is length characters in length. |
String |
getSubString(long pos,
int length)
|
long |
length()
|
long |
position(Clob searchstr,
long start)
|
long |
position(String searchstr,
long start)
|
OutputStream |
setAsciiStream(long pos)
|
Writer |
setCharacterStream(long pos)
|
int |
setString(long pos,
String str)
|
int |
setString(long pos,
String str,
int offset,
int len)
|
void |
truncate(long len)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ClobImpl(String string)
throws IOException
string - The string.
IOException| Method Detail |
|---|
public long length()
throws SQLException
length in interface ClobSQLException
public void truncate(long len)
throws SQLException
truncate in interface ClobSQLException
public InputStream getAsciiStream()
throws SQLException
getAsciiStream in interface ClobSQLException
public OutputStream setAsciiStream(long pos)
throws SQLException
setAsciiStream in interface ClobSQLException
public Reader getCharacterStream()
throws SQLException
getCharacterStream in interface ClobSQLException
public Writer setCharacterStream(long pos)
throws SQLException
setCharacterStream in interface ClobSQLException
public void free()
throws SQLException
free in interface ClobSQLException
public Reader getCharacterStream(long pos,
long length)
throws SQLException
getCharacterStream in interface Clobpos - the offset to the first byte of the partial value to be retrieved.
The first byte in the Clob is at position 1length - the length in bytes of the partial value to be retrieved
SQLException
public String getSubString(long pos,
int length)
throws SQLException
getSubString in interface ClobSQLException
public int setString(long pos,
String str)
throws SQLException
setString in interface ClobSQLException
public int setString(long pos,
String str,
int offset,
int len)
throws SQLException
setString in interface ClobSQLException
public long position(String searchstr,
long start)
throws SQLException
position in interface ClobSQLException
public long position(Clob searchstr,
long start)
throws SQLException
position in interface ClobSQLException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||