transactionfactory.java

来自「用Java实现的23个常用设计模式源代码」· Java 代码 · 共 39 行

JAVA
39
字号
//$Id: TransactionFactory.java,v 1.4 2003/04/25 03:40:36 oneovthafew Exp $package net.sf.hibernate.transaction;import java.util.Properties;import net.sf.hibernate.HibernateException;import net.sf.hibernate.Transaction;import net.sf.hibernate.engine.SessionImplementor;/** * An abstract factory for <tt>Transaction</tt> instances. Concrete implementations * are specified by <tt>hibernate.transaction.factory_class</tt>.<br> * <br> * Implementors must be threadsafe and should declare a public default constructor. * @see Transaction * @author Anton van Straaten, Gavin King */public interface TransactionFactory {	/**	 * Begin a transaction and return the associated <tt>Transaction</tt> instance.	 * @param session the session	 * @return Transaction	 * @throws HibernateException	 */	public Transaction beginTransaction(SessionImplementor session) throws HibernateException;		/**	 * Configure from the given properties.	 * @param props	 * @throws HibernateException	 */	public void configure(Properties props) throws HibernateException;}

⌨️ 快捷键说明

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