| Modifier and Type | Method and Description |
|---|---|
void |
clearCache()
Clear the metadata.
|
com.corticon.rulesemf.canonicalvocabularymodel.metadata.database.ColumnMetadata |
findColumnMetadata(java.lang.String astrTableName,
java.lang.String astrColumnName)
Return the specified ColumnMetadata object instance.
|
com.corticon.rulesemf.canonicalvocabularymodel.DatabaseAccess |
findDatabaseAccess()
Finder for DatabaseAccess instance.
|
com.corticon.rulesemf.canonicalvocabularymodel.metadata.database.DatabaseMetadata |
findDatabaseMetadata()
Finder for DatabaseMetadata anchor.
|
com.corticon.rulesemf.canonicalvocabularymodel.metadata.database.ForeignKeyMetadata |
findForeignKeyMetadata(java.lang.String astrTableName,
java.lang.String astrForeignKeyName)
Return the specified foreign key metadata object instance.
|
com.corticon.rulesemf.canonicalvocabularymodel.metadata.database.PrimaryKeyMetadata |
findPrimaryKeyMetadata(java.lang.String astrTableName,
java.lang.String astrPrimaryKeyName)
Return the specified primary key metadata object instance.
|
com.corticon.rulesemf.canonicalvocabularymodel.metadata.database.TableMetadata |
findTableMetadata(java.lang.String astrTableName)
Return the specified TableMetadata object instance.
|
java.util.ArrayList |
getAllColumnNames(java.lang.String astrTableName)
Return a list of all column names of the specified table.
|
java.util.ArrayList |
getAllForeignKeyNames(java.lang.String astrTableName)
Return a list of all foreign key names (foreign keys that *point* to this table,
not foreign keys defined for this table).
|
java.util.ArrayList |
getAllTableNames()
Return a list of fully-qualified table names.
|
java.util.ArrayList |
getColumnNamesForTypes(java.lang.String astrTableName,
java.util.List aListJdbcDataTypes)
Return a list of column names belonging to the specified table that have the
specified JDBC data type(s).
|
int |
getColumnSize(java.lang.String astrTableName,
java.lang.String astrColumnName)
Given a table name and column name, return the column size as
specified in the database metadata or -1 if no information is available.
|
int |
getDecimalDigits(java.lang.String astrTableName,
java.lang.String astrColumnName)
Given a table name and column name, return the number of decimal digits
specified in the database metadata or -1 if no information is available.
|
java.lang.String |
getJdbcDataType(java.lang.String astrTableName,
java.lang.String astrColumnName)
Get the JDBC data type for a given database table name and column name.
|
java.util.List |
getJoinExpressionsInverse(java.lang.String astrSourceTable,
java.lang.String astrTargetTable)
Given a source and target table, return a list of inverse join expressions.
|
java.util.List |
getJoinExpressionsManyToMany(java.lang.String astrTableSource,
java.lang.String astrTableTarget)
Return join expressions appropriate for many-to-many associations.
|
java.util.List |
getJoinExpressionsStandard(java.lang.String astrTableSource,
java.lang.String astrTableTarget)
Return join expressions appropriate for one-to-one or one-to-many associations.
|
java.util.ArrayList |
getPrimaryKeyColumnNames(java.lang.String astrTableName)
Return a sorted list of the primary key column names for a given table name.
|
java.lang.String |
getSqlDataType(java.lang.String astrTableName,
java.lang.String astrColumnName)
Get the SQL data type for a given database table name and column name.
|
java.util.List<java.lang.String> |
getSQLKeywords()
Get a list of SQL keywords from the current database connection.
|
boolean |
isEmpty()
Determine whether the metadata cache is empty (i.e., database contains zero tables).
|
boolean |
isForeignKeyColumn(java.lang.String astrTableName,
java.lang.String astrColumnName)
Determine whether the specified table and column name are part of a foreign key.
|
boolean |
isMetadataLoaded()
Determine whether any metadata has been loaded.
|
boolean |
isSequence(IEntity aEntity,
java.lang.String astrName)
Determine whether the specified name is a database sequence.
|
boolean |
isTable(java.lang.String astrName)
Determine whether the specified name is a database table.
|
boolean |
isValidColumn(java.lang.String astrTableName,
java.lang.String astrColumnName)
Determine whether the specified column name is valid (i.e., whether there is any
metadata present that describes the column).
|
boolean |
isValidTable(java.lang.String astrTableName)
Determine whether the specified table name is valid (i.e., whether there is any
metadata present that describes the table).
|
boolean |
isView(java.lang.String astrName)
Determine whether the specified name is a database view.
|
boolean |
load()
Load all metadata from a database connection using connection properties defined in the
DatabaseAccess EMF object.
|
JoinExpression |
parseJoinExpression(java.lang.String astrJoinExpression,
java.lang.String astrSourceTableName,
java.lang.String astrTargetTableName,
boolean abManyToMany,
boolean abPerformSemanticAnalysis)
Parse a given join expression to construct an object representation
then optionally perform semantic analysis if the database metadata is available.
|
void |
setVocabularyModelAPI(IVocabularyModelAPI aIVocabularyModelAPI)
Setter for reference to Vocabulary model API (required).
|
boolean |
testConnection(boolean abSilent)
Test the current database connection and may optionally display a message box
to indicate whether the test was successful.
|
activate, addAnnotation, addBatchedModelListener, addLowLevelModelListener, addModelListener, addResourceListener, addView, beginTransaction, cancelTransaction, canSetSupportedLocales, closeResource, createResource, deleteAnnotation, deleteAnnotation, deleteAnnotation, deleteResource, displayMessageBox, dispose, doPostLoadValidation, doSmartValidation, endTransaction, endTransaction, flushCommandStack, formatValidationMessageLocation, formatValidationMessageText, getAllLocalesProvidingCompleteLocalization, getAnnotation, getAnnotations, getAnnotations, getAnnotations, getAPIContextObject, getAsset, getBaseAttribute, getBaseAttributeString, getBatchedModelListeners, getBuildNumber, getBuildNumberOfLastValidationRulesChange, getEditingDomain, getErrors, getErrors, getIndexByLocale, getLocale, getLocalizedAttribute, getLocalizedAttributeString, getLowLevelModelListeners, getMajorServiceNumber, getMajorVersionNumber, getMessage, getMessage, getMessageBase, getMessageBoxDelegate, getMinorServiceNumber, getMinorVersionNumber, getModelAPIState, getModelListeners, getNewResourceName, getPersistenceServicesDelegate, getPreferences, getPrimaryResource, getPrimaryResourceURI, getScrollableMessageDelegate, getSupportedLocales, getSuppressBrokenLinkValidation, getSuppressValidation, getToolTip, getUpdateStamp, getUserInterfaceInfoDelegate, getValidationMessageCount, getValidationMessageCount, getValidationMessageCount, getValidationMessageCount, getValidationMessages, getValidationMessages, getWarnings, getWarnings, handleException, hasErrors, hasErrors, hasErrors, hasErrors, hasErrors, hasErrors, hasErrorsOrWarnings, hasErrorsOrWarnings, hasErrorsOrWarnings, hasErrorsOrWarnings, hasErrorsOrWarnings, hasErrorsOrWarnings, hasWarnings, hasWarnings, hasWarnings, hasWarnings, hasWarnings, hasWarnings, isAPIStateEstablished, isEnabledRedo, isEnabledUndo, isInhibitNotification, isLoaded, isOperationModeNormal, isOperationModeRedo, isOperationModeUndo, isPassive, isPostLoadInProgress, isPrimaryResourceSet, isReadOnly, isResourceActivated, isResourceConflict, isResourceDemandLoaded, isResourceLoaded, isScrollableMessageDelegateAvailable, isShowCanonicalValidationMessages, isSuppressModifiedFlagUpdates, isSuppressPostLoad, isTransactionInProgress, isValid, isValid, loadResource, loadResource, loadResource, newInstance, noOperation, postLoad, postMethod, postMethod, postsave, preMethod, presave, redo, reloadResource, remapResource, remapResource, removeBatchedModelListener, removeLowLevelModelListener, removeModelListener, removeResource, removeResourceListener, removeView, renameResource, rollbackTransaction, saveAll, saveResource, setAnnotation, setAPIContextObject, setAPIState, setBuildNumber, setEditingDomain, setInhibitNotification, setLocale, setMajorServiceNumber, setMajorVersionNumber, setMessageBoxDelegate, setMinorServiceNumber, setMinorVersionNumber, setModelAPIState, setModelListeners, setPassive, setPersistenceServicesDelegate, setPostLoadInProgress, setPreferencesDelegate, setPrimaryResource, setReadOnly, setScrollableMessageDelegate, setSupportedLocales, setSuppressBrokenLinkValidation, setSuppressModifiedFlagUpdates, setSuppressPostLoad, setSuppressValidation, setUserInterfaceInfoDelegate, undo, unloadResource, validate, validateLicensevoid clearCache()
java.util.ArrayList getAllColumnNames(java.lang.String astrTableName)
astrTableName - Fully-qualified name of database table.java.util.ArrayList getAllTableNames()
java.util.ArrayList getAllForeignKeyNames(java.lang.String astrTableName)
astrTableName - Fully-qualified name of database table.java.util.ArrayList getColumnNamesForTypes(java.lang.String astrTableName,
java.util.List aListJdbcDataTypes)
astrTableName - Fully-qualified name of database table.aListJdbcDataTypes - List of JDBC data types.java.lang.String getJdbcDataType(java.lang.String astrTableName,
java.lang.String astrColumnName)
astrTableName - Fully-qualified name of database table.astrColumn - Name of database column.null.java.lang.String getSqlDataType(java.lang.String astrTableName,
java.lang.String astrColumnName)
astrTableName - Fully-qualified name of database table.astrColumn - Name of database column.null.int getColumnSize(java.lang.String astrTableName,
java.lang.String astrColumnName)
astrTableName - Fully-qualified table name.astrColumnName - Column name.int getDecimalDigits(java.lang.String astrTableName,
java.lang.String astrColumnName)
astrTableName - Fully-qualified table name.astrColumnName - Column name.com.corticon.rulesemf.canonicalvocabularymodel.metadata.database.ColumnMetadata findColumnMetadata(java.lang.String astrTableName,
java.lang.String astrColumnName)
astrTableName - Fully-qualified table name.astrColumnName - Column name.com.corticon.rulesemf.canonicalvocabularymodel.DatabaseAccess findDatabaseAccess()
com.corticon.rulesemf.canonicalvocabularymodel.metadata.database.DatabaseMetadata findDatabaseMetadata()
com.corticon.rulesemf.canonicalvocabularymodel.metadata.database.ForeignKeyMetadata findForeignKeyMetadata(java.lang.String astrTableName,
java.lang.String astrForeignKeyName)
astrTableName - Fully-qualified table name.astrForeignKeyName - Foreign key name.com.corticon.rulesemf.canonicalvocabularymodel.metadata.database.PrimaryKeyMetadata findPrimaryKeyMetadata(java.lang.String astrTableName,
java.lang.String astrPrimaryKeyName)
astrTableName - Fully-qualified table name.astrPrimaryKeyName - Primary key name.com.corticon.rulesemf.canonicalvocabularymodel.metadata.database.TableMetadata findTableMetadata(java.lang.String astrTableName)
astrTableName - Fully-qualified table name.java.util.List getJoinExpressionsStandard(java.lang.String astrTableSource,
java.lang.String astrTableTarget)
In a one-to-many association, the source table is assumed to contain the primary key and the target table is assumed to contain the foreign key (for one-to-one associations, this distinction is not important).
The join expressions will be returned as shown in this example:astrTableSource - Fully-qualified name of source database table.astrTableTarget - fully-qualified name of target database table.java.util.List getJoinExpressionsInverse(java.lang.String astrSourceTable,
java.lang.String astrTargetTable)
astrSourceTable - Fully-qualified source table (i.e., target of inverse expressions).astrTargetTable - Fully-qualified target table (i.e., source of inverse expressions).java.util.List getJoinExpressionsManyToMany(java.lang.String astrTableSource,
java.lang.String astrTableTarget)
astrTableSource - Fully-qualified name of source database table.astrTableTarget - Fully-qualified name of target database table.java.util.ArrayList getPrimaryKeyColumnNames(java.lang.String astrTableName)
astrTableName - Fully-qualified table name.boolean isEmpty()
true if loaded but table count is empty.boolean isForeignKeyColumn(java.lang.String astrTableName,
java.lang.String astrColumnName)
astrTableName - Table Name.astrColumnName - Column Name.true if the column is part of a foreign key.boolean isMetadataLoaded()
true if metadata is present.boolean isTable(java.lang.String astrName)
astrName - Fully-qualified name of either table or view.true if name is a table.boolean isView(java.lang.String astrName)
astrName - Fully-qualified name of either table or view.true if name is a table.boolean isSequence(IEntity aEntity, java.lang.String astrName)
aEntity - Name of an entity the sequence belongs toastrName - Name of a sequence.true if name is a sequence.boolean isValidColumn(java.lang.String astrTableName,
java.lang.String astrColumnName)
astrTableName - Fully-qualified name of the database table.astrColumnName - Name of the database column.true if metadata is available.boolean isValidTable(java.lang.String astrTableName)
astrTableName - Fully-qualified name of the database table.true if metadata is available.boolean load()
true if metadata was successfully loaded.JoinExpression parseJoinExpression(java.lang.String astrJoinExpression, java.lang.String astrSourceTableName, java.lang.String astrTargetTableName, boolean abManyToMany, boolean abPerformSemanticAnalysis)
astrJoinExpression - Join expression (string).astrSourceTableName - Fully-qualified source table name.astrTargetTableName - Fully-qualified target table name.abManyToMany - true if join expression describes many-to-many association.abPerformSemanticAnalysis - true to check join expression against metadata.void setVocabularyModelAPI(IVocabularyModelAPI aIVocabularyModelAPI)
aIVocabularyModelAPI - Vocabulary model API instance.boolean testConnection(boolean abSilent)
abSilent - true to suppress message "connection successful" message box.true if connection was successful.java.util.List<java.lang.String> getSQLKeywords()
null otherwiseCopyright © 2005-2013 Progress Software Corporation and/or its subsidiaries and affiliates. All rights reserved.