SolarMetric Kodo JDO 2.5.0 Reverse Schema Tool

com.solarmetric.rd.kodo.impl.jdbc.schema.dict
Class HSQLDictionary

java.lang.Object
  |
  +--com.solarmetric.rd.kodo.impl.jdbc.schema.DBDictionary
        |
        +--com.solarmetric.rd.kodo.impl.jdbc.schema.dict.HSQLDictionary

public class HSQLDictionary
extends DBDictionary

Dictionary for Hypersonic SQL database.


Field Summary
 
Fields inherited from class com.solarmetric.rd.kodo.impl.jdbc.schema.DBDictionary
CENTI, DECI, MICRO, MILLI, NANO, SEC
 
Constructor Summary
HSQLDictionary()
           
 
Method Summary
 java.lang.String[] getAddColumnSQL(com.solarmetric.rd.kodo.impl.jdbc.schema.Column column)
          Return a series of SQL statements to add the given column to its table.
 java.lang.String[] getAddPrimaryKeySQL(com.solarmetric.rd.kodo.impl.jdbc.schema.PrimaryKey pk)
          Return a series of SQL statements to add the given primary key to its table.
 java.lang.Object getBlobObject(java.sql.ResultSet rs, int column)
          Convert the specified column of the SQL ResultSet to the proper java type.
 java.lang.String[] getDropPrimaryKeySQL(com.solarmetric.rd.kodo.impl.jdbc.schema.PrimaryKey pk)
          Return a series of SQL statements to drop the given primary key from its table.
 java.lang.String getPlatform()
          Return the database platform for this dictionary.
 int getPreferredType(int type)
          Return the preferred Types type for the given one.
 boolean isSystemIndex(java.lang.String name, com.solarmetric.rd.kodo.impl.jdbc.schema.Table table)
          This method is used to filter system indexes from database metadata.
 boolean supportsDeferredConstraints()
          Return true if the database supports deferred constraints.
 boolean supportsForeignKeyDeleteAction(int action)
          Return true if the database supports the given foreign key delete action.
 
Methods inherited from class com.solarmetric.rd.kodo.impl.jdbc.schema.DBDictionary
addSystemSchema, addSystemTable, generateForeignKeys, generateIndexes, generatePrimaryKeys, generateTables, getAddForeignKeySQL, getArray, getAsciiStream, getBigDecimal, getBigInteger, getBinaryStream, getBlob, getBoolean, getByte, getBytes, getChar, getCharacterStream, getClob, getClobString, getConfiguration, getCreateIndexSQL, getCreateTableSQL, getDate, getDate, getDatePrecision, getDBMetaData, getDeclareColumnSQL, getDouble, getDropColumnSQL, getDropForeignKeySQL, getDropIndexSQL, getDropTableSQL, getFloat, getForeignKeyActionName, getForeignKeyConstraintSQL, getInt, getJDBCType, getJDBCType, getLocale, getLong, getObject, getPrimaryKeyConstraintSQL, getRef, getShort, getSimulateLocking, getStoreCharsAsNumbers, getStoreLargeNumbersAsStrings, getString, getSystemSchemas, getSystemTables, getTime, getTimestamp, getTypeName, getValidColumnName, getValidForeignKeyName, getValidIndexName, getValidPrimaryKeyName, getValidTableName, isSystemTable, makeNameValid, replaceMapping, replaceMappingFactory, replaceSchemaFactory, setArray, setAsciiStream, setBigDecimal, setBigInteger, setBinaryStream, setBlob, setBlobObject, setBoolean, setByte, setBytes, setChar, setCharacterStream, setClob, setClobString, setConfiguration, setDate, setDate, setDBMetaData, setDouble, setFloat, setInt, setLocale, setLong, setNull, setObject, setRef, setShort, setSimulateLocking, setStoreCharsAsNumbers, setStoreLargeNumbersAsStrings, setString, setSystemSchemas, setSystemTables, setTime, setTimestamp, supportsSelectForUpdate, supportsUpdateCountsForBatch, toSelect, wrapConnection
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

HSQLDictionary

public HSQLDictionary()
Method Detail

getPlatform

public java.lang.String getPlatform()
Description copied from class: DBDictionary
Return the database platform for this dictionary.

Overrides:
getPlatform in class DBDictionary

supportsForeignKeyDeleteAction

public boolean supportsForeignKeyDeleteAction(int action)
Description copied from class: DBDictionary
Return true if the database supports the given foreign key delete action. Returns true for all actions except ForeignKey.ACTION_NONE by default.

Overrides:
supportsForeignKeyDeleteAction in class DBDictionary

supportsDeferredConstraints

public boolean supportsDeferredConstraints()
Description copied from class: DBDictionary
Return true if the database supports deferred constraints. Returns true by default.

Overrides:
supportsDeferredConstraints in class DBDictionary

getBlobObject

public java.lang.Object getBlobObject(java.sql.ResultSet rs,
                                      int column)
                               throws java.sql.SQLException
Description copied from class: DBDictionary
Convert the specified column of the SQL ResultSet to the proper java type.

Overrides:
getBlobObject in class DBDictionary
java.sql.SQLException

getPreferredType

public int getPreferredType(int type)
Description copied from class: DBDictionary
Return the preferred Types type for the given one. Returns the given type by default.

Overrides:
getPreferredType in class DBDictionary

getAddPrimaryKeySQL

public java.lang.String[] getAddPrimaryKeySQL(com.solarmetric.rd.kodo.impl.jdbc.schema.PrimaryKey pk)
Description copied from class: DBDictionary
Return a series of SQL statements to add the given primary key to its table. Return an empty array if operation not supported. Returns ALTER TABLE <table name> ADD <pk cons sql > by default.

Overrides:
getAddPrimaryKeySQL in class DBDictionary

getDropPrimaryKeySQL

public java.lang.String[] getDropPrimaryKeySQL(com.solarmetric.rd.kodo.impl.jdbc.schema.PrimaryKey pk)
Description copied from class: DBDictionary
Return a series of SQL statements to drop the given primary key from its table. Return an empty array if operation not supported. Returns ALTER TABLE <table name> DROP CONSTRAINT <pk name> by default.

Overrides:
getDropPrimaryKeySQL in class DBDictionary

getAddColumnSQL

public java.lang.String[] getAddColumnSQL(com.solarmetric.rd.kodo.impl.jdbc.schema.Column column)
Description copied from class: DBDictionary
Return a series of SQL statements to add the given column to its table. Return an empty array if operation not supported. The DBMetaData is checked for support automatically. Returns ALTER TABLE <table name> ADD (<col dec>) by default.

Overrides:
getAddColumnSQL in class DBDictionary

isSystemIndex

public boolean isSystemIndex(java.lang.String name,
                             com.solarmetric.rd.kodo.impl.jdbc.schema.Table table)
Description copied from class: DBDictionary
This method is used to filter system indexes from database metadata. Return true if the given index name represents a system index that should not appear in the schema definition. Returns false by default.

Overrides:
isSystemIndex in class DBDictionary
Parameters:
name - the index name
table - the index table

SolarMetric Kodo JDO 2.5.0 Reverse Schema Tool

Copyright 2001,2002,2003 SolarMetric, Inc. All Rights Reserved.