C# Class Lucene.Net.Index.IndexWriter.ReaderPool

Holds shared SegmentReader instances. IndexWriter uses SegmentReaders for 1) applying deletes, 2) doing merges, 3) handing out a real-time reader. this pool reuses instances of the SegmentReaders in all these places if it is in "near real-time mode" (getReader() has been called on this instance).
Inheritance: IDisposable
Afficher le fichier Open project: synhershko/lucene.net

Méthodes publiques

Méthode Description
Dispose ( ) : void

Remove all our references to readers, and commits any pending changes.

Get ( SegmentInfo info, bool doOpenStores ) : Lucene.Net.Index.SegmentReader

Obtain a SegmentReader from the readerPool. The reader must be returned by calling Release(SegmentReader)

Get ( SegmentInfo info, bool doOpenStores, int readBufferSize, int termsIndexDivisor ) : Lucene.Net.Index.SegmentReader

Obtain a SegmentReader from the readerPool. The reader must be returned by calling Release(SegmentReader)

GetIfExists ( SegmentInfo info ) : Lucene.Net.Index.SegmentReader
GetReadOnlyClone ( SegmentInfo info, bool doOpenStores, int termInfosIndexDivisor ) : Lucene.Net.Index.SegmentReader

Returns a ref to a clone. NOTE: this clone is not enrolled in the pool, so you should simply close() it when you're done (ie, do not call release()).

InfoIsLive ( SegmentInfo info ) : bool
MapToLive ( SegmentInfo info ) : SegmentInfo
ReaderPool ( IndexWriter enclosingInstance ) : System
Release ( Lucene.Net.Index.SegmentReader sr ) : void

Release the segment reader (i.e. decRef it and close if there are no more references.

Release ( Lucene.Net.Index.SegmentReader sr, bool drop ) : void

Release the segment reader (i.e. decRef it and close if there are no more references.

Méthodes protégées

Méthode Description
Dispose ( bool disposing ) : void

Private Methods

Méthode Description
Clear ( SegmentInfos infos ) : void

Forcefully clear changes for the specifed segments, and remove from the pool. This is called on succesful merge.

Commit ( ) : void

Commit all segment reader in the pool.

InitBlock ( IndexWriter enclosingInstance ) : void

Method Details

Dispose() public méthode

Remove all our references to readers, and commits any pending changes.
public Dispose ( ) : void
Résultat void

Dispose() protected méthode

protected Dispose ( bool disposing ) : void
disposing bool
Résultat void

Get() public méthode

Obtain a SegmentReader from the readerPool. The reader must be returned by calling Release(SegmentReader)
public Get ( SegmentInfo info, bool doOpenStores ) : Lucene.Net.Index.SegmentReader
info SegmentInfo ///
doOpenStores bool ///
Résultat Lucene.Net.Index.SegmentReader

Get() public méthode

Obtain a SegmentReader from the readerPool. The reader must be returned by calling Release(SegmentReader)
public Get ( SegmentInfo info, bool doOpenStores, int readBufferSize, int termsIndexDivisor ) : Lucene.Net.Index.SegmentReader
info SegmentInfo ///
doOpenStores bool ///
readBufferSize int ///
termsIndexDivisor int ///
Résultat Lucene.Net.Index.SegmentReader

GetIfExists() public méthode

public GetIfExists ( SegmentInfo info ) : Lucene.Net.Index.SegmentReader
info SegmentInfo
Résultat Lucene.Net.Index.SegmentReader

GetReadOnlyClone() public méthode

Returns a ref to a clone. NOTE: this clone is not enrolled in the pool, so you should simply close() it when you're done (ie, do not call release()).
public GetReadOnlyClone ( SegmentInfo info, bool doOpenStores, int termInfosIndexDivisor ) : Lucene.Net.Index.SegmentReader
info SegmentInfo
doOpenStores bool
termInfosIndexDivisor int
Résultat Lucene.Net.Index.SegmentReader

InfoIsLive() public méthode

public InfoIsLive ( SegmentInfo info ) : bool
info SegmentInfo
Résultat bool

MapToLive() public méthode

public MapToLive ( SegmentInfo info ) : SegmentInfo
info SegmentInfo
Résultat SegmentInfo

ReaderPool() public méthode

public ReaderPool ( IndexWriter enclosingInstance ) : System
enclosingInstance IndexWriter
Résultat System

Release() public méthode

Release the segment reader (i.e. decRef it and close if there are no more references.
public Release ( Lucene.Net.Index.SegmentReader sr ) : void
sr Lucene.Net.Index.SegmentReader ///
Résultat void

Release() public méthode

Release the segment reader (i.e. decRef it and close if there are no more references.
public Release ( Lucene.Net.Index.SegmentReader sr, bool drop ) : void
sr Lucene.Net.Index.SegmentReader ///
drop bool
Résultat void