示例#1
0
            internal int ExecuteTransactedCode()
            {
                TransactedExecState state = TransactedExecState.CommitPending;

                try {
                    _callback();

                    if (Transactions.Utils.AbortPending)
                    {
                        state = TransactedExecState.AbortPending;
                    }
                }
                catch (Exception e) {
                    _error = e; // remember exception to be rethrown back in managed code
                    state  = TransactedExecState.Error;
                }

                return((int)state);
            }
示例#2
0
            internal int ExecuteTransactedCode()
            {
                TransactedExecState commitPending = TransactedExecState.CommitPending;

                try
                {
                    this._callback();
                    if (Transactions.Utils.AbortPending)
                    {
                        commitPending = TransactedExecState.AbortPending;
                    }
                }
                catch (Exception exception)
                {
                    this._error   = exception;
                    commitPending = TransactedExecState.Error;
                }
                return((int)commitPending);
            }