PauseManager

A singleton object to manage pause states for different operations identified by a key.

The PauseManager allows you to pause and resume operations using a unique key. It can be useful for cases where certain tasks or event listeners should be temporarily paused, for example, during maintenance or other critical periods.

Functions

Link copied to clipboard

Checks if the operation associated with the given key is paused.

Link copied to clipboard
fun pause(key: String): Boolean

Pauses the operation associated with the given key.

Link copied to clipboard
fun resume(key: String): Boolean

Resumes the operation associated with the given key.