/// <summary> /// See <see cref="Bamboo.Prevalence.Indexing.IIndex.Remove"/> for details. /// </summary> /// <param name="record">record that should be removed from the index</param> /// <remarks>reference comparison is always used</remarks> public void Remove(Bamboo.Prevalence.Indexing.IRecord record) { foreach (Postings postings in _postings.Values) { postings.Remove(record); } }
/// <summary> /// See <see cref="Bamboo.Prevalence.Indexing.IIndex.Add"/> for details. /// </summary> /// <param name="record">record that should be indexed</param> /// <remarks> /// Indexes all the fields included in the /// <see cref="Fields"/> collection. Notice /// however that the record is never automatically /// reindexed should its fields change or should /// the collection of indexed fields (<see cref="Fields"/>) /// change.<br /> /// The application is always responsible for calling /// <see cref="Update"/> in such cases. /// </remarks> public void Add(Bamboo.Prevalence.Indexing.IRecord record) { foreach (IndexedField field in _fields) { IndexByField(record, field); } }
/// <summary> /// See <see cref="Bamboo.Prevalence.Indexing.IIndex.Update"/> for details. /// </summary> /// <param name="record">existing record that should have its index information updated</param> /// <remarks>reference comparison is always used</remarks> public void Update(Bamboo.Prevalence.Indexing.IRecord record) { Remove(record); Add(record); }