|
database b2007102101 |
||||||||||
| 前のクラス 次のクラス | フレームあり フレームなし | ||||||||||
| 概要: 入れ子 | フィールド | コンストラクタ | メソッド | 詳細: フィールド | コンストラクタ | メソッド | ||||||||||
java.lang.Objectorg.phosphoresce.commons.database.accessor.RecordAccessorAbstract
レコードアクセスクラス抽象クラス
当クラスはレコードアクセスにおける共通のインタフェース及びフィールドを提供します。
各種アクセスサブクラスはこれを継承して、サブクラスに特化した動作を実装します。
また、実装するサブクラスにおいて、各エレメントクラスの状態が変更されたことによる、
任意の処理を行う場合は、自身のクラスに特化したリスナークラスを設け、それをエレメントクラス
に提供し、状態の変更が行われたタイミングで、そのリスナーにイベントを通知して貰います。
なお、リスナークラスの提供は必須ではありません。
| フィールドの概要 | |
protected org.phosphoresce.commons.database.accessor.ResultAccessorListener |
listener
状態管理リスナーオブジェクト |
protected org.apache.commons.logging.Log |
log
ロガーオブジェクト |
protected java.sql.ResultSet |
resultSet
ResultSetオブジェクト |
protected ResultRowDefinition |
rowDefinition
レコード定義情報オブジェクト |
| コンストラクタの概要 | |
protected |
RecordAccessorAbstract(java.sql.ResultSet resultSet)
コンストラクタ |
| メソッドの概要 | |
ResultTemplateRow |
createTemplateRow()
ResultSetの情報を元にした定義情報を保持するテンプレート行情報オブジェクトを生成します。 |
int |
getResultColumnCount()
レコードカラム数を取得します。 |
ResultColumnDefinition |
getResultColumnDefinition(int columnIndex)
指定されたカラムインデックスのカラム定義情報を取得します。 |
ResultColumnDefinition |
getResultColumnDefinition(java.lang.String columnName)
指定されたカラム名のカラム定義情報を取得します。 |
int |
getResultRowCount()
ResultSetが保持するレコード数を取得します。 |
ResultRowDefinition |
getResultRowDefinition()
行定義オブジェクトを取得します。 |
protected int |
getResultSetRowIndex()
現在アクティブなResultSetオブジェクトの行位置を取得します。 |
boolean |
isReadOnly()
レコードアクセスオブジェクトが保持する情報が読み取り専用であるか判定します。 |
protected void |
moveCurser(int rowIndex)
指定された行位置(ResultSet仕様に伴い、1〜)にカーソルを移動します。 |
void |
refreshResult()
ResultSetが現在提供する内容で自身のオブジェクトフィールドの更新を行います。 |
protected boolean |
validateStateListener()
状態管理リスナーオブジェクトが有効であるか判定します。 |
| クラス java.lang.Object から継承したメソッド |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| インタフェース org.phosphoresce.commons.database.accessor.RecordAccessor から継承したメソッド |
deleteRow, getResultColumn, getResultRow, insertRow, insertRow, refreshResult, updateResult |
| フィールドの詳細 |
protected org.apache.commons.logging.Log log
protected java.sql.ResultSet resultSet
protected ResultRowDefinition rowDefinition
protected org.phosphoresce.commons.database.accessor.ResultAccessorListener listener
| コンストラクタの詳細 |
protected RecordAccessorAbstract(java.sql.ResultSet resultSet)
throws ResultSetAccessException,
IllegalResultSetAdjustmentException,
IllegalResultSetLocationIndexException
resultSet - ResultSetオブジェクト
ResultSetAccessException - 不正なResultSetオブジェクトを指定した場合に発生
IllegalResultSetAdjustmentException - 指定されたReusltSetオブジェクトのカーソル位置が先頭手前になっていない場合に発生
IllegalResultSetLocationIndexException - 不正な位置情報を操作した場合に発生| メソッドの詳細 |
public final void refreshResult()
throws ResultSetAccessException,
IllegalResultSetLocationIndexException,
IllegalResultSetAdjustmentException
RecordAccessor 内の refreshResultResultSetAccessException - 正常にResultSetへの操作が行えなかった場合に発生
IllegalResultSetLocationIndexException - 不正な位置情報を操作した場合に発生
IllegalResultSetAdjustmentException - ResultSetとの整合性が取られていない場合に発生RecordAccessor.refreshResult()
public final ResultTemplateRow createTemplateRow()
throws ResultSetAccessException,
IllegalResultSetLocationIndexException,
IllegalResultSetAdjustmentException
RecordAccessor 内の createTemplateRowResultSetAccessException - 正常にResultSetへの操作が行えなかった場合に発生
IllegalResultSetLocationIndexException - 不正な位置情報を操作した場合に発生
IllegalResultSetAdjustmentException - ResultSetとの整合性が取られていない場合に発生RecordAccessor.createTemplateRow()
public final int getResultRowCount()
throws ResultSetAccessException,
IllegalResultSetAdjustmentException
RecordAccessor 内の getResultRowCountResultSetAccessException - 正常にResultSetへの操作が行えなかった場合に発生
IllegalResultSetAdjustmentException - ResultSetとの整合性が取られていない場合に発生RecordAccessor.getResultRowCount()
public final int getResultColumnCount()
throws ResultSetAccessException,
IllegalResultSetAdjustmentException
RecordAccessor 内の getResultColumnCountResultSetAccessException - 正常にResultSetへの操作が行えなかった場合に発生
IllegalResultSetAdjustmentException - ResultSetとの整合性が取られていない場合に発生RecordAccessor.getResultColumnCount()
public final ResultRowDefinition getResultRowDefinition()
throws ResultSetAccessException,
IllegalResultSetAdjustmentException
RecordAccessor 内の getResultRowDefinitionResultSetAccessException - 正常にResultSetへの操作が行えなかった場合に発生
IllegalResultSetAdjustmentException - ResultSetとの整合性が取られていない場合に発生RecordAccessor.getResultRowDefinition()
public final ResultColumnDefinition getResultColumnDefinition(int columnIndex)
throws IllegalResultSetLocationIndexException,
ResultSetAccessException,
IllegalResultSetAdjustmentException
RecordAccessor 内の getResultColumnDefinitioncolumnIndex - カラムインデックス
IllegalResultSetLocationIndexException - 不正な位置情報を操作した場合に発生
ResultSetAccessException - 正常にResultSetへの操作が行えなかった場合に発生
IllegalResultSetAdjustmentException - ResultSetとの整合性が取られていない場合に発生RecordAccessor.getResultColumnDefinition(int)
public final ResultColumnDefinition getResultColumnDefinition(java.lang.String columnName)
throws IllegalResultSetLocationIndexException,
ResultSetAccessException,
IllegalResultSetAdjustmentException
RecordAccessor 内の getResultColumnDefinitioncolumnName - カラム名
IllegalResultSetLocationIndexException - 不正な位置情報を操作した場合に発生
ResultSetAccessException - 正常にResultSetへの操作が行えなかった場合に発生
IllegalResultSetAdjustmentException - ResultSetとの整合性が取られていない場合に発生RecordAccessor.getResultColumnDefinition(java.lang.String)
public final boolean isReadOnly()
throws DatabaseConnectionException
RecordAccessor 内の isReadOnlyDatabaseConnectionException - 正常にデータベースコネクションにアクセスできなかった場合に発生RecordAccessor.isReadOnly()
protected final int getResultSetRowIndex()
throws ResultSetAccessException
ResultSetAccessException - 正常にカーソル移動が行えなかった場合に発生
protected final void moveCurser(int rowIndex)
throws ResultSetAccessException
rowIndex - 行位置(1〜)
ResultSetAccessException - 正常にカーソル移動が行えなかった場合に発生protected final boolean validateStateListener()
|
database b2007102101 |
||||||||||
| 前のクラス 次のクラス | フレームあり フレームなし | ||||||||||
| 概要: 入れ子 | フィールド | コンストラクタ | メソッド | 詳細: フィールド | コンストラクタ | メソッド | ||||||||||