org.apache.commons.dbutils.handlers
クラス BeanListHandler
java.lang.Object
org.apache.commons.dbutils.handlers.BeanListHandler
- すべての実装インタフェース:
- ResultSetHandler
- public class BeanListHandler
- extends Object
- implements ResultSetHandler
ResultSet を JavaBeans の List へ変換する ResultSetHandler の実装です。
このクラスはスレッドセーフです。
ResultSetHandler implementation that converts a
ResultSet into a List of beans. This class is
thread safe.
- 作成者:
- Juozas Baliuka, David Graham
- 関連項目:
ResultSetHandler - 翻訳者:
- 小川 環
- 校正者:
- 日置 聡
- 翻訳状況:
- 校正者校正中
- 翻訳更新日:
- 2003/12/22
| クラス java.lang.Object から継承したメソッド |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
BeanListHandler
public BeanListHandler(Class type)
- BeanListHandler の新規インスタンスを作成します。
Creates a new instance of BeanListHandler.
- パラメータ:
type - handle() より返されたオブジェクトを作るためのクラス。
The Class that objects returned from handle()
are created from.
BeanListHandler
public BeanListHandler(Class type,
RowProcessor convert)
- BeanListHandler の新規インスタンスを作成します。
Creates a new instance of BeanListHandler.
- パラメータ:
type - handle() より返されたオブジェクトを作るためのクラス。
The Class that objects returned from handle()
are created from.
convert - 行を Bean へ変換する際に使用する RowProcessor 実装。
The RowProcessor implementation
to use when converting rows into beans.
handle
public Object handle(ResultSet rs)
throws SQLException
ResultSet の先頭行をコンストラクタに渡された Class
に基づいたBeanの List へ変換します。
Convert the ResultSet rows into a List of
beans with the Class given in the constructor.
- 定義:
- インタフェース
ResultSetHandler 内の handle
- パラメータ:
rs - ハンドルする ResultSet。 このメソッドに渡す前に手をつけてはいけません。
The ResultSet to handle. It has not been touched
before being passed to this method.
- 戻り値:
- Bean (各行に一個)の
List 、null は返されません。
A List of beans (one for each row), never
null.
- 例外:
SQLException- 関連項目:
ResultSetHandler.handle(java.sql.ResultSet)
このドキュメントは、Ja-Jakartaにより訳されました。 コメントがある場合は report@jajakarta.orgまでお願いします。
Translated into Japanese by jajakarta.org. The original page is here.
Copyright (c) 2002-2003 - Apache Software Foundation