com.ibatis.sqlmap.client
public interface SqlMapExecutor
See Also: SqlMapSession SqlMapClient
| Method Summary | |
|---|---|
| int | delete(String id, Object parameterObject)
Executes a mapped SQL DELETE statement.
|
| int | delete(String id)
Executes a mapped SQL DELETE statement.
|
| int | executeBatch()
Executes (flushes) all statements currently batched.
|
| List | executeBatchDetailed()
Executes (flushes) all statements currently batched.
|
| Object | insert(String id, Object parameterObject)
Executes a mapped SQL INSERT statement.
|
| Object | insert(String id)
Executes a mapped SQL INSERT statement.
|
| List | queryForList(String id, Object parameterObject)
Executes a mapped SQL SELECT statement that returns data to populate
a number of result objects.
|
| List | queryForList(String id)
Executes a mapped SQL SELECT statement that returns data to populate
a number of result objects.
|
| List | queryForList(String id, Object parameterObject, int skip, int max)
Executes a mapped SQL SELECT statement that returns data to populate
a number of result objects within a certain range.
|
| List | queryForList(String id, int skip, int max)
Executes a mapped SQL SELECT statement that returns data to populate
a number of result objects within a certain range.
|
| Map | queryForMap(String id, Object parameterObject, String keyProp)
Executes a mapped SQL SELECT statement that returns data to populate
a number of result objects that will be keyed into a Map.
|
| Map | queryForMap(String id, Object parameterObject, String keyProp, String valueProp)
Executes a mapped SQL SELECT statement that returns data to populate
a number of result objects from which one property will be keyed into a Map.
|
| Object | queryForObject(String id, Object parameterObject)
Executes a mapped SQL SELECT statement that returns data to populate
a single object instance.
|
| Object | queryForObject(String id)
Executes a mapped SQL SELECT statement that returns data to populate
a single object instance.
|
| Object | queryForObject(String id, Object parameterObject, Object resultObject)
Executes a mapped SQL SELECT statement that returns data to populate
the supplied result object.
|
| PaginatedList | queryForPaginatedList(String id, Object parameterObject, int pageSize)
Executes a mapped SQL SELECT statement that returns data to populate
a number of result objects a page at a time.
|
| PaginatedList | queryForPaginatedList(String id, int pageSize)
Executes a mapped SQL SELECT statement that returns data to populate
a number of result objects a page at a time.
|
| void | queryWithRowHandler(String id, Object parameterObject, RowHandler rowHandler)
Executes a mapped SQL SELECT statement that returns a number of
result objects that will be handled one at a time by a
RowHandler.
|
| void | queryWithRowHandler(String id, RowHandler rowHandler)
Executes a mapped SQL SELECT statement that returns a number of
result objects that will be handled one at a time by a
RowHandler.
|
| void | startBatch()
Starts a batch in which update statements will be cached before being sent to
the database all at once. |
| int | update(String id, Object parameterObject)
Executes a mapped SQL UPDATE statement.
|
| int | update(String id)
Executes a mapped SQL UPDATE statement.
|
Parameters: id The name of the statement to execute. parameterObject The parameter object (e.g. JavaBean, Map, XML etc.).
Returns: The number of rows effected.
Throws: java.sql.SQLException If an error occurs.
Parameters: id The name of the statement to execute.
Returns: The number of rows effected.
Throws: java.sql.SQLException If an error occurs.
Returns: the number of rows updated in the batch
Throws: java.sql.SQLException If the batch could not be executed or if any of the statements fails.
Returns: a List of BatchResult objects. There will be one element in the list for each sub-batch executed. A sub-batch is created by adding a statement to the batch that does not equal the prior statement.
Throws: SQLException if a database access error occurs, or the drive does not support batch statements BatchException if the driver throws BatchUpdateException
See Also: BatchException
Parameters: id The name of the statement to execute. parameterObject The parameter object (e.g. JavaBean, Map, XML etc.).
Returns: The primary key of the newly inserted row. This might be automatically generated by the RDBMS, or selected from a sequence table or other source.
Throws: java.sql.SQLException If an error occurs.
Parameters: id The name of the statement to execute.
Returns: The primary key of the newly inserted row. This might be automatically generated by the RDBMS, or selected from a sequence table or other source.
Throws: java.sql.SQLException If an error occurs.
Parameters: id The name of the statement to execute. parameterObject The parameter object (e.g. JavaBean, Map, XML etc.).
Returns: A List of result objects.
Throws: java.sql.SQLException If an error occurs.
Parameters: id The name of the statement to execute.
Returns: A List of result objects.
Throws: java.sql.SQLException If an error occurs.
Parameters: id The name of the statement to execute. parameterObject The parameter object (e.g. JavaBean, Map, XML etc.). skip The number of results to ignore. max The maximum number of results to return.
Returns: A List of result objects.
Throws: java.sql.SQLException If an error occurs.
Parameters: id The name of the statement to execute. skip The number of results to ignore. max The maximum number of results to return.
Returns: A List of result objects.
Throws: java.sql.SQLException If an error occurs.
Parameters: id The name of the statement to execute. parameterObject The parameter object (e.g. JavaBean, Map, XML etc.). keyProp The property to be used as the key in the Map.
Returns: A Map keyed by keyProp with values being the result object instance.
Throws: java.sql.SQLException If an error occurs.
Parameters: id The name of the statement to execute. parameterObject The parameter object (e.g. JavaBean, Map, XML etc.). keyProp The property to be used as the key in the Map. valueProp The property to be used as the value in the Map.
Returns: A Map keyed by keyProp with values of valueProp.
Throws: java.sql.SQLException If an error occurs.
Parameters: id The name of the statement to execute. parameterObject The parameter object (e.g. JavaBean, Map, XML etc.).
Returns: The single result object populated with the result set data, or null if no result was found
Throws: java.sql.SQLException If more than one result was found, or if any other error occurs.
Parameters: id The name of the statement to execute.
Returns: The single result object populated with the result set data, or null if no result was found
Throws: java.sql.SQLException If more than one result was found, or if any other error occurs.
Parameters: id The name of the statement to execute. parameterObject The parameter object (e.g. JavaBean, Map, XML etc.). resultObject The result object instance that should be populated with result data.
Returns: The single result object as supplied by the resultObject parameter, populated with the result set data, or null if no result was found
Throws: java.sql.SQLException If more than one result was found, or if any other error occurs.
Deprecated: All paginated list features have been deprecated
Executes a mapped SQL SELECT statement that returns data to populate a number of result objects a page at a time. The parameter object is generally used to supply the input data for the WHERE clause parameter(s) of the SELECT statement.Parameters: id The name of the statement to execute. parameterObject The parameter object (e.g. JavaBean, Map, XML etc.). pageSize The maximum number of result objects each page can hold.
Returns: A PaginatedList of result objects.
Throws: java.sql.SQLException If an error occurs.
Deprecated: All paginated list features have been deprecated
Executes a mapped SQL SELECT statement that returns data to populate a number of result objects a page at a time. This overload assumes no parameter is needed.Parameters: id The name of the statement to execute. pageSize The maximum number of result objects each page can hold.
Returns: A PaginatedList of result objects.
Throws: java.sql.SQLException If an error occurs.
Parameters: id The name of the statement to execute. parameterObject The parameter object (e.g. JavaBean, Map, XML etc.). rowHandler A RowHandler instance
Throws: java.sql.SQLException If an error occurs.
Parameters: id The name of the statement to execute. rowHandler A RowHandler instance
Throws: java.sql.SQLException If an error occurs.
Throws: java.sql.SQLException If the batch could not be started.
Parameters: id The name of the statement to execute. parameterObject The parameter object (e.g. JavaBean, Map, XML etc.).
Returns: The number of rows effected.
Throws: java.sql.SQLException If an error occurs.
Parameters: id The name of the statement to execute.
Returns: The number of rows effected.
Throws: java.sql.SQLException If an error occurs.