com.sptci.rwt
Class AbstractTriggerAnalyser
java.lang.Object
com.sptci.rwt.Analyser
com.sptci.rwt.AbstractTriggerAnalyser
- Direct Known Subclasses:
- OracleTriggerAnalyser, StandardTriggerAnalyser
public abstract class AbstractTriggerAnalyser
- extends Analyser
An abstract analyser for analysing trigger type objects in the database.
Serves as the base class for implementation specific trigger analysers.
© Copyright 2007 Sans Pareil Technologies, Inc.
- Since:
- Version 1.2
- Version:
- $Id: AbstractTriggerAnalyser.java 4123 2008-05-25 21:49:01Z rakesh $
- Author:
- Rakesh Vidyadharan 2007-11-02
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
AbstractTriggerAnalyser
protected AbstractTriggerAnalyser(ConnectionManager manager)
- Create a new instance of the class using the specified connection
manager.
- Parameters:
manager - The manager for obtaining database connections.
analyse
public Collection<TriggerMetaData> analyse(MetaData... parameters)
throws SQLException
- Returns a collection of
TriggerMetaData objects that contain
the basic information pertaining to the triggers in the schema and
table (optional) specified.
- Specified by:
analyse in class Analyser
- Parameters:
parameters - Must contain at least one parameter which is a SchemaMetaData that represents the schema to restrict
the analysis to. An optional additional TableMetaData
parameter may be specified to restrict the analysis to a specified
table.
- 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...)
createStatement
protected abstract PreparedStatement createStatement(Connection connection,
MetaData... parameters)
throws SQLException
- Create a
PreparedStatement based on the
parameters passed in.
- Parameters:
connection - The database connection to use.parameters - The array of SchemaMetaData and TableMetaData objects.
- Returns:
- PreparedStatement The initialised statement that can be executed.
- Throws:
SQLException - If errors are encountered while creating the
statement.- See Also:
Analyser.getNames(com.sptci.rwt.MetaData)
createMetaData
protected abstract void createMetaData(ResultSet resultSet,
Collection<TriggerMetaData> collection,
MetaData... parameters)
throws SQLException
- Create a new metadata object out of the data in the specified result
set.
- Parameters:
resultSet - The result set from which to create the metadata.collection - The collection to which the metadata objects are
to be added.parameters - The array of RootMetaData and TableMetaData objects.
- Throws:
SQLException - If errors are encountered while fetching the
data from the result set.