接口 ScrollableResultSetProcessor
-
public interface ScrollableResultSetProcessorContract for processing JDBC ResultSets a single logical row at a time. These are intended for use byScrollableResultsimplementations. NOTE : these methods initially taken directly fromLoadercounterparts in an effort to break Loader into manageable pieces, especially in regards to the processing of result sets.- 作者:
- Steve Ebersole
-
-
方法概要
所有方法 实例方法 抽象方法 修饰符和类型 方法 说明 ObjectextractLogicalRowForward(ResultSet resultSet, SessionImplementor session, QueryParameters queryParameters)Given a scrollable ResultSet, extract a logical row.ObjectextractLogicalRowReverse(ResultSet resultSet, SessionImplementor session, QueryParameters queryParameters, boolean isLogicallyAfterLast)LikeextractLogicalRowForward(java.sql.ResultSet, org.hibernate.engine.spi.SessionImplementor, org.hibernate.engine.spi.QueryParameters)but here moving through the ResultSet in reverse.ObjectextractSingleRow(ResultSet resultSet, SessionImplementor session, QueryParameters queryParameters)Give a ResultSet, extract just a single result row.
-
-
-
方法详细资料
-
extractSingleRow
Object extractSingleRow(ResultSet resultSet, SessionImplementor session, QueryParameters queryParameters)
Give a ResultSet, extract just a single result row. Copy ofLoader.loadSingleRow(ResultSet, SharedSessionContractImplementor, QueryParameters, boolean)but dropping the 'returnProxies' (that method has only one use in the entire codebase and it always passes in false...)- 参数:
resultSet- The result set being processed.session- The originating sessionqueryParameters- The "parameters" used to build the query- 返回:
- The extracted result row
- 抛出:
HibernateException- Indicates a problem extracting values from the result set.
-
extractLogicalRowForward
Object extractLogicalRowForward(ResultSet resultSet, SessionImplementor session, QueryParameters queryParameters)
Given a scrollable ResultSet, extract a logical row. The assumption here is that the ResultSet is already properly ordered to account for any to-many fetches. Multiple ResultSet rows are read into a single query result "row". Copy ofLoader.loadSequentialRowsForward(ResultSet, SharedSessionContractImplementor, QueryParameters, boolean)but dropping the 'returnProxies' (that method has only one use in the entire codebase and it always passes in false...)- 参数:
resultSet- The result set being processed.session- The originating sessionqueryParameters- The "parameters" used to build the query- 返回:
- The extracted result row
- 抛出:
HibernateException- Indicates a problem extracting values from the result set.
-
extractLogicalRowReverse
Object extractLogicalRowReverse(ResultSet resultSet, SessionImplementor session, QueryParameters queryParameters, boolean isLogicallyAfterLast)
LikeextractLogicalRowForward(java.sql.ResultSet, org.hibernate.engine.spi.SessionImplementor, org.hibernate.engine.spi.QueryParameters)but here moving through the ResultSet in reverse. Copy ofLoader.loadSequentialRowsReverse(ResultSet, SharedSessionContractImplementor, QueryParameters, boolean, boolean)but dropping the 'returnProxies' (that method has only one use in the entire codebase and it always passes in false...). todo : is 'logicallyAfterLastRow really needed? Can't that be deduced? In fact pretty positive it is not needed.- 参数:
resultSet- The result set being processed.session- The originating sessionqueryParameters- The "parameters" used to build the queryisLogicallyAfterLast- Is the result set currently positioned after the last row; again, is this really needed? How is it any diff- 返回:
- The extracted result row
- 抛出:
HibernateException- Indicates a problem extracting values from the result set.
-
-