Package com.healthmarketscience.jackcess
Interface Index
-
- All Known Implementing Classes:
IndexImpl
public interface IndexAccess database index definition. ATablehas a list of Index instances. Indexes can enable fast searches and ordered traversal on a Table (for the indexed columns). These features can be utilized via anIndexCursor.- Author:
- James Ahlborn
- Usage:
- General: This class is general use.
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static interfaceIndex.ColumnInformation about a Column in an Index
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description intgetColumnCount()List<? extends Index.Column>getColumns()StringgetName()PropertyMapgetProperties()Returns the properties for this index.IndexgetReferencedIndex()TablegetTable()booleanisForeignKey()booleanisPrimaryKey()booleanisRequired()Whether or not values are required for index columns.booleanisUnique()Whether or not index entries must be unique.CursorBuildernewCursor()Convenience method for constructing a new CursorBuilder for this Index.booleanshouldIgnoreNulls()Whether or notnullvalues are actually recorded in the index.
-
-
-
Method Detail
-
getTable
Table getTable()
-
getName
String getName()
-
isPrimaryKey
boolean isPrimaryKey()
-
isForeignKey
boolean isForeignKey()
-
getColumnCount
int getColumnCount()
- Usage:
- General: This method is general use.
-
getColumns
List<? extends Index.Column> getColumns()
- Returns:
- the Columns for this index (unmodifiable)
-
getReferencedIndex
Index getReferencedIndex() throws IOException
- Returns:
- the Index referenced by this Index's ForeignKeyReference (if it
has one), otherwise
null. - Throws:
IOException
-
shouldIgnoreNulls
boolean shouldIgnoreNulls()
Whether or notnullvalues are actually recorded in the index.
-
isUnique
boolean isUnique()
Whether or not index entries must be unique.Some notes about uniqueness:
- Access does not seem to consider multiple
nullentries invalid for a unique index - text indexes collapse case, and Access seems to compare only the index entry bytes, therefore two strings which differ only in case will violate the unique constraint
- Access does not seem to consider multiple
-
isRequired
boolean isRequired()
Whether or not values are required for index columns.
-
getProperties
PropertyMap getProperties() throws IOException
Returns the properties for this index. An index has a property block of its own, separate from the block of the column it is named after.- Throws:
IOException
-
newCursor
CursorBuilder newCursor()
Convenience method for constructing a new CursorBuilder for this Index.
-
-