インタフェース AutoInsert<T>
-
- 型パラメータ:
T- 処理対象となるエンティティの型
- 既知の実装クラスのリスト:
AutoInsertImpl
public interface AutoInsert<T>挿入を行うSQLを自動生成するクエリです。- バージョン:
- 0.3
- 作成者:
- T.TSUCHIE
-
-
メソッドの概要
すべてのメソッド インスタンス・メソッド abstractメソッド 修飾子とタイプ メソッド 説明 AutoInsert<T>excludes(PropertyPath<?>... properties)指定のプロパティを挿入対象から除外します。intexecute()クエリを実行します。AutoInsert<T>includes(PropertyPath<?>... properties)指定のプロパティのみを挿入対象とします。AutoInsert<T>queryTimeout(int seconds)クエリタイムアウトの秒数を設定します。
-
-
-
メソッドの詳細
-
queryTimeout
AutoInsert<T> queryTimeout(int seconds)
クエリタイムアウトの秒数を設定します。-1 を指定するとJDBC ドライバーのデフォルト値を使用します。
- パラメータ:
seconds- クエリタイムアウトの秒数- 戻り値:
- 自身のインスタンス。
- 導入されたバージョン:
- 0.3
-
includes
AutoInsert<T> includes(PropertyPath<?>... properties)
指定のプロパティのみを挿入対象とします。ID(主キー)、バージョンキー(排他キー)の場合は、必ず挿入対象となります。
excludes(PropertyPath...)と同時に指定した場合、includes(PropertyPath...)が優先されます。- パラメータ:
properties- 挿入対象のプロパティ情報。- 戻り値:
- 自身のインスタンス。
- 例外:
IllegalOperateException- エンティティに存在しないプロパティ名を指定した場合にスローされます。
-
excludes
AutoInsert<T> excludes(PropertyPath<?>... properties)
指定のプロパティを挿入対象から除外します。ID(主キー)、バージョンキー(排他キー)の場合は、必ず挿入対象となります。
includes(PropertyPath...)と同時に指定した場合、includes(PropertyPath...)が優先されます。- パラメータ:
properties- 除外対象のプロパティ情報。- 戻り値:
- 自身のインスタンス。
-
execute
int execute()
クエリを実行します。- 戻り値:
- 挿入した行数。
- 例外:
org.springframework.dao.DuplicateKeyException- 主キーなどのが一意制約に違反したとき。
-
-