Interface Statistics<Name>

Statistics for solver operations

Provides access to performance metrics, memory usage, decision counts, and other diagnostic information from solver operations.

interface Statistics<Name extends string = "main"> {
    ctx: Context<Name>;
    ptr: Z3_stats;
    "[iterator]"(): Iterator<StatisticsEntry<Name>, any, any>;
    entries(): StatisticsEntry<Name>[];
    get(key: string): number;
    keys(): string[];
    release(): void;
    size(): number;
}

Type Parameters

  • Name extends string = "main"

Hierarchy

Properties

ptr: Z3_stats

Methods

  • Returns Iterator<StatisticsEntry<Name>, any, any>

  • Return a specific statistic value by key

    Parameters

    • key: string

      The key of the statistic to retrieve

    Returns number

    The numeric value of the statistic

    Error if the key doesn't exist

  • Manually decrease the reference count of the statistics object This is automatically done when the statistics is garbage collected, but calling this eagerly can help release memory sooner.

    Returns void

  • Return the number of statistical data points

    Returns number

    The number of statistics entries