Package-level declarations

Functions

Link copied to clipboard
fun checkedCoroutineHandler(coroutineScope: CoroutineScope, route: Route, launchMode: CoroutineHandlerLaunchMode = DefaultOnVertxEventLoop, requestHandler: suspend (RoutingContext) -> Unit): Route
Link copied to clipboard
fun Route.checkedCoroutineHandler(coroutineScope: CoroutineScope, launchMode: CoroutineHandlerLaunchMode = DefaultOnVertxEventLoop, requestHandler: suspend (RoutingContext) -> Unit): Route
Link copied to clipboard
fun coroutineHandler(coroutineScope: CoroutineScope, route: Route, launchMode: CoroutineHandlerLaunchMode = DefaultOnVertxEventLoop, requestHandler: suspend (RoutingContext) -> Unit): Route
Link copied to clipboard
fun Route.coroutineHandler(coroutineScope: CoroutineScope, launchMode: CoroutineHandlerLaunchMode = DefaultOnVertxEventLoop, requestHandler: suspend (RoutingContext) -> Unit): Route

fun Route.coroutineHandler(coroutineScope: CoroutineScope, context: CoroutineContext, start: CoroutineStart, requestHandler: suspend (RoutingContext) -> Unit): Route

This function can be replaced by coroutineRouter and CoroutineRouterSupport.coHandler which is newly introduced to the official "vertx-lang-kotlin-coroutines" library. However, note that CoroutineRouterSupport.coHandler handles exceptions and is equivalent to Route.checkedCoroutineHandler. See the official docs for more details.

Link copied to clipboard
inline fun CoroutineScope.launchChecked(ctx: RoutingContext, context: CoroutineContext = EmptyCoroutineContext, start: CoroutineStart = CoroutineStart.DEFAULT, crossinline block: suspend CoroutineScope.() -> Unit): Job

Launches a coroutine like launch, and calls RoutingContext.fail on ctx if a Throwable is thrown in block.