public class TypeDescriptor extends java.lang.Object implements oracle.jdbc.internal.OracleTypeMetaData, java.io.Serializable, ORAData, OracleData, Diagnosable
oracle.jdbc.internal.OracleTypeMetaData.Array, oracle.jdbc.internal.OracleTypeMetaData.Opaque, oracle.jdbc.internal.OracleTypeMetaData.StructOracleTypeMetaData.ArrayStorage, OracleTypeMetaData.Kind| Modifier | Constructor and Description |
|---|---|
protected |
TypeDescriptor(short _typeCode) |
protected |
TypeDescriptor(short _typeCode,
oracle.jdbc.oracore.OracleTypeADT type,
java.sql.Connection conn) |
protected |
TypeDescriptor(short _typeCode,
oracle.sql.SQLName name,
java.sql.Connection conn) |
protected |
TypeDescriptor(short _typeCode,
oracle.sql.SQLName name,
oracle.jdbc.oracore.OracleTypeADT type,
java.sql.Connection conn) |
protected |
TypeDescriptor(short _typeCode,
java.lang.String name,
java.sql.Connection conn) |
| Modifier and Type | Method and Description |
|---|---|
static java.lang.String |
convToUpperCase(java.lang.String str)
Convert the String to UpperCase character by character
|
protected oracle.jdbc.internal.OracleConnection |
getConnectionDuringExceptionHandling() |
Diagnosable |
getDiagnosable() |
short |
getInternalTypeCode() |
OracleTypeMetaData.Kind |
getKind()
Return the kind of type.
|
java.lang.String |
getName()
Return fully qualified type name.
|
long |
getPrecision() |
byte |
getScale() |
static java.lang.String |
getSubtypeName(OracleConnection conn,
byte[] image,
long offset) |
int |
getTypeCode()
Returns type code.
|
java.lang.String |
getTypeCodeName()
Returns the type code name.
|
static TypeDescriptor |
getTypeDescriptor(java.lang.String qualifiedName,
OracleConnection conn,
byte[] image,
long offset)
Obtain the type descriptor associated with the specified type name.
|
void |
initMetadataRecursively() |
void |
initNamesRecursively() |
boolean |
isTransient() |
static boolean |
isV2available(byte[] toid) |
void |
printXML(java.io.PrintStream s)
Print an XML representation of this type
and all OracleTypes within.
|
void |
printXML(java.io.PrintStream stream,
boolean fetchAllMetaDataAsNeeded)
Print an XML representation of this type
and all OracleTypes within.
|
void |
setConnection(java.sql.Connection connection) |
void |
setPrecision(long _precision) |
void |
setScale(byte _scale) |
Datum |
toDatum(java.sql.Connection c)
Extract an oracle.sql.Datum object.
|
java.lang.Object |
toJDBCObject(java.sql.Connection c)
Extract a jdbc Object.
|
java.lang.String |
toXMLString()
Creates a String which is an XML representation
of this type and all OracleTypes within.
|
java.lang.String |
toXMLString(boolean fetchAllMetaDataAsNeeded)
Creates a String which is an XML representation
of this type and all OracleTypes within.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitbegin, beginCurrentSql, debug, debug, debug, debug, debug, debug, debug, debug, debug, debug, debugp, end, endCurrentSql, format, isDebugEnabled, isDiagnoseFirstFailureEnabled, isLoggable, isSensitiveEnabled, onClose, propertyChange, resumeLogging, secure, suspendLogging, trace, traceppublic static boolean DEBUG_SERIALIZATION
public static final int KOIDFLEN
public static final byte[] RAWTOID
public static final byte[] JSONTOID
public static final byte[] ANYTYPETOID
public static final byte[] ANYDATATOID
public static final byte[] ANYDATASETTOID
public static final byte[] XMLTYPETOID
public static final short TYPECODE_REF
public static final short TYPECODE_DATE
public static final short TYPECODE_SIGNED8
public static final short TYPECODE_SIGNED16
public static final short TYPECODE_SIGNED32
public static final short TYPECODE_REAL
public static final short TYPECODE_DOUBLE
public static final short TYPECODE_BFLOAT
public static final short TYPECODE_BDOUBLE
public static final short TYPECODE_FLOAT
public static final short TYPECODE_NUMBER
public static final short TYPECODE_DECIMAL
public static final short TYPECODE_UNSIGNED8
public static final short TYPECODE_UNSIGNED16
public static final short TYPECODE_UNSIGNED32
public static final short TYPECODE_OCTET
public static final short TYPECODE_SMALLINT
public static final short TYPECODE_INTEGER
public static final short TYPECODE_RAW
public static final short TYPECODE_PTR
public static final short TYPECODE_VARCHAR2
public static final short TYPECODE_CHAR
public static final short TYPECODE_VARCHAR
public static final short TYPECODE_MLSLABEL
public static final short TYPECODE_VARRAY
public static final short TYPECODE_TABLE
public static final short TYPECODE_OBJECT
public static final short TYPECODE_OPAQUE
public static final short TYPECODE_NAMEDCOLLECTION
public static final short TYPECODE_BLOB
public static final short TYPECODE_BFILE
public static final short TYPECODE_CLOB
public static final short TYPECODE_CFILE
public static final short TYPECODE_TIME
public static final short TYPECODE_TIME_TZ
public static final short TYPECODE_TIMESTAMP
public static final short TYPECODE_TIMESTAMP_TZ
public static final short TYPECODE_TIMESTAMP_LTZ
public static final short TYPECODE_INTERVAL_YM
public static final short TYPECODE_INTERVAL_DS
public static final short TYPECODE_UROWID
public static final short TYPECODE_OTMFIRST
public static final short TYPECODE_OTMLAST
public static final short TYPECODE_SYSFIRST
public static final short TYPECODE_SYSLAST
public static final short TYPECODE_PLS_INTEGER
public static final short TYPECODE_ITABLE
public static final short TYPECODE_RECORD
public static final short TYPECODE_BOOLEAN
public static final short TYPECODE_NCHAR
public static final short TYPECODE_NVARCHAR2
public static final short TYPECODE_NCLOB
public static final short TYPECODE_NONE
public static final short TYPECODE_ERRHP
public static final short TYPECODE_JDBC_JOBJECT
public static final short TYPECODE_JDBC_STRUCT
public static final short TYPECODE_JDBC_ARRAY
public static final short TYPECODE_JDBC_JOPAQUE
public static final short TYPECODE_JDBC_REF
public static final short TYPECODE_JDBC_JSTRUCT
public static final short TYPECODE_SQLXML
protected TypeDescriptor(short _typeCode)
protected TypeDescriptor(short _typeCode,
java.lang.String name,
java.sql.Connection conn)
throws java.sql.SQLException
java.sql.SQLExceptionprotected TypeDescriptor(short _typeCode,
oracle.sql.SQLName name,
java.sql.Connection conn)
throws java.sql.SQLException
java.sql.SQLExceptionprotected TypeDescriptor(short _typeCode,
oracle.sql.SQLName name,
oracle.jdbc.oracore.OracleTypeADT type,
java.sql.Connection conn)
throws java.sql.SQLException
java.sql.SQLExceptionprotected TypeDescriptor(short _typeCode,
oracle.jdbc.oracore.OracleTypeADT type,
java.sql.Connection conn)
throws java.sql.SQLException
java.sql.SQLExceptionpublic OracleTypeMetaData.Kind getKind()
OracleTypeMetaDatagetKind in interface OracleTypeMetaDatapublic java.lang.String getName()
throws java.sql.SQLException
getName in interface OracleTypeMetaDatajava.sql.SQLExceptionpublic int getTypeCode()
throws java.sql.SQLException
getTypeCode in interface OracleTypeMetaDatajava.sql.SQLExceptionpublic java.lang.String getTypeCodeName()
throws java.sql.SQLException
getTypeCodeName in interface OracleTypeMetaDatajava.sql.SQLExceptionpublic short getInternalTypeCode()
throws java.sql.SQLException
java.sql.SQLExceptionpublic static boolean isV2available(byte[] toid)
public static TypeDescriptor getTypeDescriptor(java.lang.String qualifiedName, OracleConnection conn, byte[] image, long offset) throws java.sql.SQLException
name - specifies the type name.conn - specifies the associated connection.java.sql.SQLException - if the specified type does not exist, or if an error
occurred.public Datum toDatum(java.sql.Connection c) throws java.sql.SQLException
ORADataThis method is invoked by setORAData() to extract a Datum. The implementation of this method must return the correct type of Datum.
Although most implementation will ignore the connection, it is occassionally needed. For example, if the class embeds CHAR attributes, connection may be needed to determine the database character set.
public java.lang.Object toJDBCObject(java.sql.Connection c)
throws java.sql.SQLException
OracleDataThis method is invoked by setObject() to extract the jdbc Object. The implementation must return the jdbc Object that correctly represents the underlying SQLType.
Although most implementation will ignore the connection, it is occassionally needed. for example, if the class embeds CHAR attributes, connection may be needed to determine the database character set.
toJDBCObject in interface OracleDatac - The connection into which the value is being sent.java.sql.SQLException - if an error occurred.public boolean isTransient()
public void setPrecision(long _precision)
public long getPrecision()
public void setScale(byte _scale)
public byte getScale()
public void setConnection(java.sql.Connection connection)
throws java.sql.SQLException
java.sql.SQLExceptionpublic static java.lang.String getSubtypeName(OracleConnection conn, byte[] image, long offset) throws java.sql.SQLException
java.sql.SQLExceptionpublic void initMetadataRecursively()
throws java.sql.SQLException
java.sql.SQLExceptionpublic void initNamesRecursively()
throws java.sql.SQLException
java.sql.SQLExceptionpublic java.lang.String toXMLString()
throws java.sql.SQLException
java.sql.SQLExceptionpublic java.lang.String toXMLString(boolean fetchAllMetaDataAsNeeded)
throws java.sql.SQLException
fetchAllMetaDataAsNeeded - if set to true and if necessary
the driver will fetch the metadata from the serverjava.sql.SQLExceptionpublic void printXML(java.io.PrintStream s)
throws java.sql.SQLException
s - a PrintStream upon which to writejava.sql.SQLExceptionpublic void printXML(java.io.PrintStream stream,
boolean fetchAllMetaDataAsNeeded)
throws java.sql.SQLException
stream - a PrintStream upon which to writefetchAllMetaDataAsNeeded - if set to true and if necessary
the driver will fetch the metadata from the serverjava.sql.SQLExceptionprotected oracle.jdbc.internal.OracleConnection getConnectionDuringExceptionHandling()
public static java.lang.String convToUpperCase(java.lang.String str)
String - public Diagnosable getDiagnosable()
getDiagnosable in interface Diagnosable