/// <summary> /// If a DB cannot be opened, you may attempt to call this method to /// resurrect as much of the contents of the database as possible. /// Some data may be lost, so be careful when calling this function /// on a database that contains important information. /// </summary> public static void Repair(Options options, string name) { IntPtr error; LevelDBInterop.leveldb_repair_db(options.Handle, name, out error); Throw(error); }
/// <summary> /// If a DB cannot be opened, you may attempt to call this method to /// resurrect as much of the contents of the database as possible. /// Some data may be lost, so be careful when calling this function /// on a database that contains important information. /// Options should not be modified after calling this method. /// </summary> public static void Repair(string name, Options options) { IntPtr error; LevelDBInterop.leveldb_repair_db(options.Handle, name, out error); LevelDBException.Check(error); GC.KeepAlive(options); }