StopWatch Class
A StopWatch for timing operations.
Methods
Name | Description | |
---|---|---|
constructor(description?: string, startImmediately: booleanfalse): StopWatch | ctor for StopWatch | |
reset(): void | Clear the StopWatch | |
start(): void | Start the stopwatch. | |
stop(): BeDuration | Stop the stopwatch so that the duration can be viewed later. |
Properties
Name | Type | Description | |
---|---|---|---|
current Accessor ReadOnly | BeDuration | Get the elapsed time since start() on a running timer. | |
currentSeconds Accessor ReadOnly | number | Get the elapsed time, in seconds, since start() on a running timer. | |
description | string | undefined | optional string stored with the StopWatch | |
elapsed Accessor ReadOnly | BeDuration | Get the elapsed time between start() and stop() on this timer in milliseconds. | |
elapsedSeconds Accessor ReadOnly | number | Get the elapsed time, in seconds, between start() and stop() on this timer. |
Defined in
- core/bentley/src/Time.ts Line 136
Last Updated: 17 December, 2024
Found something wrong, missing, or unclear on this page?Raise an issue in our repo.