Package com.ibatis.sqlmap.engine.transaction

Examples of com.ibatis.sqlmap.engine.transaction.Transaction


            MappedStatement ms = getMappedStatement(id);

            DEBUG.P("ms=" + ms);

            Transaction trans = getTransaction(sessionScope);

            DEBUG.P("trans=" + trans);

            boolean autoStart = trans == null;
View Full Code Here


            DEBUG.P("max=" + max);

            List list = null;

            MappedStatement ms = getMappedStatement(id);
            Transaction trans = getTransaction(sessionScope);

            DEBUG.P("trans1=" + trans); //通常为null
            boolean autoStart = trans == null;

            try {
View Full Code Here

     */
    public void queryWithRowHandler(SessionScope sessionScope, String id, Object paramObject, RowHandler rowHandler)
            throws SQLException {

        MappedStatement ms = getMappedStatement(id);
        Transaction trans = getTransaction(sessionScope);
        boolean autoStart = trans == null;

        try {
            trans = autoStartTransaction(sessionScope, autoStart, trans);

View Full Code Here

        try {//我加上的
            DEBUG.P(this, "autoStartTransaction(3)");
            DEBUG.P("autoStart=" + autoStart);
            DEBUG.P("trans=" + trans);

            Transaction transaction = trans;
            if (autoStart) {
                DEBUG.P("sessionScope.getSqlMapTxMgr()=" + sessionScope.getSqlMapTxMgr());
                sessionScope.getSqlMapTxMgr().startTransaction();
                transaction = getTransaction(sessionScope);
            }
View Full Code Here

    //Connection从Transaction中获取
    public Connection getCurrentConnection() throws SQLException {
        try {
            Connection conn = null;
            Transaction trans = delegate.getTransaction(sessionScope);
            if (trans != null) {
                conn = trans.getConnection();
            }
            return conn;
        } catch (TransactionException e) {
            throw new NestedSQLException("Error getting Connection from Transaction.  Cause: " + e, e);
        }
View Full Code Here

TOP

Related Classes of com.ibatis.sqlmap.engine.transaction.Transaction

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.