package com.quantum.model;
+import java.sql.SQLException;
+
import com.quantum.IQuantumConstants;
/**
* @author BC
*/
-public interface Entity extends BookmarkHolder {
+public interface Entity extends BookmarkHolder, Comparable {
public static final String TABLE_TYPE = IQuantumConstants.Table;
public static final String VIEW_TYPE = IQuantumConstants.View;
public String getName();
public String getSchema();
public String getType();
- public Column[] getColumns();
- public Index[] getIndexes();
- public Column getColumn(String columnName);
+ public Column[] getColumns() throws NotConnectedException, SQLException;
+ public Index[] getIndexes() throws NotConnectedException, SQLException;
+ public Column getColumn(String columnName) throws NotConnectedException, SQLException;
/**
- * Returns a String with the qualified name of the Entity.
- * That is, "schema.name". The difference with getQualifiedName()
- * is that the schema may be absent if it's not defined in the bookmark
+ * Returns a String with the qualified name of the Entity in the
+ * format "schema.name".
*/
- public String getCondQualifiedName();
+ public String getQualifiedName();
/**
* @return - TRUE if the entity exists in the database<br />
* @return
*/
public String getQuotedTableName();
+ public ForeignKey[] getExportedKeys() throws NotConnectedException, SQLException;
+ public ForeignKey[] getImportedKeys() throws NotConnectedException, SQLException;
+ public ForeignKey[] getReferences() throws NotConnectedException, SQLException;
}