// We need to scan the notes initially to fill up last_modified_table // Otherwise, we might miss deletions that occur before any addition private void ScanNotesInitial() { NotesIndexableGenerator generator = new NotesIndexableGenerator(this, knotes_file, last_modified_table, true); // just a dummy scan while (generator.HasNextIndexable()) { generator.GetNextIndexable(); } }
///////////////////////////////////////////////// private void Index() { if (ThisScheduler.ContainsByTag("KNotes")) { Logger.Log.Debug("Not adding task for already running KNotes task"); return; } // Then add the notes from the notes file NotesIndexableGenerator generator = new NotesIndexableGenerator(this, knotes_file, last_modified_table, false); Scheduler.Task task; task = NewAddTask(generator); task.Tag = "KNotes"; // Make sure add task gets scheduled after delete task task.Priority = Scheduler.Priority.Delayed; task.SubPriority = 0; ThisScheduler.Add(task); }
///////////////////////////////////////////////// private void Index () { if (ThisScheduler.ContainsByTag ("KNotes")) { Logger.Log.Debug ("Not adding task for already running KNotes task"); return; } // Then add the notes from the notes file NotesIndexableGenerator generator = new NotesIndexableGenerator (this, knotes_file, last_modified_table, false); Scheduler.Task task; task = NewAddTask (generator); task.Tag = "KNotes"; // Make sure add task gets scheduled after delete task task.Priority = Scheduler.Priority.Delayed; task.SubPriority = 0; ThisScheduler.Add (task); }
// We need to scan the notes initially to fill up last_modified_table // Otherwise, we might miss deletions that occur before any addition private void ScanNotesInitial () { NotesIndexableGenerator generator = new NotesIndexableGenerator (this, knotes_file, last_modified_table, true); // just a dummy scan while (generator.HasNextIndexable ()) generator.GetNextIndexable (); }