Table of Contents

Class StoppingCriteriaBase

Namespace
BenchmarkDotNet.Engines
Assembly
BenchmarkDotNet.dll
public abstract class StoppingCriteriaBase : IStoppingCriteria
Inheritance
StoppingCriteriaBase
Implements
Derived

Constructors

StoppingCriteriaBase()

protected StoppingCriteriaBase()

Properties

MaxIterationCount

The maximum possible count of iterations. Engine needs this value for setting the maximum capacity of the returned list of measurements. The correct capacity helps to avoid infrastructure allocations during benchmarking.

public int MaxIterationCount { get; }

Property Value

int

Title

Title which can be used in logs and diagnostics methods

public string Title { get; }

Property Value

string

Warnings

An array of user-friendly warnings which notify about incorrect parameters.

public IReadOnlyList<string> Warnings { get; }

Property Value

IReadOnlyList<string>

Methods

Evaluate(IReadOnlyList<Measurement>)

Checks do we have enough iterations

public abstract StoppingResult Evaluate(IReadOnlyList<Measurement> measurements)

Parameters

measurements IReadOnlyList<Measurement>

Returns

StoppingResult

GetMaxIterationCount()

protected abstract int GetMaxIterationCount()

Returns

int

GetTitle()

protected abstract string GetTitle()

Returns

string

GetWarnings()

protected abstract IEnumerable<string> GetWarnings()

Returns

IEnumerable<string>