org.jboss.dna.common.jdbc.model.api
Interface Index

All Superinterfaces:
CoreMetaData, DatabaseNamedObject, SchemaObject, Serializable
All Known Implementing Classes:
IndexBean

public interface Index
extends SchemaObject

Provides all database table's index specific metadata.

Author:
Sergiy Litsenko

Method Summary
 void addColumn(IndexColumn indexColumn)
          Adds IndexColumn
 void deleteColumn(IndexColumn indexColumn)
          delete IndexColumn
 IndexColumn findColumnByName(String columnName)
          Returns index column for specified column name or null
 Integer getCardinality()
          When TYPE is tableIndexStatistic, then this is the number of rows in the table; otherwise, it is the number of unique values in the index.
 Set<IndexColumn> getColumns()
          Retrieves index columns
 String getFilterCondition()
          Returns the filter condition, if any.
 IndexType getIndexType()
          Gets index type
 Integer getPages()
          When TYPE is tableIndexStatisic then this is the number of pages used for the table, otherwise it is the number of pages used for the current index.
 Boolean isUnique()
          Can index values be non-unique. false when TYPE is tableIndexStatistic.
 void setCardinality(Integer cardinality)
          When TYPE is tableIndexStatistic, then this is the number of rows in the table; otherwise, it is the number of unique values in the index.
 void setFilterCondition(String filterCondition)
          Sets the filter condition, if any.
 void setIndexType(IndexType indexType)
          Sets index type
 void setPages(Integer pages)
          When TYPE is tableIndexStatisic then this is the number of pages used for the table, otherwise it is the number of pages used for the current index.
 void setUnique(Boolean unique)
          Can index values be non-unique. false when TYPE is tableIndexStatistic.
 
Methods inherited from interface org.jboss.dna.common.jdbc.model.api.SchemaObject
getCatalog, getSchema, setCatalog, setSchema
 
Methods inherited from interface org.jboss.dna.common.jdbc.model.api.DatabaseNamedObject
addExtraProperty, deleteExtraProperty, getExtraProperties, getExtraProperty, getName, getRemarks, setName, setRemarks
 

Method Detail

getColumns

Set<IndexColumn> getColumns()
Retrieves index columns

Returns:
index columns

addColumn

void addColumn(IndexColumn indexColumn)
Adds IndexColumn

Parameters:
indexColumn - the IndexColumn

deleteColumn

void deleteColumn(IndexColumn indexColumn)
delete IndexColumn

Parameters:
indexColumn - the IndexColumn

findColumnByName

IndexColumn findColumnByName(String columnName)
Returns index column for specified column name or null

Parameters:
columnName - the name of column
Returns:
index column for specified column name or null.

isUnique

Boolean isUnique()
Can index values be non-unique. false when TYPE is tableIndexStatistic.

Returns:
true if index values can be non-unique.

setUnique

void setUnique(Boolean unique)
Can index values be non-unique. false when TYPE is tableIndexStatistic.

Parameters:
unique - true if index values can be non-unique.

getIndexType

IndexType getIndexType()
Gets index type

Returns:
index type

setIndexType

void setIndexType(IndexType indexType)
Sets index type

Parameters:
indexType - index type

getCardinality

Integer getCardinality()
When TYPE is tableIndexStatistic, then this is the number of rows in the table; otherwise, it is the number of unique values in the index.

Returns:
the number of rows in the table if index type is STATISTICS; otherwise, the number of unique values in the index.

setCardinality

void setCardinality(Integer cardinality)
When TYPE is tableIndexStatistic, then this is the number of rows in the table; otherwise, it is the number of unique values in the index.

Parameters:
cardinality - the number of rows in the table if index type is STATISTICS; otherwise, the number of unique values in the index.

getPages

Integer getPages()
When TYPE is tableIndexStatisic then this is the number of pages used for the table, otherwise it is the number of pages used for the current index.

Returns:
the number of pages used for the table if index type is STATISTICS; otherwise the number of pages used for the current index.

setPages

void setPages(Integer pages)
When TYPE is tableIndexStatisic then this is the number of pages used for the table, otherwise it is the number of pages used for the current index.

Parameters:
pages - the number of pages used for the table if index type is STATISTICS; otherwise the number of pages used for the current index.

getFilterCondition

String getFilterCondition()
Returns the filter condition, if any. (may be null)

Returns:
the filter condition, if any. (may be null)

setFilterCondition

void setFilterCondition(String filterCondition)
Sets the filter condition, if any. (may be null)

Parameters:
filterCondition - the filter condition, if any. (may be null)


Copyright © 2008-Present JBoss a division of Red Hat. All Rights Reserved.