org.apache.lucene.benchmark.byTask.tasks
public abstract class PerfTask extends Object implements Cloneable
task.max.depth.log
.
Field Summary | |
---|---|
protected static String | NEW_LINE |
protected String | params |
Constructor Summary | |
---|---|
PerfTask(PerfRunData runData) |
Method Summary | |
---|---|
protected Object | clone() |
abstract int | doLogic()
Perform the task once (ignoring repetions specification)
Return number of work items done by this task.
|
int | getDepth() |
String | getName() |
String | getParams() |
PerfRunData | getRunData() |
int | runAndMaybeStats(boolean reportStats)
Run the task, record statistics. |
void | setDepth(int depth) |
protected void | setName(String name) |
void | setParams(String params)
Set the params of this task. |
void | setup()
Task setup work that should not be measured for that specific task.
|
protected boolean | shouldNeverLogAtStart()
Tasks that should never log at start can overide this. |
protected boolean | shouldNotRecordStats()
Tasks that should not record statistics can overide this. |
boolean | supportsParams()
Sub classes that supports parameters must overide this method to return true. |
void | tearDown()
Task tearDown work that should not be measured for that specific task.
|
String | toString() |
Returns: number of work items done by this task.
Returns: Returns the depth.
Returns: Returns the name.
Returns: Returns the Params.
Returns: Returns the run data.
Returns: number of work items done by this task.
Parameters: depth The depth to set.
Parameters: name The name to set.
Throws: UnsupportedOperationException for tasks supporting command line parameters.
Throws: Exception
Returns: true if this task should never log when it start.
Returns: true if this task should never record its statistics.
Returns: true iff this task supports command line params.