UNPKG

@syntest/core

Version:

The common core of the SynTest Framework

56 lines 1.85 kB
import { RuntimeVariable } from "./RuntimeVariable"; import { TotalTimeBudget } from "../search/budget/TotalTimeBudget"; import { Encoding } from "../search/Encoding"; /** * Collector for runtime statistics. * * @author Mitchell Olsthoorn */ export declare class StatisticsCollector<T extends Encoding> { /** * Mapping from runtime variable to value. * @protected */ protected _variables: Map<RuntimeVariable, string>; /** * Mapping from total search time to another mapping from runtime variable to value. * @protected */ protected _eventVariables: Map<number, Map<RuntimeVariable, string>>; /** * Total search time budget from the search process. * @protected */ protected _timeBudget: TotalTimeBudget<T>; /** * Constructor. * * @param timeBudget The time budget to use for tracking time */ constructor(timeBudget: TotalTimeBudget<T>); /** * Record a static variable in the collector. * * @param variable The variable type to record * @param value The variable value */ recordVariable(variable: RuntimeVariable, value: string): StatisticsCollector<T>; /** * Record a dynamic variable in the collector. * * The event is recorded at the current time of the search process. * * @param variable The variable type to record * @param value The variable value */ recordEventVariable(variable: RuntimeVariable, value: string | number): StatisticsCollector<T>; /** * Return the static variables stored in the collector */ getVariables(): Map<RuntimeVariable, string>; /** * Return the dynamic variables stored in the collector */ getEventVariables(): Map<number, Map<RuntimeVariable, string>>; } //# sourceMappingURL=StatisticsCollector.d.ts.map