private GetReaderForMerge ( IOContext context ) : Lucene.Net.Index.SegmentReader | ||
context | IOContext | |
Результат | Lucene.Net.Index.SegmentReader |
internal virtual SegmentReader GetReaderForMerge(IOContext context)
{
lock (this)
{
//Debug.Assert(Thread.holdsLock(Writer));
// must execute these two statements as atomic operation, otherwise we
// could lose updates if e.g. another thread calls writeFieldUpdates in
// between, or the updates are applied to the obtained reader, but then
// re-applied in IW.commitMergedDeletes (unnecessary work and potential
// bugs).
IsMerging = true;
return GetReader(context);
}
}