org.apache.commons.dbutils.handlers
Class MapListHandler
java.lang.Object
org.apache.commons.dbutils.handlers.AbstractListHandler<Map<String,Object>>
org.apache.commons.dbutils.handlers.MapListHandler
- All Implemented Interfaces:
- ResultSetHandler<List<Map<String,Object>>>
public class MapListHandler
- extends AbstractListHandler<Map<String,Object>>
ResultSetHandler implementation that converts a
ResultSet into a List of Maps.
This class is thread safe.
- See Also:
ResultSetHandler
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
MapListHandler
public MapListHandler()
- Creates a new instance of MapListHandler using a
BasicRowProcessor for conversion.
MapListHandler
public MapListHandler(RowProcessor convert)
- Creates a new instance of MapListHandler.
- Parameters:
convert - The RowProcessor implementation
to use when converting rows into Maps.
handleRow
protected Map<String,Object> handleRow(ResultSet rs)
throws SQLException
- Converts the
ResultSet row into a Map object.
- Specified by:
handleRow in class AbstractListHandler<Map<String,Object>>
- Parameters:
rs - ResultSet to process.
- Returns:
- A
Map, never null.
- Throws:
SQLException - if a database access error occurs- See Also:
AbstractListHandler.handle(ResultSet)
Copyright © 2002-2011 The Apache Software Foundation. All Rights Reserved.