-
- すべてのスーパーインタフェース:
AutoCloseable,Orm
- 既知のサブインタフェースのリスト:
OrmTransaction
public interface OrmConnection extends Orm, AutoCloseable
- 作成者:
- yuu_nkjm
-
-
メソッドの概要
すべてのメソッド staticメソッド インスタンス・メソッド abstractメソッド 修飾子とタイプ メソッド 説明 voidclose()Closes theConnectionassociated with this instance.voidcommit()Commits theConnectionassociated with this instance.<T> TableMappedOrmConnection<T>mapToTable(Class<T> type)Gets aTableMappedOrmConnectioninstance indicated the given parameter.<T> TableMappedOrmConnection<T>mapToTable(Class<T> type, String tableName)Gets aTableMappedOrmConnectioninstance indicated the given parameters.static OrmConnectionof(Connection connection)Create aOrmConnectionwrapping the given JDBC Connection.static OrmConnectionof(Connection connection, SormContext sormContext)Create aOrmConnectionwrapping the given JDBC Connection and the given context.voidrollback()Roll back theConnectionassociated with this instance.voidsetAutoCommit(boolean autoCommit)Sets the auto commit behavior for theConnectionassociated with this instance.-
インタフェースから継承されたメソッド org.nkjmlab.sorm4j.Orm
delete, delete, delete, deleteAll, deleteAllIn, deleteByPrimaryKey, deleteByPrimaryKeyIn, deleteIn, deleteIn, deleteIn, executeQuery, executeQuery, executeQuery, executeQuery, executeUpdate, executeUpdate, exists, exists, exists, exists, getContext, getJdbcConnection, getJdbcDatabaseMetaData, getResultSetTraverser, getRowMapper, getTableMetaData, getTableMetaData, getTableName, getTableSql, getTableSql, insert, insert, insert, insertAndGet, insertAndGet, insertAndGet, insertAndGetIn, insertAndGetIn, insertAndGetIn, insertIn, insertIn, insertIn, insertMapIn, insertMapIn, insertMapIn, joinOn, joinOn, joinUsing, leftJoinOn, leftJoinOn, merge, merge, merge, mergeIn, mergeIn, mergeIn, readFirst, readFirst, readList, readList, readOne, readOne, readTupleList, readTupleList, readTupleList, readTupleList, selectAll, selectByPrimaryKey, stream, stream, streamAll, update, update, update, updateByPrimaryKey, updateByPrimaryKeyIn, updateIn, updateIn, updateIn
-
-
-
-
メソッドの詳細
-
of
static OrmConnection of(Connection connection)
Create aOrmConnectionwrapping the given JDBC Connection. You should always use try-with-resources block to ensure the database connection is released.- パラメータ:
connection-- 戻り値:
-
of
static OrmConnection of(Connection connection, SormContext sormContext)
Create aOrmConnectionwrapping the given JDBC Connection and the given context. You should always use try-with-resources block to ensure the database connection is released.- パラメータ:
connection-sormContext-- 戻り値:
-
close
void close()
Closes theConnectionassociated with this instance.- 定義:
closeインタフェース内AutoCloseable- 関連項目:
Connection.close()
-
commit
void commit()
Commits theConnectionassociated with this instance.- 関連項目:
Connection.commit()
-
rollback
void rollback()
Roll back theConnectionassociated with this instance.- 関連項目:
Connection.rollback()
-
setAutoCommit
void setAutoCommit(boolean autoCommit)
Sets the auto commit behavior for theConnectionassociated with this instance.
-
mapToTable
<T> TableMappedOrmConnection<T> mapToTable(Class<T> type)
Gets aTableMappedOrmConnectioninstance indicated the given parameter. The table name is guessed from the given type.- 型パラメータ:
T-- パラメータ:
type-- 戻り値:
-
mapToTable
<T> TableMappedOrmConnection<T> mapToTable(Class<T> type, String tableName)
Gets aTableMappedOrmConnectioninstance indicated the given parameters.- 型パラメータ:
T-- パラメータ:
type-tableName-- 戻り値:
-
-