Class WaitTask
Simply waits for the specified (via the parameter) amount of time. For example Wait(30s) waits for 30 seconds. This is useful with background tasks to control how long the tasks run.
You can specify h, m, or s (hours, minutes, seconds) as the trailing time unit. No unit is interpreted as seconds.Implements
Inherited Members
Namespace: Lucene.Net.Benchmarks.ByTask.Tasks
Assembly: Lucene.Net.Benchmark.dll
Syntax
public class WaitTask : PerfTask, IDisposable
Constructors
WaitTask(PerfRunData)
Simply waits for the specified (via the parameter) amount of time. For example Wait(30s) waits for 30 seconds. This is useful with background tasks to control how long the tasks run.
You can specify h, m, or s (hours, minutes, seconds) as the trailing time unit. No unit is interpreted as seconds.Declaration
public WaitTask(PerfRunData runData)
Parameters
| Type | Name | Description |
|---|---|---|
| PerfRunData | runData |
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
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. |