1 17 package org.apache.ws.jaxme.sqls.hsqldb; 18 19 import org.apache.ws.jaxme.sqls.Table; 20 import org.apache.ws.jaxme.sqls.impl.SQLGeneratorImpl; 21 22 23 27 public class HsqlDbSQLGeneratorImpl extends SQLGeneratorImpl implements HsqlDbSQLGenerator { 28 protected boolean isPrimaryKeyUniqueIndex() { 29 return false; 30 } 31 32 protected boolean isPrimaryKeyPartOfCreateTable() { 33 return true; 34 } 35 36 protected boolean isUniqueIndexPartOfCreateTable() { 37 return true; 38 } 39 40 protected boolean isNonUniqueIndexPartOfCreateTable() { 41 return false; 42 } 43 44 protected boolean isForeignKeyPartOfCreateTable() { 45 return true; 46 } 47 48 protected String getCreateTableHeader(Table pTable) { 49 if (pTable instanceof HsqlDbTable) { 50 HsqlDbTable table = (HsqlDbTable) pTable; 51 if (table.isCached()) { 52 return "CREATE CACHED TABLE " + pTable.getQName(); 53 } 54 } 55 return super.getCreateTableHeader(pTable); 56 } 57 } 58 | Popular Tags |