Class ReaderManager
Utility class to safely share DirectoryReader instances across
multiple threads, while periodically reopening. This class ensures each
reader is disposed only once all threads have finished using it.
Note
This API is experimental and might change in incompatible ways in the next release.
Inheritance
System.Object
ReaderManager
Implements
System.IDisposable
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Assembly: Lucene.Net.dll
Syntax
public sealed class ReaderManager : ReferenceManager<DirectoryReader>, IDisposable
Constructors
|
Improve this Doc
View Source
ReaderManager(IndexWriter, Boolean)
Declaration
public ReaderManager(IndexWriter writer, bool applyAllDeletes)
Parameters
Exceptions
Type |
Condition |
System.IO.IOException |
If there is a low-level I/O error
|
|
Improve this Doc
View Source
ReaderManager(Directory)
Declaration
public ReaderManager(Directory dir)
Parameters
Exceptions
Type |
Condition |
System.IO.IOException |
If there is a low-level I/O error
|
Methods
|
Improve this Doc
View Source
DecRef(DirectoryReader)
Declaration
protected override void DecRef(DirectoryReader reference)
Parameters
Overrides
Lucene.Net.Search.ReferenceManager<Lucene.Net.Index.DirectoryReader>.DecRef(Lucene.Net.Index.DirectoryReader)
|
Improve this Doc
View Source
GetRefCount(DirectoryReader)
Declaration
protected override int GetRefCount(DirectoryReader reference)
Parameters
Returns
Type |
Description |
System.Int32 |
|
Overrides
Lucene.Net.Search.ReferenceManager<Lucene.Net.Index.DirectoryReader>.GetRefCount(Lucene.Net.Index.DirectoryReader)
|
Improve this Doc
View Source
RefreshIfNeeded(DirectoryReader)
Declaration
protected override DirectoryReader RefreshIfNeeded(DirectoryReader referenceToRefresh)
Parameters
Returns
Overrides
Lucene.Net.Search.ReferenceManager<Lucene.Net.Index.DirectoryReader>.RefreshIfNeeded(Lucene.Net.Index.DirectoryReader)
|
Improve this Doc
View Source
TryIncRef(DirectoryReader)
Declaration
protected override bool TryIncRef(DirectoryReader reference)
Parameters
Returns
Type |
Description |
System.Boolean |
|
Overrides
Lucene.Net.Search.ReferenceManager<Lucene.Net.Index.DirectoryReader>.TryIncRef(Lucene.Net.Index.DirectoryReader)
Implements
System.IDisposable
Extension Methods
See Also