Package oracle.spatial.util
Class JDBCAdapter
- java.lang.Object
-
- oracle.spatial.util.JDBCAdapter
-
public class JDBCAdapter extends java.lang.ObjectThis Class helps to encapsulate calls to Oracle JDBC Extensions that does not work with some J2EE connection pools implementations. If initialize is not call, casting to oracle.sql.STRUCT and oracle.sql.ARRAY will be used.
-
-
Method Summary
All Methods Static Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static voidclearStatementCache(java.sql.Connection conn)static voidcloseOracleConnection(oracle.jdbc.OracleConnection conn)static oracle.sql.ArrayDescriptorgetArrayDescriptor(java.lang.Object obj)Deprecated.Use OracleConnection.createOracleArray(...);static javax.sql.DataSource[]getDataSource(java.lang.String... dataSourceName)static JGeometrygetJGeometry(java.lang.Object obj)static oracle.sql.Datum[]getOracleArray(java.lang.Object obj)Deprecated.Use java.sql.Array array = resultSet.getArray(...);static oracle.sql.Datum[]getOracleAttributes(java.lang.Object obj)Deprecated.Use java.sql.Struct.getAttributes();static oracle.jdbc.OracleConnectiongetOracleConnection(java.sql.Connection conn)static oracle.sql.StructDescriptorgetStructDescriptor(java.lang.Object obj)static oracle.xdb.XMLTypegetXMLType(java.lang.Object obj)Deprecated.Use SQLXML newXML = resultSet.getSQLXML(columnNumber);static voidinitialize(JDBCExtensionInterface oracleExtension)This method should be called before any interaction with the db.
-
-
-
Method Detail
-
initialize
public static void initialize(JDBCExtensionInterface oracleExtension)
This method should be called before any interaction with the db. JDBCExtensionInterface provides the implementation details to deal with Connection Wrappers.- Parameters:
oracleExtension-
-
getOracleConnection
public static oracle.jdbc.OracleConnection getOracleConnection(java.sql.Connection conn) throws java.sql.SQLException- Throws:
java.sql.SQLException
-
clearStatementCache
public static void clearStatementCache(java.sql.Connection conn) throws java.sql.SQLException- Throws:
java.sql.SQLException
-
getJGeometry
public static JGeometry getJGeometry(java.lang.Object obj) throws java.sql.SQLException
- Throws:
java.sql.SQLException
-
getOracleAttributes
public static oracle.sql.Datum[] getOracleAttributes(java.lang.Object obj) throws java.sql.SQLExceptionDeprecated.Use java.sql.Struct.getAttributes();- Parameters:
obj-- Returns:
- Throws:
java.sql.SQLException
-
getStructDescriptor
public static oracle.sql.StructDescriptor getStructDescriptor(java.lang.Object obj) throws java.sql.SQLException- Throws:
java.sql.SQLException
-
getOracleArray
public static oracle.sql.Datum[] getOracleArray(java.lang.Object obj) throws java.sql.SQLExceptionDeprecated.Use java.sql.Array array = resultSet.getArray(...);- Parameters:
obj-- Returns:
- Throws:
java.sql.SQLException
-
getArrayDescriptor
public static oracle.sql.ArrayDescriptor getArrayDescriptor(java.lang.Object obj) throws java.sql.SQLExceptionDeprecated.Use OracleConnection.createOracleArray(...);- Parameters:
obj-- Returns:
- Throws:
java.sql.SQLException
-
closeOracleConnection
public static void closeOracleConnection(oracle.jdbc.OracleConnection conn) throws java.sql.SQLException- Throws:
java.sql.SQLException
-
getDataSource
public static javax.sql.DataSource[] getDataSource(java.lang.String... dataSourceName)
-
getXMLType
public static oracle.xdb.XMLType getXMLType(java.lang.Object obj) throws java.sql.SQLExceptionDeprecated.Use SQLXML newXML = resultSet.getSQLXML(columnNumber);- Parameters:
obj-- Returns:
- Throws:
java.sql.SQLException
-
-