C# Class Lucene.Net.Util.LineFileDocs

Minimal port of benchmark's LneDocSource + DocMaker, so tests can enum docs from a line file created by benchmark's WriteLineDoc task
Inheritance: IDisposable
Datei anzeigen Open project: paulirwin/lucene.net Class Usage Examples

Public Methods

Method Description
Dispose ( ) : void
LineFileDocs ( Random random ) : Lucene.Net.Documents
LineFileDocs ( Random random, bool useDocValues ) : Lucene.Net.Documents
LineFileDocs ( Random random, string path, bool useDocValues ) : Lucene.Net.Documents

If forever is true, we rewind the file at EOF (repeat the docs over and over)

NextDoc ( ) : Document

Note: Document instance is re-used per-thread

Reset ( Random random ) : void

Private Methods

Method Description
Open ( Random random ) : void
RandomSeekPos ( Random random, long size ) : long

Method Details

Dispose() public method

public Dispose ( ) : void
return void

LineFileDocs() public method

public LineFileDocs ( Random random ) : Lucene.Net.Documents
random System.Random
return Lucene.Net.Documents

LineFileDocs() public method

public LineFileDocs ( Random random, bool useDocValues ) : Lucene.Net.Documents
random System.Random
useDocValues bool
return Lucene.Net.Documents

LineFileDocs() public method

If forever is true, we rewind the file at EOF (repeat the docs over and over)
public LineFileDocs ( Random random, string path, bool useDocValues ) : Lucene.Net.Documents
random System.Random
path string
useDocValues bool
return Lucene.Net.Documents

NextDoc() public method

Note: Document instance is re-used per-thread
public NextDoc ( ) : Document
return Document

Reset() public method

public Reset ( Random random ) : void
random System.Random
return void