InitFun

@Target(allowedTargets = [AnnotationTarget.FUNCTION])
annotation class InitFun(val dispatcher: Dispatcher = Dispatcher.SYNC, val runAfter: Array<KClass<*>> = [], val runBefore: Array<KClass<*>> = [])

Marks a function to be called during initialization. This requires the class to be annotated with Init or InternalInit, and automatically has a dependency on the initialization of the class.

Parameters

dispatcher

Defines how the initialization is dispatched. Falls back to the dispatcher of the class if not specified.

runAfter

The classes (and their init functions) which should be initialized after this function is called. (This function is called before them.) Those classes must be annotated with Init or InternalInit.

Properties

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard