|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.lucene.benchmark.byTask.feeds.BasicDocMaker
org.apache.lucene.benchmark.byTask.feeds.LineDocMaker
public class LineDocMaker
A DocMaker reading one line at a time as a Document from a single file. This saves IO cost (over DirDocMaker) of recursing through a directory and opening a new file for every document. It also re-uses its Document and Field instance to improve indexing speed. Config properties: docs.file=<path to the file%gt;
| Field Summary |
|---|
| Fields inherited from class org.apache.lucene.benchmark.byTask.feeds.BasicDocMaker |
|---|
BODY_FIELD, BYTES_FIELD, config, DATE_FIELD, forever, ID_FIELD, indexVal, NAME_FIELD, storeVal, termVecVal, TITLE_FIELD |
| Constructor Summary | |
|---|---|
LineDocMaker()
|
|
| Method Summary | |
|---|---|
protected DocData |
getNextDocData()
Return the data of the next document. |
Document |
makeDocument()
Create the next document. |
Document |
makeDocument(int size)
Create the next document, of the given size by input bytes. |
int |
numUniqueTexts()
Return how many real unique texts are available, 0 if not applicable. |
void |
resetInputs()
Reset inputs so that the test run would behave, input wise, as if it just started. |
| Methods inherited from class org.apache.lucene.benchmark.byTask.feeds.BasicDocMaker |
|---|
addBytes, addUniqueBytes, collectFiles, getByteCount, getCount, getHtmlParser, numUniqueBytes, printDocStatistics, setConfig, setHTMLParser |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public LineDocMaker()
| Method Detail |
|---|
protected DocData getNextDocData()
throws Exception
BasicDocMaker
getNextDocData in class BasicDocMakerNoMoreDataException - if data is exhausted (and 'forever' set to false).
Exception
public Document makeDocument()
throws Exception
DocMaker
makeDocument in interface DocMakermakeDocument in class BasicDocMakerException
public Document makeDocument(int size)
throws Exception
DocMaker
makeDocument in interface DocMakermakeDocument in class BasicDocMakersize - size of document, or 0 if there is no size requirement.
Exceptionpublic void resetInputs()
DocMaker
resetInputs in interface DocMakerresetInputs in class BasicDocMakerpublic int numUniqueTexts()
DocMaker
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||