Internationalisation
Bundled Plugins API
TimeoutScheduler
A scheduler that uses the hs.timer library to schedule events on an event loop.

API Overview

  • Methods - API calls which can only be made on an object returned by a constructor
  • create
  • schedule
  • stopAll

API Documentation

Methods

create

Signature
cp.rx.TimeoutScheduler.create() -> cp.rx.TimeoutScheduler
Type
Method
Description
Creates a new TimeoutScheduler.
Returns
  • The new TimeoutScheduler.

schedule

Signature
cp.rx.TimeoutScheduler:schedule(action[, delay]) -> cp.rx.TimeoutScheduler
Type
Method
Description
Schedules an action to run at a future point in time.
Parameters
  • action - The action to run.
  • delay - The delay, in milliseconds. Defaults to 0.
Returns

stopAll

Signature
cp.rx.TimeoutScheduler:stopAll() -> nil
Type
Method
Description
Stops all future timers from running and clears them.
Last modified 1mo ago
Export as PDF
Copy link