Пример #1
0
 /// <summary> Sqlite 3 total changes. </summary>
 /// <exception cref="ArgumentNullException"> Thrown when one or more required arguments are null. </exception>
 /// <exception cref="ArgumentException"> Thrown when one or more arguments have unsupported or
 ///     illegal values. </exception>
 /// <param name="db"> The database. </param>
 /// <param name="isMaintenanceDb"> (Optional) True if this object is maintenance database. </param>
 /// <returns> An int. </returns>
 internal int sqlite3_total_changes(SqliteDatabaseHandle db, bool isMaintenanceDb = false)
 {
     if (db == null)
     {
         throw new ArgumentNullException(nameof(db));
     }
     DbProvider.sqlite3 database = (isMaintenanceDb ? db.MaintenanceDb : db.Db)
                                   ?? throw new ArgumentException((isMaintenanceDb
                                           ? "Maintenance mode is specified, but the database is not in Maintenance Mode."
                                           : "The database is in Maintenance Mode, but this was not properly specified."),
                                                                  nameof(isMaintenanceDb));
     return(DbProviderOperations.sqlite3_total_changes(database));
 }