Interface TableInformation
- All Known Implementing Classes:
TableInformationImpl
public interface TableInformation
Provides access to information about existing tables in the database
-
Method Summary
Modifier and TypeMethodDescriptionvoid
addColumn
(ColumnInformation columnIdentifier) getColumn
(Identifier columnIdentifier) Retrieve the named ColumnInformationGet the comments/remarks defined for the table.getForeignKey
(Identifier keyName) Retrieve the named ForeignKeyInformationObtain an iterable over all the table's defined foreign keys.getIndex
(Identifier indexName) Retrieve the named IndexInformationObtain an iterable over all the table's defined indexes.getName()
Get the qualified name of the table.Retrieve information about the table's primary key, if one is defined (aka, may returnnull
).boolean
Does this information describe a physical table as opposed to a view, etc?
-
Method Details
-
getName
QualifiedTableName getName()Get the qualified name of the table.- Returns:
- The qualified table name
-
isPhysicalTable
boolean isPhysicalTable()Does this information describe a physical table as opposed to a view, etc?- Returns:
true
if this is a physical table;false
otherwise.
-
getComment
String getComment()Get the comments/remarks defined for the table.- Returns:
- The table comments
-
getColumn
Retrieve the named ColumnInformation- Parameters:
columnIdentifier
- The column identifier (simple name)- Returns:
- The matching column information. May return
null
-
getPrimaryKey
PrimaryKeyInformation getPrimaryKey()Retrieve information about the table's primary key, if one is defined (aka, may returnnull
).- Returns:
- The primary key information, or
null
if the table did not define a primary key.
-
getForeignKeys
Iterable<ForeignKeyInformation> getForeignKeys()Obtain an iterable over all the table's defined foreign keys.- Returns:
- The iterable.
-
getForeignKey
Retrieve the named ForeignKeyInformation- Parameters:
keyName
- The foreign key identifier (simple name)- Returns:
- The matching foreign key information. May return
null
-
getIndexes
Iterable<IndexInformation> getIndexes()Obtain an iterable over all the table's defined indexes.- Returns:
- The iterable.
-
getIndex
Retrieve the named IndexInformation- Parameters:
indexName
- The index identifier (simple name)- Returns:
- The matching index information. May return
null
-
addColumn
-