| java.lang.Object org.apache.lucene.benchmark.byTask.tasks.PerfTask org.apache.lucene.benchmark.byTask.tasks.ReadTask
All known Subclasses: org.apache.lucene.benchmark.byTask.tasks.WarmTask, org.apache.lucene.benchmark.byTask.tasks.SearchTravTask, org.apache.lucene.benchmark.byTask.tasks.SearchTask,
ReadTask | abstract public class ReadTask extends PerfTask (Code) | | Read index (abstract) task.
Sub classes implement withSearch(), withWarm(), withTraverse() and withRetrieve()
methods to configure the actual action.
Note: All ReadTasks reuse the reader if it is already open.
Otherwise a reader is opened at start and closed at the end.
Other side effects: none.
|
Method Summary | |
public int | doLogic() | abstract public QueryMaker | getQueryMaker() Return query maker used for this task. | protected int | retrieveDoc(IndexReader ir, int id) | public int | traversalSize() Specify the number of hits to traverse. | abstract public boolean | withRetrieve() Return true if, with search & results traversing, docs should be retrieved. | abstract public boolean | withSearch() Return true if search should be performed. | abstract public boolean | withTraverse() Return true if, with search, results should be traversed. | abstract public boolean | withWarm() Return true if warming should be performed. |
getQueryMaker | abstract public QueryMaker getQueryMaker()(Code) | | Return query maker used for this task.
|
traversalSize | public int traversalSize()(Code) | | Specify the number of hits to traverse. Tasks should override this if they want to restrict the number
of hits that are traversed when
ReadTask.withTraverse() is true. Must be greater than 0.
Read task calculates the traversal as: Math.min(hits.length(), traversalSize())
Integer.MAX_VALUE |
withRetrieve | abstract public boolean withRetrieve()(Code) | | Return true if, with search & results traversing, docs should be retrieved.
|
withSearch | abstract public boolean withSearch()(Code) | | Return true if search should be performed.
|
withTraverse | abstract public boolean withTraverse()(Code) | | Return true if, with search, results should be traversed.
|
withWarm | abstract public boolean withWarm()(Code) | | Return true if warming should be performed.
|
|
|