cmttransactionfactory.java

来自「hibernate-3.0.5 中文文档」· Java 代码 · 共 32 行

JAVA
32
字号
//$Id: CMTTransactionFactory.java,v 1.2 2005/05/04 00:13:26 oneovthafew Exp $package org.hibernate.transaction;import java.util.Properties;import org.hibernate.ConnectionReleaseMode;import org.hibernate.HibernateException;import org.hibernate.Transaction;import org.hibernate.jdbc.JDBCContext;/** * Factory for <tt>CMTTransaction</tt>. * * @see CMTTransaction * @author Gavin King */public class CMTTransactionFactory implements TransactionFactory {	public ConnectionReleaseMode getDefaultReleaseMode() {		return ConnectionReleaseMode.AFTER_STATEMENT;	}	public void configure(Properties props) throws HibernateException {}	public Transaction beginTransaction(JDBCContext jdbcContext, Context transactionContext) throws HibernateException {		CMTTransaction tx = new CMTTransaction(jdbcContext, transactionContext);		tx.begin();		return tx;	}}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?