Example #1
0
        private object CloseNestedObjectImplicitly()
        {
            BridgeDataRecord currentNestedRecord = this._currentNestedRecord;

            if (currentNestedRecord != null)
            {
                this._currentNestedRecord = (BridgeDataRecord)null;
                currentNestedRecord.CloseImplicitly();
            }
            BridgeDataReader currentNestedReader = this._currentNestedReader;

            if (currentNestedReader != null)
            {
                this._currentNestedReader = (BridgeDataReader)null;
                currentNestedReader.CloseImplicitly();
            }
            return((object)null);
        }
 /// <summary>
 ///     Implicitly close this (nested) data reader; will be called whenever
 ///     the user has done a GetValue() or a Read() on a parent reader/record
 ///     to ensure that we consume all our results.  We do that because we
 ///     our design requires us to be positioned at the next nested reader's
 ///     first row.
 /// </summary>
 internal void CloseImplicitly()
 {
     EnsureInitialized();
     Consume();
     _dataRecord.CloseImplicitly();
 }