Timer

abstract class Timer

Timer that can be stopped and started.

Constructors

Link copied to clipboard
constructor(milliseconds: Long)
Creates a new timer.

Properties

Link copied to clipboard
open val isStarted: Boolean

Functions

Link copied to clipboard
open fun getProgress(): Int
Gets the progress in percentage.
Link copied to clipboard
open fun getRunTime(): Long
Gets the total run time in milliseconds.
Link copied to clipboard
open fun start()
Starts the timer.
Link copied to clipboard
open fun stop()
Stops the timer.