SPT RWT Application API

com.sptci.rwt
Class IndexAnalyser

java.lang.Object
  extended by com.sptci.rwt.Analyser
      extended by com.sptci.rwt.KeyAnalyser
          extended by com.sptci.rwt.IndexAnalyser

public class IndexAnalyser
extends KeyAnalyser

An analyser for analysing index columns for tables in the database.

© Copyright 2007 Sans Pareil Technologies, Inc.

Version:
$Id: IndexAnalyser.java 4123 2008-05-25 21:49:01Z rakesh $
Author:
Rakesh Vidyadharan 2007-09-25
See Also:
DatabaseMetaData.getIndexInfo(java.lang.String, java.lang.String, java.lang.String, boolean, boolean)

Nested Class Summary
 
Nested classes/interfaces inherited from class com.sptci.rwt.Analyser
Analyser.CatalogueSchema
 
Field Summary
 
Fields inherited from class com.sptci.rwt.Analyser
logger, manager
 
Constructor Summary
IndexAnalyser(ConnectionManager manager)
          Create a new instance of the class using the specified connection manager.
 
Method Summary
 Collection<IndexMetaData> analyse(MetaData... parameters)
          Returns a collection of IndexMetaData objects that contain all information pertaining to the indices for the specified table.
protected  IndexMetaData.SortSequence processSortSequence(String value)
          Process the asc_or_desc value and match them with the appropriate IndexMetaData.SortSequence value.
protected  IndexMetaData.Type processType(short value)
          Process the type values and match them with the appropriate IndexMetaData.Type value.
 
Methods inherited from class com.sptci.rwt.KeyAnalyser
checkTableColumns
 
Methods inherited from class com.sptci.rwt.Analyser
getNames
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

IndexAnalyser

public IndexAnalyser(ConnectionManager manager)
Create a new instance of the class using the specified connection manager.

Parameters:
manager - The manager for obtaining database connections.
Method Detail

analyse

public Collection<IndexMetaData> analyse(MetaData... parameters)
                                  throws SQLException
Returns a collection of IndexMetaData objects that contain all information pertaining to the indices for the specified table.

Specified by:
analyse in class Analyser
Parameters:
parameters - Must contain two parameters which are the names of the catalog/schema and table from which index metadata are to be retrieved.
Returns:
The collection of metadata objects representing all objects of this type.
Throws:
SQLException - If errors are encountered while analysisng the
See Also:
Analyser.analyse(com.sptci.rwt.MetaData...), Analyser.getNames(com.sptci.rwt.MetaData)

processType

protected IndexMetaData.Type processType(short value)
Process the type values and match them with the appropriate IndexMetaData.Type value.

Parameters:
value - The the short value read from result set.
Returns:
The appropriate type value.

processSortSequence

protected IndexMetaData.SortSequence processSortSequence(String value)
Process the asc_or_desc value and match them with the appropriate IndexMetaData.SortSequence value.

Parameters:
value - The the short value read from result set.
Returns:
The appropriate sort order value.

SPT RWT Application API