コード例 #1
0
        public void Dispose()
        {
            if (m_isDisposed)
            {
                return;
            }

            if (!m_inTransaction)
            {
                return;
            }

            bool isCommited = false;

            try
            {
                if (m_shouldCommit)
                {
                    m_transactionManager.ExecuteTransaction();

                    isCommited = true;
                }
            }
            finally
            {
                if (!isCommited)
                {
                    try
                    {
                        m_transactionManager.RollbackTransaction();
                    }
                    catch (Exception)
                    {
                    }
                }

                OnPostFinishTransaction();
            }

            m_isDisposed = true;
        }
コード例 #2
0
 public void RollbackTransaction()
 {
     m_oTransactionManager.RollbackTransaction();
 }