Ticker

interface Ticker

The timeline ticker is responsible to update the last and the current playhead position of the underlying video player, to its TickerObserver observers.

Types

Link copied to clipboard
Describes the positions where the Ticker can start.

Functions

Link copied to clipboard
abstract fun isRunning(): Boolean
Check if the ticker has started and is currently active
Link copied to clipboard
abstract fun registerObserver(tickerObserver: TickerObserver)
Registers an observer.
Link copied to clipboard
abstract fun reset()
Resets the ticker.
Link copied to clipboard
abstract fun start(position: Ticker.Position)
Starts the ticker with the specified Position type.
open fun start(position: Long)
Starts the ticker with the specified position value.
Link copied to clipboard
abstract fun stop()
Stops the ticker.
Link copied to clipboard
abstract fun tick()
Updates the observers with the playhead position.
Link copied to clipboard
abstract fun unregisterObserver(tickerObserver: TickerObserver)
Unregisters an observer.