Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • Timer

Index

Constructors

Properties

_pulse: null | Date = null

The time the timer was last started or updated.

_time: number = 0

The amount of time the timer has been running. This is only accurate after update.

running: boolean = false

Whether the timer is currently running or not.

Accessors

  • get time(): number
  • Get the amount of time the timer has been running.

    Returns number

Methods

  • clear(): void
  • Stop the timer and clear the time that has been recorded.

    Returns void

  • restart(): void
  • Restart the timer at 0.

    Returns void

  • start(): void
  • stop(): void
  • Stop the timer (and update the time it had been running).

    Returns void

  • update(): void
  • Update the time the timer has been running.

    Returns void

Generated using TypeDoc