| java.lang.Object org.ofbiz.entity.jdbc.DatabaseUtil
DatabaseUtil | public class DatabaseUtil (Code) | | Utilities for Entity Database Maintenance
author: David E. Jones version: $Revision: 1.12 $ since: 2.0 |
Inner Class :public static class ColumnCheckInfo | |
Inner Class :public static class ReferenceCheckInfo | |
Method Summary | |
public String | addColumn(ModelEntity entity, ModelField field) | public void | checkDb(Map modelEntities, List messages, boolean addMissing) | public String | createDeclaredIndex(ModelEntity entity, ModelIndex modelIndex) | public String | createDeclaredIndices(ModelEntity entity) | public String | createForeignKey(ModelEntity entity, ModelRelation modelRelation, ModelEntity relModelEntity, int constraintNameClipLength, String fkStyle, boolean useFkInitiallyDeferred) | public String | createForeignKeyIndex(ModelEntity entity, ModelRelation modelRelation, int constraintNameClipLength) | public String | createForeignKeyIndices(ModelEntity entity, int constraintNameClipLength) | public void | createForeignKeys(ModelEntity entity, Map modelEntities, List messages) | public void | createForeignKeys(ModelEntity entity, Map modelEntities, int constraintNameClipLength, String fkStyle, boolean useFkInitiallyDeferred, List messages) | public String | createTable(ModelEntity entity, Map modelEntities, boolean addFks, boolean usePkConstraintNames, int constraintNameClipLength, String fkStyle, boolean useFkInitiallyDeferred) | public String | deleteDeclaredIndex(ModelEntity entity, ModelIndex modelIndex) | public String | deleteDeclaredIndices(ModelEntity entity) | public String | deleteForeignKey(ModelEntity entity, ModelRelation modelRelation, ModelEntity relModelEntity, int constraintNameClipLength) | public String | deleteForeignKeyIndex(ModelEntity entity, ModelRelation modelRelation, int constraintNameClipLength) | public String | deleteForeignKeyIndices(ModelEntity entity, int constraintNameClipLength) | public void | deleteForeignKeys(ModelEntity entity, Map modelEntities, List messages) | public void | deleteForeignKeys(ModelEntity entity, Map modelEntities, int constraintNameClipLength, List messages) | public void | deleteTable(ModelEntity entity, List messages) | public Map | getColumnInfo(Set tableNames, Collection messages) | protected Connection | getConnection() | public DatabaseMetaData | getDatabaseMetaData(Connection connection, Collection messages) | public EntityConfigUtil.DatasourceInfo | getDatasourceInfo() | public Map | getIndexInfo(Set tableNames, Collection messages) | public Map | getReferenceInfo(Set tableNames, Collection messages) | public TreeSet | getTableNames(Collection messages) | public List | induceModelFromDb(Collection messages) | public String | makeFkConstraintClause(ModelEntity entity, ModelRelation modelRelation, ModelEntity relModelEntity, int constraintNameClipLength, String fkStyle, boolean useFkInitiallyDeferred) | public String | makeFkConstraintName(ModelRelation modelRelation, int constraintNameClipLength) | public String | makeFkIndexClause(ModelEntity entity, ModelRelation modelRelation, int constraintNameClipLength) | public String | makeIndexClause(ModelEntity entity, ModelIndex modelIndex) | public void | printDbMiscData(DatabaseMetaData dbData) |
checkDb | public void checkDb(Map modelEntities, List messages, boolean addMissing)(Code) | | |
createForeignKeyIndices | public String createForeignKeyIndices(ModelEntity entity, int constraintNameClipLength)(Code) | | |
createForeignKeys | public void createForeignKeys(ModelEntity entity, Map modelEntities, int constraintNameClipLength, String fkStyle, boolean useFkInitiallyDeferred, List messages)(Code) | | |
createTable | public String createTable(ModelEntity entity, Map modelEntities, boolean addFks, boolean usePkConstraintNames, int constraintNameClipLength, String fkStyle, boolean useFkInitiallyDeferred)(Code) | | |
deleteForeignKeyIndices | public String deleteForeignKeyIndices(ModelEntity entity, int constraintNameClipLength)(Code) | | |
deleteForeignKeys | public void deleteForeignKeys(ModelEntity entity, Map modelEntities, int constraintNameClipLength, List messages)(Code) | | |
induceModelFromDb | public List induceModelFromDb(Collection messages)(Code) | | Creates a list of ModelEntity objects based on meta data from the database
|
|
|