registerCallback
suspend fun <T : Any> registerCallback(context: Any, eventType: EventType<T>, callback: EventCallback<T>)
Registers callbacks with the specified type.
Parameters
T
type of data passed to callback
context
an object that identifies callbacks in the list
eventType
type of event to listen to
callback
a block of code to execute when event was handled
Throws
thrown when method encounters an exception during subscribing on channel