org.chur.ant.db.profiles.impl
Class CommonProfile

java.lang.Object
  extended by org.chur.ant.db.profiles.AbstractDBProfile
      extended by org.chur.ant.db.profiles.impl.CommonProfile
All Implemented Interfaces:
DBProfile

public class CommonProfile
extends AbstractDBProfile

Common database profile

Date: Oct 9, 2006 Time: 6:31:53 PM Author: Sergey Churikov


Constructor Summary
CommonProfile()
           
 
Method Summary
 SQLCommandProducer<Record> createDeleteSQLProducer()
           
 SQLCommandProducer<Record> createInsertSQLProducer()
           
 SQLCommandProducer<UpdateRecord> createUpdateSQLProducer()
           
 boolean isExceptionCanBeIgnored(java.sql.SQLException ex)
          All types of SQLException are applied (not ignored)
 java.lang.String toString()
           
 java.lang.String typeName(int sqlType, int len, java.lang.Integer precision)
          Convert field description into ANSI SQL.
 java.lang.String viewNameColumn()
          This method is used only in ViewStructTask to retrieve information about a view.
 java.lang.String viewOwnerColumn()
          This method is used only in ViewStructTask to retrieve information about a view.
 java.lang.String viewsCatalog()
          This method is used only in ViewStructTask to retrieve information about a view.
 java.lang.String viewSqlColumn()
          This method is used only in ViewStructTask to retrieve information about a view.
 
Methods inherited from class org.chur.ant.db.profiles.AbstractDBProfile
convert
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

CommonProfile

public CommonProfile()
Method Detail

typeName

public java.lang.String typeName(int sqlType,
                                 int len,
                                 java.lang.Integer precision)
Convert field description into ANSI SQL. The following types supported:

Parameters:
sqlType - java.sql.Type value
len - field length according to metadata
precision - precision value if exist
Returns:
The SQL type description to include this string in SQL script
Throws:
java.lang.IllegalArgumentException - if sqlType is not supported (the support type see above)

viewsCatalog

public java.lang.String viewsCatalog()
Description copied from interface: DBProfile
This method is used only in ViewStructTask to retrieve information about a view.

Returns:
null

viewSqlColumn

public java.lang.String viewSqlColumn()
Description copied from interface: DBProfile
This method is used only in ViewStructTask to retrieve information about a view.

Returns:
null

viewNameColumn

public java.lang.String viewNameColumn()
Description copied from interface: DBProfile
This method is used only in ViewStructTask to retrieve information about a view.

Returns:
null

viewOwnerColumn

public java.lang.String viewOwnerColumn()
Description copied from interface: DBProfile
This method is used only in ViewStructTask to retrieve information about a view.

Returns:
null

isExceptionCanBeIgnored

public boolean isExceptionCanBeIgnored(java.sql.SQLException ex)
All types of SQLException are applied (not ignored)

Parameters:
ex -
Returns:
false

createUpdateSQLProducer

public SQLCommandProducer<UpdateRecord> createUpdateSQLProducer()

createInsertSQLProducer

public SQLCommandProducer<Record> createInsertSQLProducer()

createDeleteSQLProducer

public SQLCommandProducer<Record> createDeleteSQLProducer()

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object