@ascentbv/ts-common - v1.0.123
    Preparing search index...

    Class DebugTimerUtilAbstract

    Index

    Constructors

    Accessors

    Methods

    • Starts a named timer and pushes it to the stack for nesting. Use with stop() or end(id) to complete tracking.

      Parameters

      • id: string

        Unique identifier for the timer block.

      Returns void

    • Stops the most recent active timer (LIFO). Automatically accounts for nested exclusive timing.

      Returns void

    • Ends a specific named timer regardless of stack position.

      Parameters

      • id: string

        The identifier of the timer to end.

      Returns void

    • Logs a single-shot timer value and resets it.

      Parameters

      • id: string

        Timer ID to log.

      • description: string

        Description for the log entry.

      • logThreshold: number = 0

        Minimum duration (in microseconds) required to log the result.

      Returns void

    • Prints a report of timers that start with a specific prefix.

      Parameters

      • prefix: string

        The prefix to filter timers by.

      Returns void

    • Prints a grouped report for all matching prefixes.

      Parameters

      • prefixes: string[]

        Array of prefixes to include.

      Returns void

    • Dumps all timers that exceed a certain exclusive duration in milliseconds.

      Parameters

      • ms: number

        Threshold in milliseconds.

      Returns void

    • Prints a timer report sorted by the given metric.

      Parameters

      • mode: "exclusive" | "total" | "avg" = "exclusive"

        One of "exclusive", "total", or "avg" to sort by.

      Returns void