Class OpenReaderTask
Open an index reader.
Other side effects: index reader object in perfRunData is set. Optional params commitUserData eg. OpenReader(false,commit1)Implements
Inherited Members
Namespace: Lucene.Net.Benchmarks.ByTask.Tasks
Assembly: Lucene.Net.Benchmark.dll
Syntax
public class OpenReaderTask : PerfTask, IDisposable
Constructors
OpenReaderTask(PerfRunData)
Open an index reader.
Other side effects: index reader object in perfRunData is set. Optional params commitUserData eg. OpenReader(false,commit1)Declaration
public OpenReaderTask(PerfRunData runData)
Parameters
Type | Name | Description |
---|---|---|
PerfRunData | runData |
Fields
USER_DATA
Open an index reader.
Other side effects: index reader object in perfRunData is set. Optional params commitUserData eg. OpenReader(false,commit1)Declaration
public static readonly string USER_DATA
Field Value
Type | Description |
---|---|
string |
Properties
SupportsParams
Sub classes that support parameters must override this method to return
true
if this task supports command line params.
Declaration
public override bool SupportsParams { get; }
Property Value
Type | Description |
---|---|
bool |
Overrides
Methods
DoLogic()
Perform the task once (ignoring repetitions specification). Return number of work items done by this task. For indexing that can be number of docs added. For warming that can be number of scanned items, etc.
Declaration
public override int DoLogic()
Returns
Type | Description |
---|---|
int | Number of work items done by this task. |
Overrides
FindIndexCommit(Directory, string)
Open an index reader.
Other side effects: index reader object in perfRunData is set. Optional params commitUserData eg. OpenReader(false,commit1)Declaration
public static IndexCommit FindIndexCommit(Directory dir, string userData)
Parameters
Type | Name | Description |
---|---|---|
Directory | dir | |
string | userData |
Returns
Type | Description |
---|---|
IndexCommit |
SetParams(string)
Set the params of this task.
Declaration
public override void SetParams(string @params)
Parameters
Type | Name | Description |
---|---|---|
string | params |
Overrides
Exceptions
Type | Condition |
---|---|
NotSupportedException | For tasks supporting command line parameters. |