Method Acquire
- Namespace
- TantivyDotNet
- Assembly
- TantivyDotNet.dll
Acquire()
Returns a lease on the current searcher. Dispose the lease when the request is done; the searcher stays valid until then, even if it's replaced meanwhile.
public SearcherLease Acquire()
Returns
Remarks
With RefreshOnCommit, this first swaps in a newer snapshot if Tantivy has reloaded one (running the warmer on this thread). If another thread is already doing that, this one doesn't wait and gets the current searcher.
Exceptions
- ObjectDisposedException
The manager was disposed.