You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

25 lines
505 B

package container
import (
"github.com/go-xorm/xorm"
)
// 事务句柄工厂
type TransactionHandlerFactory interface {
// 创建事务句柄
// 返回值:
// 1.事务句柄
// 2.错误
Create() (TransactionHandler, error)
}
// 创建事务句柄工厂
// 参数:
// 1.xorm引擎
// 返回值:
// 1.事务句柄工厂
// 异常:
// 1.xorm.Engine不能为空!
func NewTransactionHandlerFactory(engine *xorm.Engine) TransactionHandlerFactory {
return NewDefaultTransactionHandlerFactory(engine)
}