|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.sourceforge.sqlunit.handlers.SqlHandler
net.sourceforge.sqlunit.handlers.CallHandler
public class CallHandler
The CallHandler class processes the contents of a call tag in the input XML file.
Constructor Summary | |
---|---|
CallHandler()
|
Method Summary | |
---|---|
protected java.sql.Statement |
acquireStatementObject(java.sql.Connection conn,
java.lang.String stmt)
Overrides the parent method to build a CallableStatement object from the Connection and SQL string. |
protected void |
clrOutputParameters(java.sql.Statement cs,
Param[] params)
Overrides the parent method to clear parameters in the DatabaseResult object. |
protected boolean |
isMoreResultsAvailable(boolean hasResults,
int rowsUpdated)
Overrides the parent method to return true if more results are available. |
java.lang.Object |
process(org.jdom.Element elCall)
Runs the SQL Stored Procedure contained in the call tag in the input XML file. |
protected void |
setOutputParameters(java.sql.Statement cs,
Param[] params,
DatabaseResult result)
Overrides the parent method to set the OUT parameters into the DatabaseResult object. |
protected java.sql.Statement |
setParameters(java.sql.Statement cs,
Param[] params)
Overrides the parent method to set replaceable parameters, if any, into the CallableStatement object. |
Methods inherited from class net.sourceforge.sqlunit.handlers.SqlHandler |
---|
acquireConnection, executeQuery, executeSQL, initDatabaseResult |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public CallHandler()
Method Detail |
---|
public final java.lang.Object process(org.jdom.Element elCall) throws java.lang.Exception
process
in interface IHandler
process
in class SqlHandler
elCall
- the JDOM Element representing the call tag.
java.lang.Exception
- if there was a problem running the SQL.protected final java.sql.Statement acquireStatementObject(java.sql.Connection conn, java.lang.String stmt) throws java.lang.Exception
acquireStatementObject
in class SqlHandler
conn
- the Connection object.stmt
- the SQL string.
java.lang.Exception
- if there was a problem building the Statement.protected final java.sql.Statement setParameters(java.sql.Statement cs, Param[] params) throws java.lang.Exception
setParameters
in class SqlHandler
cs
- the Statement object.params
- the array of Param objects.
java.lang.Exception
- if there was a problem setting the parameters.protected final boolean isMoreResultsAvailable(boolean hasResults, int rowsUpdated)
isMoreResultsAvailable
in class SqlHandler
hasResults
- boolean generated from cs.execute().rowsUpdated
- int generated from cs.getUpdateCount().
protected final void setOutputParameters(java.sql.Statement cs, Param[] params, DatabaseResult result) throws java.lang.Exception
setOutputParameters
in class SqlHandler
cs
- the Statement object.params
- the array of Param objects.result
- the DatabaseResult object.
java.lang.Exception
- if there was a problem setting the OUT params.protected final void clrOutputParameters(java.sql.Statement cs, Param[] params) throws java.lang.Exception
clrOutputParameters
in class SqlHandler
cs
- the Statement object.params
- the array of Param objects.
java.lang.Exception
- if there was a problem clearing the out parameters.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |