Serializable
, oracle.jdbc.internal.ACProxyable
, oracle.jdbc.internal.ObjectData
, oracle.jdbc.internal.OracleTypeMetaData
, OracleData
, OracleTypeMetaData
, ORAData
ArrayDescriptor
, OpaqueDescriptor
, StructDescriptor
public class TypeDescriptor extends Object implements oracle.jdbc.internal.OracleTypeMetaData, Serializable, ORAData, OracleData
oracle.jdbc.internal.OracleTypeMetaData.Array, oracle.jdbc.internal.OracleTypeMetaData.Opaque, oracle.jdbc.internal.OracleTypeMetaData.Struct
OracleTypeMetaData.ArrayStorage, OracleTypeMetaData.Kind
Modifier | Constructor | Description |
---|---|---|
protected |
TypeDescriptor(short _typeCode) |
|
protected |
TypeDescriptor(short _typeCode, String name, Connection conn) |
|
protected |
TypeDescriptor(short _typeCode, oracle.jdbc.oracore.OracleTypeADT type, Connection conn) |
|
protected |
TypeDescriptor(short _typeCode, oracle.sql.SQLName name, Connection conn) |
|
protected |
TypeDescriptor(short _typeCode, oracle.sql.SQLName name, oracle.jdbc.oracore.OracleTypeADT type, Connection conn) |
Modifier and Type | Method | Description |
---|---|---|
static String |
convToUpperCase(String str) |
Convert the String to UpperCase character by character
|
protected oracle.jdbc.internal.OracleConnection |
getConnectionDuringExceptionHandling() |
|
short |
getInternalTypeCode() |
|
OracleTypeMetaData.Kind |
getKind() |
Return the kind of type.
|
String |
getName() |
Return fully qualified type name.
|
long |
getPrecision() |
|
byte |
getScale() |
|
static String |
getSubtypeName(OracleConnection conn, byte[] image, long offset) |
|
int |
getTypeCode() |
Returns type code.
|
String |
getTypeCodeName() |
Returns the type code name.
|
void |
initMetadataRecursively() |
|
void |
initNamesRecursively() |
|
boolean |
isTransient() |
|
static boolean |
isV2available(byte[] toid) |
|
void |
printXML(PrintStream s) |
Print an XML representation of this type and all OracleTypes within.
|
void |
printXML(PrintStream stream, boolean fetchAllMetaDataAsNeeded) |
Print an XML representation of this type and all OracleTypes within.
|
void |
setConnection(Connection connection) |
|
void |
setPrecision(long _precision) |
|
void |
setScale(byte _scale) |
|
Datum |
toDatum(Connection c) |
Extract an oracle.sql.Datum object.
|
Object |
toJDBCObject(Connection c) |
Extract a jdbc Object.
|
String |
toXMLString() |
Creates a String which is an XML representation of this type and all OracleTypes within.
|
String |
toXMLString(boolean fetchAllMetaDataAsNeeded) |
Creates a String which is an XML representation of this type and all OracleTypes within.
|
public static boolean DEBUG_SERIALIZATION
public static final byte[] RAWTOID
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, String name, Connection conn) throws SQLException
SQLException
protected TypeDescriptor(short _typeCode, oracle.sql.SQLName name, Connection conn) throws SQLException
SQLException
protected TypeDescriptor(short _typeCode, oracle.sql.SQLName name, oracle.jdbc.oracore.OracleTypeADT type, Connection conn) throws SQLException
SQLException
protected TypeDescriptor(short _typeCode, oracle.jdbc.oracore.OracleTypeADT type, Connection conn) throws SQLException
SQLException
public OracleTypeMetaData.Kind getKind()
OracleTypeMetaData
getKind
in interface OracleTypeMetaData
public String getName() throws SQLException
getName
in interface OracleTypeMetaData
SQLException
public int getTypeCode() throws SQLException
getTypeCode
in interface OracleTypeMetaData
SQLException
public String getTypeCodeName() throws SQLException
getTypeCodeName
in interface OracleTypeMetaData
SQLException
public short getInternalTypeCode() throws SQLException
SQLException
public static boolean isV2available(byte[] toid)
public Datum toDatum(Connection c) throws SQLException
ORAData
This 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.
toDatum
in interface ORAData
c
- The connection into which the value is being sent.SQLException
- if an error occurred.public Object toJDBCObject(Connection c) throws SQLException
OracleData
This 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 ocassionally needed. for example, if the class embeds CHAR attributes, connection may be needed to determine the database character set.
toJDBCObject
in interface OracleData
c
- The connection into which the value is being sent.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(Connection connection) throws SQLException
SQLException
public static String getSubtypeName(OracleConnection conn, byte[] image, long offset) throws SQLException
SQLException
public void initMetadataRecursively() throws SQLException
SQLException
public void initNamesRecursively() throws SQLException
SQLException
public String toXMLString() throws SQLException
SQLException
public String toXMLString(boolean fetchAllMetaDataAsNeeded) throws SQLException
fetchAllMetaDataAsNeeded
- if set to true and if necessary the driver will fetch the metadata from the serverSQLException
public void printXML(PrintStream s) throws SQLException
s
- a PrintStream upon which to writeSQLException
public void printXML(PrintStream stream, boolean fetchAllMetaDataAsNeeded) throws SQLException
stream
- a PrintStream upon which to writefetchAllMetaDataAsNeeded
- if set to true and if necessary the driver will fetch the metadata from the serverSQLException
protected oracle.jdbc.internal.OracleConnection getConnectionDuringExceptionHandling()