Ejemplo n.º 1
0
        internal void VersionContextFinished(TransactionContextExecutionVersionContext executionVersionContext)
        {
            if (this.disposed)
            {
                throw new ObjectDisposedException(nameof(TransactionContext));
            }

            if (this.DataAccessTransaction == null)
            {
                this.dataAccessObjectDataContext = null;

                foreach (var cc in this.commandsContextsBySqlDatabaseContexts.Values)
                {
                    cc.Dispose();
                }

                this.commandsContextsBySqlDatabaseContexts.Clear();
                this.dataAccessModel.AsyncLocalTransactionContext = null;
                this.Dispose();
            }
        }
Ejemplo n.º 2
0
		internal void VersionContextFinished(TransactionContextExecutionVersionContext executionVersionContext)
		{
			if (this.disposed)
			{
				throw new ObjectDisposedException(nameof(TransactionContext));
			}

			if (this.DataAccessTransaction == null)
			{
				this.dataAccessObjectDataContext = null;

				foreach (var cc in this.commandsContextsBySqlDatabaseContexts.Values)
				{
					cc.Dispose();
				}

				this.commandsContextsBySqlDatabaseContexts.Clear();
				this.dataAccessModel.AsyncLocalTransactionContext = null;
				this.Dispose();
			}
		}