org.pojava.persistence.processor
Class ResultSetToList<T>

java.lang.Object
  extended by org.pojava.persistence.processor.ResultSetToList<T>
All Implemented Interfaces:
ResultSetProcessor

public class ResultSetToList<T>
extends Object
implements ResultSetProcessor

Process a data set into a list of objects.

Author:
John Pile

Constructor Summary
ResultSetToList(TableMap<T> map, List<T> list)
          This processor populates a list from the result set.
 
Method Summary
 int process(ResultSet rs)
          Populate each row into a mapped bean, added to a list.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ResultSetToList

public ResultSetToList(TableMap<T> map,
                       List<T> list)
This processor populates a list from the result set.

Parameters:
map -
list -
Method Detail

process

public int process(ResultSet rs)
            throws SQLException
Populate each row into a mapped bean, added to a list.

Specified by:
process in interface ResultSetProcessor
Returns:
number of rows processed
Throws:
SQLException


Copyright © 2011. All Rights Reserved.