TxnCommit() 개인적인 메소드

private TxnCommit ( IntPtr handle, int flags ) : int
handle System.IntPtr
flags int
리턴 int
예제 #1
0
        /// <summary>
        /// Commits the Transaction
        /// </summary>
        /// <remarks>
        /// This method wraps the native ups_txn_commit function.
        /// <br />
        /// Note that the function will fail with UPS_CURSOR_STILL_OPEN if
        /// a Cursor was attached to this Transaction, and the Cursor was
        /// not closed.
        /// </remarks>
        public void Commit()
        {
            int st;

            lock (env) {
                st = NativeMethods.TxnCommit(handle, 0);
            }
            if (st != 0)
            {
                throw new DatabaseException(st);
            }
            handle = IntPtr.Zero;
            env    = null;
        }