Class ArrayHandler
java.lang.Object
org.apache.commons.dbutils.handlers.ArrayHandler
- All Implemented Interfaces:
ResultSetHandler<Object[]>
ResultSetHandler implementation that converts a
ResultSet into an Object[]. This class is
thread safe.- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionCreates a new instance of ArrayHandler using aBasicRowProcessorfor conversion.ArrayHandler(RowProcessor convert) Creates a new instance of ArrayHandler. -
Method Summary
-
Constructor Details
-
ArrayHandler
public ArrayHandler()Creates a new instance of ArrayHandler using aBasicRowProcessorfor conversion. -
ArrayHandler
Creates a new instance of ArrayHandler.- Parameters:
convert- TheRowProcessorimplementation to use when converting rows into arrays.
-
-
Method Details
-
handle
Places the column values from the first row in anObject[].- Specified by:
handlein interfaceResultSetHandler<Object[]>- Parameters:
resultSet-ResultSetto process.- Returns:
- An Object[]. If there are no rows in the
ResultSetan empty array will be returned. - Throws:
SQLException- if a database access error occurs- See Also:
-