Package io.kvision.remote

A set of components for creating multiplatform automatic JSON-RPC connectivity with a backend server.

Types

KVServiceManager
Link copied to clipboard
common
open class KVServiceManager<T : Any>(serviceClass: KClass<T>) : KVServiceMgr<T>
Multiplatform service manager.
js
open class KVServiceManager<T : Any>(serviceClass: KClass<T>) : KVServiceManagerJs<T> , KVServiceMgr<T>
Multiplatform service manager.
open class KVServiceManager<T : Any>(serviceClass: KClass<T>) : KVServiceBinder<T, RequestHandler, WebsocketHandler> , KVServiceMgr<T>
Multiplatform service manager for Vert.x.
RequestHandler
Link copied to clipboard
typealias RequestHandler = (RoutingContext) -> Unit
WebsocketHandler
Link copied to clipboard
typealias WebsocketHandler = (Injector, ServerWebSocket) -> Unit

Functions

applyRoutes
Link copied to clipboard
fun <T : Any> Vertx.applyRoutes(router: Router, serviceManager: KVServiceManager<T>)
A function to generate routes based on definitions from the service manager.
kvisionInit
Link copied to clipboard
fun Vertx.kvisionInit(router: Router, vararg modules: Module)
Initialization function for Vert.x server.
fun Vertx.kvisionInit(router: Router, server: HttpServer, wsServiceManagers: List<KVServiceManager<*>> = emptyList(), vararg modules: Module)
Initialization function for Vert.x server with support for WebSockets.
serviceRoute
Link copied to clipboard
fun Router.serviceRoute(service: KVServiceManager<*>, handler: Handler<RoutingContext>)

Properties

KV_INJECTOR_KEY
Link copied to clipboard
const val KV_INJECTOR_KEY: String