org.springframework.jdbc.core
Class JdbcTemplate.ObjectResultSetExtractor

java.lang.Object
  extended byorg.springframework.jdbc.core.JdbcTemplate.ObjectResultSetExtractor
All Implemented Interfaces:
ResultSetExtractor
Enclosing class:
JdbcTemplate

protected static final class JdbcTemplate.ObjectResultSetExtractor
extends java.lang.Object
implements ResultSetExtractor

ResultSetExtractor implementation that returns single result object.


Constructor Summary
JdbcTemplate.ObjectResultSetExtractor(java.lang.Class requiredType)
           
 
Method Summary
 java.lang.Object extractData(java.sql.ResultSet rs)
          Implementations must implement this method to process all rows in the ResultSet.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JdbcTemplate.ObjectResultSetExtractor

public JdbcTemplate.ObjectResultSetExtractor(java.lang.Class requiredType)
Method Detail

extractData

public java.lang.Object extractData(java.sql.ResultSet rs)
                             throws java.sql.SQLException
Description copied from interface: ResultSetExtractor
Implementations must implement this method to process all rows in the ResultSet.

Specified by:
extractData in interface ResultSetExtractor
Parameters:
rs - ResultSet to extract data from. Implementations should not close this: it will be closed by the JdbcTemplate.
Returns:
an arbitrary result object
Throws:
java.sql.SQLException - if a SQLException is encountered getting column values or navigating (that is, there's no need to catch SQLException)


Copyright (C) 2003-2004 The Spring Framework Project.