org.apache.commons.dbutils
インタフェース RowProcessor

既知の実装クラスの一覧:
BasicRowProcessor

public interface RowProcessor

RowProcessor の実装は、 ResultSet の行を他のさまざまなオブジェクトへ変換します。 実装は、このインターフェースに対する変更から自身を保護するために、 BasicRowProcessor を継承可能です。

RowProcessor implementations convert ResultSet rows into various other objects. Implementations can extend BasicRowProcessor to protect themselves from changes to this interface.

作成者:
David Graham
関連項目:
BasicRowProcessor
翻訳者:
小川 環
校正者:
日置 聡
翻訳状況:
校正者校正中
翻訳更新日:
2003/12/22

メソッドの概要
 Object[] toArray(ResultSet rs)
          ResultSet 一行分のカラム値から Object[] を作成します。
 Object toBean(ResultSet rs, Class type)
          ResultSet 一行分のカラム値から JavaBean を作成します。
 List toBeanList(ResultSet rs, Class type)
          ResultSet 全行のカラム値からJavaBeansの List を作成します。
 Map toMap(ResultSet rs)
          ResultSet 一行分のカラム値から Map を作成します。
 

メソッドの詳細

toArray

public Object[] toArray(ResultSet rs)
                 throws SQLException
ResultSet 一行分のカラム値から Object[] を作成します。 ResultSet はこのメソッドへ渡す前に、有効な行へ位置を設定しておいてください。 このメソッドの実装では、ResultSet の行の位置を変更してはいけません。
Create an Object[] from the column values in one ResultSet row. The ResultSet should be positioned on a valid row before passing it to this method. Implementations of this method must not alter the row position of the ResultSet.

例外:
SQLException

toBean

public Object toBean(ResultSet rs,
                     Class type)
              throws SQLException
ResultSet 一行分のカラム値から JavaBean を作成します。 ResultSet はこのメソッドへ渡す前に、有効な行へ位置を設定しておいてください。 このメソッドの実装では、ResultSet の行の位置を変更してはいけません。
Create a JavaBean from the column values in one ResultSet row. The ResultSet should be positioned on a valid row before passing it to this method. Implementations of this method must not alter the row position of the ResultSet.

例外:
SQLException

toBeanList

public List toBeanList(ResultSet rs,
                       Class type)
                throws SQLException
ResultSet 全行のカラム値からJavaBeansの List を作成します。 このメソッドへ渡す前に、ResultSet.next() を呼び出しを行わないでください
Create a List of JavaBeans from the column values in all ResultSet rows. ResultSet.next() should not be called before passing it to this method.

戻り値:
ResultSet によって返された順序にしたがっている指定された型の Bean の List
A List of beans with the given type in the order they were returned by the ResultSet.
例外:
SQLException

toMap

public Map toMap(ResultSet rs)
          throws SQLException
ResultSet 一行分のカラム値から Map を作成します。 ResultSet はこのメソッドへ渡す前に、有効な行へ位置を設定しておいてください。 このメソッドの実装では、ResultSet の行の位置を変更してはいけません。
Create a Map from the column values in one ResultSet row. The ResultSet should be positioned on a valid row before passing it to this method. Implementations of this method must not alter the row position of the ResultSet.

例外:
SQLException


このドキュメントは、Ja-Jakartaにより訳されました。 コメントがある場合は report@jajakarta.orgまでお願いします。
Translated into Japanese by jajakarta.org. The original page is here.
Copyright (c) 2002-2003 - Apache Software Foundation