System.Data.SQLite
Check-in [85f27cc9f8]
Not logged in

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Raise the static OnChanged event for the connection when a data reader is created.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | onChanged
Files: files | file ages | folders
SHA1: 85f27cc9f8d10d351e3ec6c2144fd43db46ecb86
User & Date: mistachkin 2013-08-29 23:00:02
References
2013-08-29
23:01 Ticket [aba4549801] SQLiteStatementHandles are not being disposed properly with EF or Linq2SQL status still Pending with 3 other changes artifact: 4c7d88ed0a user: mistachkin
Context
2013-09-04
03:42
Allow monitoring of the creation of all critical handle derived class instances. check-in: b194408bb5 user: mistachkin tags: onChanged
2013-08-29
23:00
Raise the static OnChanged event for the connection when a data reader is created. check-in: 85f27cc9f8 user: mistachkin tags: onChanged
09:08
Update SQLite core library to the latest trunk. check-in: fec273cc1d user: mistachkin tags: trunk
Changes
Hide Diffs Side-by-Side Diffs Ignore Whitespace Patch

Changes to System.Data.SQLite/SQLiteConnection.cs.


Changes to System.Data.SQLite/SQLiteConvert.cs.

  1294   1294         EnlistTransaction = 6,
  1295   1295   
  1296   1296         /// <summary>
  1297   1297         /// A command was created using the connection.
  1298   1298         /// </summary>
  1299   1299         NewCommand = 7,
  1300   1300   
         1301  +      /// <summary>
         1302  +      /// A data reader was created using the connection.
         1303  +      /// </summary>
         1304  +      NewDataReader = 8,
         1305  +
  1301   1306         /// <summary>
  1302   1307         /// The connection is being closed.
  1303   1308         /// </summary>
  1304         -      Closing = 8,
         1309  +      Closing = 9,
  1305   1310   
  1306   1311         /// <summary>
  1307   1312         /// The connection was closed.
  1308   1313         /// </summary>
  1309         -      Closed = 9
         1314  +      Closed = 10
  1310   1315     }
  1311   1316   
  1312   1317     /// <summary>
  1313   1318     /// This implementation of SQLite for ADO.NET can process date/time fields in databases in only one of three formats.  Ticks, ISO8601
  1314   1319     /// and JulianDay.
  1315   1320     /// </summary>
  1316   1321     /// <remarks>

Changes to System.Data.SQLite/SQLiteDataReader.cs.

   101    101         _baseSchemaName = _command.Connection._baseSchemaName;
   102    102   
   103    103         _commandBehavior = behave;
   104    104         _activeStatementIndex = -1;
   105    105         _rowsAffected = -1;
   106    106   
   107    107         if (_command != null)
   108         -        NextResult();
          108  +      {
          109  +          SQLiteConnection.OnChanged(_command.Connection,
          110  +              new ConnectionEventArgs(SQLiteConnectionEventType.NewDataReader,
          111  +                  null, null, _command, null, new object[] { this, behave }));
          112  +
          113  +          NextResult();
          114  +      }
   109    115       }
   110    116   
   111    117       ///////////////////////////////////////////////////////////////////////////////////////////////
   112    118   
   113    119       #region IDisposable "Pattern" Members
   114    120       private bool disposed;
   115    121       private void CheckDisposed() /* throw */