Package oracle.sql
Class CLOB
- java.lang.Object
-
- oracle.sql.Datum
-
- oracle.sql.DatumWithConnection
-
- oracle.sql.CLOB
-
- All Implemented Interfaces:
java.io.Serializable
,java.sql.Clob
,oracle.jdbc.internal.ACProxyable
,oracle.jdbc.internal.OracleClob
,oracle.jdbc.internal.OracleConcreteProxy
,oracle.jdbc.internal.OracleDatumWithConnection
,oracle.jdbc.internal.OracleLargeObject<char[]>
,OracleClob
- Direct Known Subclasses:
NCLOB
public class CLOB extends DatumWithConnection implements oracle.jdbc.internal.OracleClob, oracle.jdbc.internal.OracleConcreteProxy
Deprecated.Use java.sql.Clob interface for declaration instead of using concrete class oracle.sql.CLOB.This class implements java.sql.Clob interface in JDBC.2.0. Use java.sql.Clob interface for declaration instead of using concrete class oracle.sql.CLOB. java.sql.Clob has methods declared for all opertions. For Oracle specific methods use the interface oracle.jdbc.OracleClob. There is no need for the user to bother about chunk sizes any more it is taken care of internally.Obtaining java.sql.Clob from ResultSet
java.sql.Clob clob = resultSet.getClob(...);
Creating a temporary Clob should use
Connection.createClob()
java.sql.Clob clob = connection.createClob();
- See Also:
Clob
,OracleClob
,Connection.createClob()
, Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static int
DURATION_CALL
Deprecated.static int
DURATION_INVALID
Deprecated.static int
DURATION_SESSION
Deprecated.static int
MAX_CHUNK_SIZE
Deprecated.static int
MODE_READONLY
Deprecated.static int
MODE_READWRITE
Deprecated.static int
OLD_WRONG_DURATION_CALL
Deprecated.static int
OLD_WRONG_DURATION_SESSION
Deprecated.protected oracle.jdbc.driver.OracleClob
target
Deprecated.-
Fields inherited from class oracle.sql.DatumWithConnection
targetDatumWithConnection
-
Fields inherited from class oracle.sql.Datum
ojiOracleDatumWithConnection, targetDatum
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
CLOB()
Deprecated.protected
CLOB(oracle.jdbc.driver.OracleClob c)
Deprecated.Call from empty lob static methodCLOB(OracleConnection conn, byte[] lob_descriptor, short csform)
Deprecated.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description boolean
canReadBasicLobDataInLocator()
Deprecated.Can the lob data be read directly from the locator?void
close()
Deprecated.Close a previously opened CLOB.static CLOB
createTemporary(java.sql.Connection conn, boolean cache, int _duration)
Deprecated.Create a temporary clob.static CLOB
createTemporary(java.sql.Connection conn, boolean cache, int _duration, short form_of_use)
Deprecated.Create a temporary clob or nclob.static CLOB
empty_lob()
Deprecated.use getEmptyCLOB insteadvoid
free()
Deprecated.Free the resources the clob holds.void
freeLOB()
Deprecated.void
freeTemporary()
Deprecated.Free the contents and the locator of the temporary clob.static void
freeTemporary(CLOB temp_lob)
Deprecated.Free the contents and the locator of the temporary clob.java.io.OutputStream
getAsciiOutputStream()
Deprecated.This method is deprecated.java.io.OutputStream
getAsciiOutputStream(long pos)
Deprecated.This method is deprecated.java.io.InputStream
getAsciiStream()
Deprecated.Implements the Clob interface method.java.io.InputStream
getAsciiStream(boolean isInternal)
Deprecated.Implements the Clob interface method.java.io.InputStream
getAsciiStream(long pos)
Deprecated.Read from the CLOB as a stream at the requested position.int
getBufferSize()
Deprecated.Oracle extension.java.io.Writer
getCharacterOutputStream()
Deprecated.This method is deprecated.java.io.Writer
getCharacterOutputStream(long pos)
Deprecated.This method is deprecated.java.io.Reader
getCharacterStream()
Deprecated.Implements the Clob interface method.java.io.Reader
getCharacterStream(long pos)
Deprecated.Read from the CLOB as a stream at the requested position.java.io.Reader
getCharacterStream(long pos, long length)
Deprecated.Return a character stream beginning at the specified position and ofthe specified length.int
getChars(long pos, int length, char[] buffer)
Deprecated.Oracle extension.int
getChunkSize()
Deprecated.Oracle extension.short
getDuration()
Deprecated.return the duration of a temporary LOBstatic short
getDuration(CLOB lob)
Deprecated.return the duration of a temporary LOBstatic CLOB
getEmptyCLOB()
Deprecated.Return a empty lob.static short
getFormOfUseFromLocator(byte[] lob_descriptor)
Deprecated.java.sql.Connection
getJavaSqlConnection()
Deprecated.Oracle extension Return the java.sql.Connection associated with the receiver.oracle.jdbc.internal.OracleLargeObject.PrefetchData<char[]>
getPrefetchData()
Deprecated.int
getPrefetchedDataSize()
Deprecated.java.lang.String
getSubString(long pos, int length)
Deprecated.Implements the Clob interface method.oracle.jdbc.driver.OracleClob
getTarget()
Deprecated.boolean
isConvertibleTo(java.lang.Class<?> jClass)
Deprecated.Test whether this data object can be converted to the specified Java data type.boolean
isEmptyLob()
Deprecated.Return true if this is a empty lob.boolean
isFree()
Deprecated.boolean
isNCLOB()
Deprecated.boolean
isOpen()
Deprecated.Check whether the CLOB is opened.boolean
isSecureFile()
Deprecated.Returnstrue
if this is a SecureFile (LOBs with the STORE AS SECUREFILE option, which were introduced in Oracle Database 11g Release 1).boolean
isTemporary()
Deprecated.Return true if the lob locator points to a temporary clob.static boolean
isTemporary(CLOB lob)
Deprecated.Return true if the lob locator points to a temporary clob.long
length()
Deprecated.Implements the Clob interface method.void
open(LargeObjectAccessMode mode)
Deprecated.Public method using enum instead of intlong
position(java.lang.String searchstr, long start)
Deprecated.Implements the Clob interface method.long
position(java.sql.Clob searchstr, long start)
Deprecated.Implements the Clob interface method.int
putChars(long pos, char[] chars)
Deprecated.Oracle extension.int
putChars(long pos, char[] chars, int length)
Deprecated.Oracle extension.int
putChars(long pos, char[] chars, int offset, int length)
Deprecated.Oracle extension.int
putString(long pos, java.lang.String str)
Deprecated.This method is deprecated -- use setString.java.io.OutputStream
setAsciiStream(long pos)
Deprecated.JDBC 3.0 Retrieves a stream to be used to write Ascii characters to theCLOB
value that thisClob
object represents, starting at positionpos
.void
setBytes(byte[] locator)
Deprecated.Sets datum value using a byte array.java.io.Writer
setCharacterStream(long pos)
Deprecated.JDBC 3.0 Retrieves a stream to be used to write a stream of Unicode characters to theCLOB
value that thisClob
object represents, at positionpos
.void
setPrefetchData(oracle.jdbc.internal.OracleLargeObject.PrefetchData<char[]> prefetchData)
Deprecated.int
setString(long pos, java.lang.String str)
Deprecated.JDBC 3.0 Writes the given JavaString
to theCLOB
value that thisClob
object designates at the positionpos
.int
setString(long pos, java.lang.String str, int offset, int len)
Deprecated.JDBC 3.0 Writeslen
characters ofstr
, starting at characteroffset
, to theCLOB
value that thisClob
represents.java.lang.String
stringValue()
Deprecated.Convert to a String representation of the datum objectjava.lang.Object
toJdbc()
Deprecated.Convert this data object into its default Java object type.java.sql.SQLXML
toSQLXML()
Deprecated.Returns an object which impements java.sql.SQLXML with content take from this Clob.java.sql.SQLXML
toSQLXML(java.lang.String schemaURL)
Deprecated.Returns an object which impements java.sql.SQLXML with content taken from this Clob.void
trim(long newlen)
Deprecated.This method is deprecated.void
truncate(long len)
Deprecated.JDBC 3.0 Truncates theCLOB
value that thisClob
designates to have a length oflen
characters.-
Methods inherited from class oracle.sql.DatumWithConnection
assertNotNull, assertNotNull, getConnection, getConnectionDuringExceptionHandling, getOracleConnection
-
Methods inherited from class oracle.sql.Datum
bigDecimalValue, booleanValue, bytesEqual, bytesHashCode, byteValue, compareBytes, dateValue, doubleValue, equals, floatValue, getBytes, getLength, getStream, intValue, isNull, longValue, setShareBytes, shareBytes, stringValue, timestampValue, timestampValue, timeValue, timeValue, toClass
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface oracle.jdbc.internal.OracleDatumWithConnection
bigDecimalValue, booleanValue, byteValue, dateValue, doubleValue, floatValue, getBytes, getConnection, getInternalConnection, getLength, getOracleConnection, getStream, intValue, longValue, setPhysicalConnectionOf, setShareBytes, shareBytes, stringValue, timestampValue, timestampValue, timeValue, timeValue
-
-
-
-
Field Detail
-
MAX_CHUNK_SIZE
public static final int MAX_CHUNK_SIZE
Deprecated.- See Also:
- Constant Field Values
-
DURATION_INVALID
public static final int DURATION_INVALID
Deprecated.- See Also:
- Constant Field Values
-
DURATION_SESSION
public static final int DURATION_SESSION
Deprecated.- See Also:
- Constant Field Values
-
DURATION_CALL
public static final int DURATION_CALL
Deprecated.- See Also:
- Constant Field Values
-
OLD_WRONG_DURATION_SESSION
public static final int OLD_WRONG_DURATION_SESSION
Deprecated.- See Also:
- Constant Field Values
-
OLD_WRONG_DURATION_CALL
public static final int OLD_WRONG_DURATION_CALL
Deprecated.- See Also:
- Constant Field Values
-
MODE_READONLY
public static final int MODE_READONLY
Deprecated.- See Also:
- Constant Field Values
-
MODE_READWRITE
public static final int MODE_READWRITE
Deprecated.- See Also:
- Constant Field Values
-
target
protected oracle.jdbc.driver.OracleClob target
Deprecated.
-
-
Constructor Detail
-
CLOB
protected CLOB()
Deprecated.
-
CLOB
protected CLOB(oracle.jdbc.driver.OracleClob c)
Deprecated.Call from empty lob static method
-
CLOB
public CLOB(OracleConnection conn, byte[] lob_descriptor, short csform) throws java.sql.SQLException
Deprecated.- Throws:
java.sql.SQLException
-
-
Method Detail
-
getTarget
public oracle.jdbc.driver.OracleClob getTarget()
Deprecated.
-
getFormOfUseFromLocator
public static final short getFormOfUseFromLocator(byte[] lob_descriptor)
Deprecated.
-
isNCLOB
public boolean isNCLOB()
Deprecated.- Specified by:
isNCLOB
in interfaceoracle.jdbc.internal.OracleClob
- Returns:
- true if the data is bound for a SQL NCHAR datatype false otherwise
-
length
public long length() throws java.sql.SQLException
Deprecated.Implements the Clob interface method. Returns the number of characters in theCLOB
value designated by thisClob
object.- Specified by:
length
in interfacejava.sql.Clob
- Returns:
- length of the
CLOB
in characters - Throws:
java.sql.SQLException
- if there is an error accessing the length of theCLOB
-
getSubString
public java.lang.String getSubString(long pos, int length) throws java.sql.SQLException
Deprecated.Implements the Clob interface method. Returns a copy of the specified substring in theCLOB
value designated by thisClob
object. The substring begins at positionpos
and has up tolength
consecutive characters.- Specified by:
getSubString
in interfacejava.sql.Clob
- Parameters:
pos
- the first character of the substring to be extracted. The first character is at position 1.length
- the number of consecutive characters to be copied- Returns:
- a
String
that is the specified substring in theCLOB
value designated by thisClob
object. If thepos
argument is larger than the length of the data the result is an emptyString
. If thepos
argument is less than the length of the data, but the sum ofpos
argument and thelength
is greater than the length of the data, the result will be smaller than the length requested. - Throws:
java.sql.SQLException
- if there is an error accessing theCLOB
-
getCharacterStream
public java.io.Reader getCharacterStream() throws java.sql.SQLException
Deprecated.Implements the Clob interface method. Gets theClob
contents as a Unicode stream.- Specified by:
getCharacterStream
in interfacejava.sql.Clob
- Returns:
- a Unicode stream containing the
CLOB
data - Throws:
java.sql.SQLException
- if there is an error accessing theCLOB
-
getAsciiStream
public java.io.InputStream getAsciiStream() throws java.sql.SQLException
Deprecated.Implements the Clob interface method. Gets theCLOB
value designated by thisClob
object as a stream of Ascii bytes.- Specified by:
getAsciiStream
in interfacejava.sql.Clob
- Returns:
- an ascii stream containing the
CLOB
data - Throws:
java.sql.SQLException
- if there is an error accessing theCLOB
value
-
getAsciiStream
public java.io.InputStream getAsciiStream(boolean isInternal) throws java.sql.SQLException
Deprecated.Implements the Clob interface method. Gets theCLOB
value designated by thisClob
object as a stream of Ascii bytes.- Returns:
- an ascii stream containing the
CLOB
data - Throws:
java.sql.SQLException
- if there is an error accessing theCLOB
value
-
position
public long position(java.lang.String searchstr, long start) throws java.sql.SQLException
Deprecated.Implements the Clob interface method. Determine the character position at which the given substring- Specified by:
position
in interfacejava.sql.Clob
- Parameters:
searchstr
- is the substring to search for.start
- is the position at which to begin searching.- Returns:
- the position at which the substring appears, else -1.
- Throws:
java.sql.SQLException
-
position
public long position(java.sql.Clob searchstr, long start) throws java.sql.SQLException
Deprecated.Implements the Clob interface method. Determine the character position at which the given substring- Specified by:
position
in interfacejava.sql.Clob
- Parameters:
searchstr
- is the substring to search for.start
- is the position at which to begin searching.- Returns:
- the position at which the substring appears, else -1.
- Throws:
java.sql.SQLException
-
getChars
public int getChars(long pos, int length, char[] buffer) throws java.sql.SQLException
Deprecated.Oracle extension. Return copy of the substring of the CLOB at the requested position.- Specified by:
getChars
in interfaceoracle.jdbc.internal.OracleClob
- Parameters:
buffer
- is the buffer into whcih the characters are read.pos
- is the first character of the substring to be extracted.length
- is the number of consecutive character to be copied.- Returns:
- the actual number of characters read.
- Throws:
java.sql.SQLException
-
getCharacterOutputStream
public java.io.Writer getCharacterOutputStream() throws java.sql.SQLException
Deprecated.This method is deprecated. Use setCharacterStream( 1L ).Oracle extension. Write Unicode stream to the CLOB.- Specified by:
getCharacterOutputStream
in interfaceoracle.jdbc.internal.OracleClob
- Returns:
- a Unicode character output stream.
- Throws:
java.sql.SQLException
-
getAsciiOutputStream
public java.io.OutputStream getAsciiOutputStream() throws java.sql.SQLException
Deprecated.This method is deprecated. Use setAsciiStream( 1L );Oracle extension. Write ascii stream to the CLOB.- Specified by:
getAsciiOutputStream
in interfaceoracle.jdbc.internal.OracleClob
- Returns:
- a ascii output stream.
- Throws:
java.sql.SQLException
-
putChars
public int putChars(long pos, char[] chars) throws java.sql.SQLException
Deprecated.Oracle extension. Write characters at the requested position.- Specified by:
putChars
in interfaceoracle.jdbc.internal.OracleClob
- Parameters:
pos
- is the position to write characters.chars
- is the buffer of characters to be written.- Returns:
- the actual number of characters written.
- Throws:
java.sql.SQLException
-
putChars
public int putChars(long pos, char[] chars, int length) throws java.sql.SQLException
Deprecated.Oracle extension. Write characters at the requested position.- Parameters:
pos
- is the position to write characters.chars
- is the buffer of characters to be written.length
- is the length to write- Returns:
- the actual number of characters written.
- Throws:
java.sql.SQLException
-
putChars
public int putChars(long pos, char[] chars, int offset, int length) throws java.sql.SQLException
Deprecated.Oracle extension. Write characters at the requested position.- Specified by:
putChars
in interfaceoracle.jdbc.internal.OracleClob
- Parameters:
pos
- is the position to write characters.chars
- is the buffer of characters to be written.offset
- is the position in the buffer from which to beginlength
- is the length to write- Returns:
- the actual number of characters written.
- Throws:
java.sql.SQLException
-
putString
public int putString(long pos, java.lang.String str) throws java.sql.SQLException
Deprecated.This method is deprecated -- use setString.Oracle extension. Write String to a CLOB This method provides support to return a 32-bit specification of the number of characters written to the CLOB.- Specified by:
putString
in interfaceoracle.jdbc.internal.OracleClob
- Throws:
java.sql.SQLException
-
getChunkSize
public int getChunkSize() throws java.sql.SQLException
Deprecated.Oracle extension. Get database LOB storage chunk size. There is no need for the user to use this, since the driver does the read and writes in chunk sizes internally.- Specified by:
getChunkSize
in interfaceoracle.jdbc.internal.OracleClob
- Returns:
- the size in terms of characters.
- Throws:
java.sql.SQLException
-
getBufferSize
public int getBufferSize() throws java.sql.SQLException
Deprecated.Oracle extension. Get ideal LOB db access buffer size.- Specified by:
getBufferSize
in interfaceoracle.jdbc.internal.OracleClob
- Returns:
- the size in terms of characters.
- Throws:
java.sql.SQLException
-
empty_lob
public static CLOB empty_lob() throws java.sql.SQLException
Deprecated.use getEmptyCLOB insteadReturn a empty lob. An empty lob is used initialize a LOB column/attribute. Note: an empty lob can not be read or written- Returns:
- a empty lob
- Throws:
java.sql.SQLException
- Since:
- 8.1.7
-
getEmptyCLOB
public static CLOB getEmptyCLOB() throws java.sql.SQLException
Deprecated.Return a empty lob. An empty lob is used initialize a LOB column/attribute. Note: an empty lob can not be read or written- Returns:
- a empty lob
- Throws:
java.sql.SQLException
- Since:
- 10.2
-
isEmptyLob
public boolean isEmptyLob() throws java.sql.SQLException
Deprecated.Return true if this is a empty lob.- Specified by:
isEmptyLob
in interfaceOracleClob
- Returns:
- true if this is a empty lob. This method supports only Clobs that are not returned from the database. For Clobs returned from the database, use length(), i.e. check for zero length
- Throws:
java.sql.SQLException
- Since:
- 8.1.7
- See Also:
empty_lob()
-
isSecureFile
public boolean isSecureFile() throws java.sql.SQLException
Deprecated.Returnstrue
if this is a SecureFile (LOBs with the STORE AS SECUREFILE option, which were introduced in Oracle Database 11g Release 1).- Specified by:
isSecureFile
in interfaceOracleClob
- Returns:
true
if this is a SecureFile andfalse
otherwise.- Throws:
java.sql.SQLException
-
getAsciiOutputStream
public java.io.OutputStream getAsciiOutputStream(long pos) throws java.sql.SQLException
Deprecated.This method is deprecated. Use setAsciiStream.Write to the CLOB from a stream at the requested position.- Specified by:
getAsciiOutputStream
in interfaceoracle.jdbc.internal.OracleClob
- Parameters:
pos
- is the position data to be put.- Returns:
- a output stream to write data to the CLOB
- Throws:
java.sql.SQLException
- Since:
- 8.2.0
-
getCharacterOutputStream
public java.io.Writer getCharacterOutputStream(long pos) throws java.sql.SQLException
Deprecated.This method is deprecated. Use setCharacterStream.Write to the CLOB from a stream at the requested position.- Specified by:
getCharacterOutputStream
in interfaceoracle.jdbc.internal.OracleClob
- Parameters:
pos
- is the position data to be put.- Returns:
- a output stream to write data to the CLOB
- Throws:
java.sql.SQLException
- Since:
- 8.2.0
-
getAsciiStream
public java.io.InputStream getAsciiStream(long pos) throws java.sql.SQLException
Deprecated.Read from the CLOB as a stream at the requested position.- Specified by:
getAsciiStream
in interfaceoracle.jdbc.internal.OracleClob
- Parameters:
pos
- is the position data to be put.- Returns:
- a input stream to read data from the CLOB
- Throws:
java.sql.SQLException
- Since:
- 8.2.0
-
getCharacterStream
public java.io.Reader getCharacterStream(long pos) throws java.sql.SQLException
Deprecated.Read from the CLOB as a stream at the requested position.- Specified by:
getCharacterStream
in interfaceoracle.jdbc.internal.OracleClob
- Parameters:
pos
- is the position data to be put.- Returns:
- a input stream to read data from the CLOB
- Throws:
java.sql.SQLException
- Since:
- 8.2.0
-
trim
public void trim(long newlen) throws java.sql.SQLException
Deprecated.This method is deprecated. Use truncate().Trim the value of the CLOB to the length you specify in the newlen parameter.- Specified by:
trim
in interfaceoracle.jdbc.internal.OracleClob
- Parameters:
newlen
- the new length of the CLOB.- Throws:
java.sql.SQLException
- Since:
- 8.2.0
-
createTemporary
public static CLOB createTemporary(java.sql.Connection conn, boolean cache, int _duration) throws java.sql.SQLException
Deprecated.Create a temporary clob.- Parameters:
cache
- Specifies if LOB should be read into buffer cache or not._duration
- The duration of the temporary LOB. The following are valid values: DURATION_SESSION, DURATION_CALL.- Returns:
- A temporary clob.
- Throws:
java.sql.SQLException
- Since:
- 8.2.0
-
createTemporary
public static CLOB createTemporary(java.sql.Connection conn, boolean cache, int _duration, short form_of_use) throws java.sql.SQLException
Deprecated.Create a temporary clob or nclob.- Parameters:
cache
- Specifies if LOB should be read into buffer cache or not._duration
- The duration of the temporary LOB. The following are valid values: DURATION_SESSION, DURATION_CALL.form_of_use
- Valid values are FORM_CHAR and FORM_NCHAR- Returns:
- A temporary clob.
- Throws:
java.sql.SQLException
- Since:
- 10g
-
freeTemporary
public static void freeTemporary(CLOB temp_lob) throws java.sql.SQLException
Deprecated.Free the contents and the locator of the temporary clob.- Parameters:
temp_lob
- A temporary clob to be freeed.- Throws:
java.sql.SQLException
- if temp_lob is a permanent lob or temp_lob has already been freed.- Since:
- 8.2.0
-
isTemporary
public static boolean isTemporary(CLOB lob) throws java.sql.SQLException
Deprecated.Return true if the lob locator points to a temporary clob. False if it does not.- Parameters:
lob
- the clob to test.- Returns:
- true if the lob locator points to a temporary clob. False if it does not.
- Throws:
java.sql.SQLException
- Since:
- 8.2.0
-
getDuration
public static short getDuration(CLOB lob) throws java.sql.SQLException
Deprecated.return the duration of a temporary LOB- Returns:
- the duration of a temporary LOB
- Throws:
java.sql.SQLException
- Since:
- 18.1
-
freeTemporary
public void freeTemporary() throws java.sql.SQLException
Deprecated.Free the contents and the locator of the temporary clob.- Specified by:
freeTemporary
in interfaceoracle.jdbc.internal.OracleLargeObject<char[]>
- Throws:
java.sql.SQLException
- if self is a permanent lob or self has already been freed.- Since:
- 8.2.0
-
isTemporary
public boolean isTemporary() throws java.sql.SQLException
Deprecated.Return true if the lob locator points to a temporary clob. False if it does not.- Specified by:
isTemporary
in interfaceOracleClob
- Specified by:
isTemporary
in interfaceoracle.jdbc.internal.OracleLargeObject<char[]>
- Returns:
- true if the lob locator points to a temporary clob. False if it does not.
- Throws:
java.sql.SQLException
- Since:
- 8.2.0
-
getDuration
public short getDuration() throws java.sql.SQLException
Deprecated.return the duration of a temporary LOB- Specified by:
getDuration
in interfaceoracle.jdbc.internal.OracleLargeObject<char[]>
- Returns:
- the duration of a temporary LOB
- Throws:
java.sql.SQLException
- Since:
- 18.1
-
open
public void open(LargeObjectAccessMode mode) throws java.sql.SQLException
Deprecated.Public method using enum instead of int- Specified by:
open
in interfaceOracleClob
- Throws:
java.sql.SQLException
-
close
public void close() throws java.sql.SQLException
Deprecated.Close a previously opened CLOB.- Specified by:
close
in interfaceOracleClob
- Throws:
java.sql.SQLException
- Since:
- 8.2.0
-
isOpen
public boolean isOpen() throws java.sql.SQLException
Deprecated.Check whether the CLOB is opened.- Specified by:
isOpen
in interfaceOracleClob
- Returns:
- true if the LOB is opened.
- Throws:
java.sql.SQLException
- Since:
- 8.2.0
-
setString
public int setString(long pos, java.lang.String str) throws java.sql.SQLException
Deprecated.JDBC 3.0 Writes the given JavaString
to theCLOB
value that thisClob
object designates at the positionpos
.- Specified by:
setString
in interfacejava.sql.Clob
- Parameters:
pos
- the position at which to start writing to theCLOB
value that thisClob
object representsstr
- the string to be written to theCLOB
value that thisClob
designates- Returns:
- the number of characters written
- Throws:
java.sql.SQLException
- if there is an error accessing theCLOB
value- Since:
- 9.0.2
-
setString
public int setString(long pos, java.lang.String str, int offset, int len) throws java.sql.SQLException
Deprecated.JDBC 3.0 Writeslen
characters ofstr
, starting at characteroffset
, to theCLOB
value that thisClob
represents.- Specified by:
setString
in interfacejava.sql.Clob
- Parameters:
pos
- the position at which to start writing to thisCLOB
objectstr
- the string to be written to theCLOB
value that thisClob
object representsoffset
- the offset intostr
to start reading the characters to be writtenlen
- the number of characters to be written- Returns:
- the number of characters written
- Throws:
java.sql.SQLException
- if there is an error accessing theCLOB
value- Since:
- 9.0.2 This method is currently not supported. Use setString( long pos, String str )
-
setAsciiStream
public java.io.OutputStream setAsciiStream(long pos) throws java.sql.SQLException
Deprecated.JDBC 3.0 Retrieves a stream to be used to write Ascii characters to theCLOB
value that thisClob
object represents, starting at positionpos
.- Specified by:
setAsciiStream
in interfacejava.sql.Clob
- Parameters:
pos
- the position at which to start writing to thisCLOB
object- Returns:
- the stream to which ASCII encoded characters can be written
- Throws:
java.sql.SQLException
- if there is an error accessing theCLOB
value- Since:
- 9.0.2
-
setCharacterStream
public java.io.Writer setCharacterStream(long pos) throws java.sql.SQLException
Deprecated.JDBC 3.0 Retrieves a stream to be used to write a stream of Unicode characters to theCLOB
value that thisClob
object represents, at positionpos
.- Specified by:
setCharacterStream
in interfacejava.sql.Clob
- Parameters:
pos
- the position at which to start writing to theCLOB
value- Returns:
- a stream to which Unicode encoded characters can be written
- Throws:
java.sql.SQLException
- if there is an error accessing theCLOB
value- Since:
- 9.0.2
-
truncate
public void truncate(long len) throws java.sql.SQLException
Deprecated.JDBC 3.0 Truncates theCLOB
value that thisClob
designates to have a length oflen
characters.- Specified by:
truncate
in interfacejava.sql.Clob
- Parameters:
len
- the length, in bytes, to which theCLOB
value should be truncated- Throws:
java.sql.SQLException
- if there is an error accessing theCLOB
value- Since:
- 9.0.2
-
toJdbc
public java.lang.Object toJdbc() throws java.sql.SQLException
Deprecated.Convert this data object into its default Java object type.
-
isConvertibleTo
public boolean isConvertibleTo(java.lang.Class<?> jClass)
Deprecated.Test whether this data object can be converted to the specified Java data type.- Specified by:
isConvertibleTo
in interfaceoracle.jdbc.internal.OracleClob
- Specified by:
isConvertibleTo
in interfaceoracle.jdbc.internal.OracleDatumWithConnection
- Specified by:
isConvertibleTo
in classDatum
- Parameters:
jClass
- specifies the Java data type to test against.- Returns:
- true if this data object is convertible to the specified Java class, and a corresponding xxxValue() method is available; otherwise, a false is returned.
-
stringValue
public java.lang.String stringValue() throws java.sql.SQLException
Deprecated.Convert to a String representation of the datum object- Specified by:
stringValue
in interfaceoracle.jdbc.internal.OracleClob
- Specified by:
stringValue
in interfaceoracle.jdbc.internal.OracleDatumWithConnection
- Overrides:
stringValue
in classDatum
- Returns:
- String representation of the datum object
- Throws:
java.sql.SQLException
-
getJavaSqlConnection
public java.sql.Connection getJavaSqlConnection() throws java.sql.SQLException
Deprecated.Description copied from class:DatumWithConnection
Oracle extension Return the java.sql.Connection associated with the receiver. Since 9.0.0 not all Oracle JDBC connection objects are assignment compatible with oracle.jdbc.driver.OracleConnection. If the connection is wrapped, return the outermost wrapper.- Specified by:
getJavaSqlConnection
in interfaceoracle.jdbc.internal.OracleClob
- Specified by:
getJavaSqlConnection
in interfaceoracle.jdbc.internal.OracleDatumWithConnection
- Overrides:
getJavaSqlConnection
in classDatumWithConnection
- Returns:
- the connection
- Throws:
java.sql.SQLException
- if an error occurs
-
setPrefetchData
public final void setPrefetchData(oracle.jdbc.internal.OracleLargeObject.PrefetchData<char[]> prefetchData)
Deprecated.- Specified by:
setPrefetchData
in interfaceoracle.jdbc.internal.OracleLargeObject<char[]>
-
getPrefetchData
public final oracle.jdbc.internal.OracleLargeObject.PrefetchData<char[]> getPrefetchData()
Deprecated.- Specified by:
getPrefetchData
in interfaceoracle.jdbc.internal.OracleLargeObject<char[]>
-
getPrefetchedDataSize
public final int getPrefetchedDataSize()
Deprecated.
-
canReadBasicLobDataInLocator
public boolean canReadBasicLobDataInLocator() throws java.sql.SQLException
Deprecated.Can the lob data be read directly from the locator?- Specified by:
canReadBasicLobDataInLocator
in interfaceoracle.jdbc.internal.OracleClob
- Returns:
- True if we can; false otherwise.
- Throws:
java.sql.SQLException
-
freeLOB
public void freeLOB() throws java.sql.SQLException
Deprecated.- Specified by:
freeLOB
in interfaceoracle.jdbc.internal.OracleLargeObject<char[]>
- Throws:
java.sql.SQLException
-
free
public void free() throws java.sql.SQLException
Deprecated.Free the resources the clob holds.- Specified by:
free
in interfacejava.sql.Clob
- Throws:
java.sql.SQLException
- Since:
- 11.0
-
getCharacterStream
public java.io.Reader getCharacterStream(long pos, long length) throws java.sql.SQLException
Deprecated.Return a character stream beginning at the specified position and ofthe specified length.- Specified by:
getCharacterStream
in interfacejava.sql.Clob
- Parameters:
pos
- start positionlength
- number of characters in the result- Throws:
java.sql.SQLException
- - if pos is less than 1 or if pos is greater than the number of characters in the Clob or if pos + length is greater than the number of characters in the Clob or if an error occurs- Since:
- 11.0
-
setBytes
public void setBytes(byte[] locator)
Deprecated.Description copied from class:Datum
Sets datum value using a byte array. The byte array is copied.
-
toSQLXML
public java.sql.SQLXML toSQLXML() throws java.sql.SQLException
Deprecated.Returns an object which impements java.sql.SQLXML with content take from this Clob.- Specified by:
toSQLXML
in interfaceOracleClob
- Returns:
- the new SQLXML object
- Throws:
java.sql.SQLException
- Since:
- 12.2
-
toSQLXML
public java.sql.SQLXML toSQLXML(java.lang.String schemaURL) throws java.sql.SQLException
Deprecated.Returns an object which impements java.sql.SQLXML with content taken from this Clob.- Specified by:
toSQLXML
in interfaceOracleClob
- Returns:
- the new SQLXML object
- Throws:
java.sql.SQLException
- Since:
- 12.2
-
isFree
public final boolean isFree()
Deprecated.- Specified by:
isFree
in interfaceoracle.jdbc.internal.OracleLargeObject<char[]>
-
-