Exemplo n.º 1
0
        private void CloseInternalParameters()
        {
            Debug.Assert(null != _connection, "no connection, CloseInternalParameters");
            Bindings?bindings = _dbBindings;

            _dbBindings = null;
            bindings?.Dispose();
        }
        private void CloseInternalParameters()
        {
            Bindings bindings = this._dbBindings;

            this._dbBindings = null;
            if (bindings != null)
            {
                bindings.Dispose();
            }
        }
 internal void CloseFromDataReader(Bindings bindings)
 {
     if (bindings != null)
     {
         if (this.canceling)
         {
             bindings.Dispose();
         }
         else
         {
             bindings.ApplyOutputParameters();
             this.ParameterBindings = bindings;
         }
     }
     this._hasDataReader = false;
 }
Exemplo n.º 4
0
 // may be called from either
 //      OleDbDataReader.Close/Dispose
 //      via OleDbCommand.Dispose or OleDbConnection.Close
 internal void CloseFromDataReader(Bindings bindings)
 {
     if (null != bindings)
     {
         if (canceling)
         {
             bindings.Dispose();
             Debug.Assert(_dbBindings == bindings, "bindings with two owners");
         }
         else
         {
             bindings.ApplyOutputParameters();
             ParameterBindings = bindings;
         }
     }
     _hasDataReader = false;
 }
Exemplo n.º 5
0
 // may be called from either
 //      OleDbDataReader.Close/Dispose
 //      via OleDbCommand.Dispose or OleDbConnection.Close
 internal void CloseFromDataReader(Bindings bindings) {
     if (null != bindings) {
         if (canceling) {
             bindings.Dispose();
             Debug.Assert(_dbBindings == bindings, "bindings with two owners");
         }
         else {
             bindings.ApplyOutputParameters();
             ParameterBindings = bindings;
         }
     }
     _hasDataReader = false;
 }
 internal void CloseFromDataReader(Bindings bindings)
 {
     if (bindings != null)
     {
         if (this.canceling)
         {
             bindings.Dispose();
         }
         else
         {
             bindings.ApplyOutputParameters();
             this.ParameterBindings = bindings;
         }
     }
     this._hasDataReader = false;
 }