Esempio n. 1
0
        public void SaveOrUpdate(TDoc document)
        {
            Storage.SaveOrUpdate(document);

            FulltextBackgroundTaskExecutor.Schedule(() =>
            {
                SearchEngine.Add(document);
                SearchEngine.CommitFulltextIndex();
            });
        }
Esempio n. 2
0
        public void SaveOrUpdate(params TDoc[] docs)
        {
            foreach (var doc in docs)
            {
                Storage.SaveOrUpdate(doc);
            }

            FulltextBackgroundTaskExecutor.Schedule(() =>
            {
                SearchEngine.Add(docs);
                SearchEngine.CommitFulltextIndex();
            });
        }