Package org.enhydra.instantdb.jdbc

Examples of org.enhydra.instantdb.jdbc.ConnectionExtensions


     * getConnection.
     */
    public void start(Xid xid, int flags) throws XAException {
        doStart (xid, flags);                // do state checks and set state
        curCon.commitOnPrepare = false;            // we will do a REAL prepare
        ConnectionExtensions conExt
                = (ConnectionExtensions)curCon.con;        // get the InstantDB connection
        conExt.startGlobalTransaction (xid);        // associate the transaction with the global TX
        curCon = null;                    // no longer owned by this object
        con = null;                      // ditto
    }
View Full Code Here


    /**
     * Prepares to perform a commit.
     */
    public int prepare(Xid xid) throws XAException {
        StandardXAStatefulConnection stateCon = checkPreparedState (xid);// do generic state checking etc.
        ConnectionExtensions con
                = (ConnectionExtensions)stateCon.con;      // get the InstantDB connection
        int status = con.prepare();              // prepare to commit
        if (status == XA_RDONLY) {              // if transaction didn't update the database
            xaDataSource.freeConnection (xid, false);      // free the connection
        } // if
        return status;
    }
View Full Code Here

TOP

Related Classes of org.enhydra.instantdb.jdbc.ConnectionExtensions

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.