org.biojava.bio.seq.db.biosql
Class OracleDBHelper

java.lang.Object
  extended byorg.biojava.bio.seq.db.biosql.DBHelper
      extended byorg.biojava.bio.seq.db.biosql.OracleDBHelper

public class OracleDBHelper
extends DBHelper

This is a DBHelper that provides support for Oracle databases.

Author:
Len Trigg, Eric Haugen

Nested Class Summary
 
Nested classes inherited from class org.biojava.bio.seq.db.biosql.DBHelper
DBHelper.DeleteStyle, DBHelper.JoinStyle
 
Field Summary
 
Fields inherited from class org.biojava.bio.seq.db.biosql.DBHelper
DELETE_GENERIC, DELETE_MYSQL4, DELETE_POSTGRESQL, JOIN_GENERIC, JOIN_ORACLE8
 
Constructor Summary
OracleDBHelper(Connection connection)
           
 
Method Summary
 boolean containsTable(DataSource ds, String tablename)
          Detects whether a particular table is present in the database.
 int getInsertID(Connection conn, String table, String columnName)
          Returns the id value created during the last insert command.
 DBHelper.JoinStyle getJoinStyle()
          Returns the an object indicating the style of table joining that this database should employ.
 
Methods inherited from class org.biojava.bio.seq.db.biosql.DBHelper
getDBHelper, getDeleteStyle
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

OracleDBHelper

public OracleDBHelper(Connection connection)
Method Detail

getJoinStyle

public DBHelper.JoinStyle getJoinStyle()
Description copied from class: DBHelper
Returns the an object indicating the style of table joining that this database should employ.

Overrides:
getJoinStyle in class DBHelper
Returns:
the preferred joining style.

getInsertID

public int getInsertID(Connection conn,
                       String table,
                       String columnName)
                throws SQLException
Description copied from class: DBHelper
Returns the id value created during the last insert command. This is for tables that have an auto increment column.

Specified by:
getInsertID in class DBHelper
Returns:
the last id assigned, or -1 if the id could not be found.
Throws:
SQLException

containsTable

public boolean containsTable(DataSource ds,
                             String tablename)
Description copied from class: DBHelper
Detects whether a particular table is present in the database.

Overrides:
containsTable in class DBHelper
Parameters:
ds - a DataSource that can provide a connection to a database
tablename - the name of the table.
Returns:
true if the table exists in the database.