JabbitScope

Receiver of the jabbit { } builder.

Functions

Link copied to clipboard
fun android(configure: AndroidScope.() -> Unit)

Settings that only apply when running on Android.

Link copied to clipboard
fun browser(configure: BrowserScope.() -> Unit)

Settings that only apply when running in a browser.

Link copied to clipboard
fun desktop(configure: DesktopScope.() -> Unit)

Settings that only apply when running on the desktop.

Link copied to clipboard

Sets how long finished jobs stay observable. Ignored on Android, where the retention of WorkManager applies.

Link copied to clipboard
fun ios(configure: IosScope.() -> Unit)

Settings that only apply when running on iOS.

Link copied to clipboard
fun listener(listener: JabbitListener)

Adds a listener watching what happens to jobs. Several may be installed.

Link copied to clipboard
fun logger(logger: JabbitLogger)

Routes diagnostic output into logger.

Link copied to clipboard

Limits how many jobs may run at the same time. Ignored on Android, where WorkManager decides.

Link copied to clipboard
fun <I, O> worker(type: JobType<I, O>, factory: () -> JabbitWorker<I, O>)

Registers the worker that runs jobs of type.