ServiceRouteHandler

The handler of one service route: the binding the compiler generates for a @ServiceRoute function, named as the Manifest names the route (context, name). The edge mounts it at the route the Manifest lists, admits the call, and asks it to handle the request.

Properties

Link copied to clipboard
abstract val context: String

The bounded context of the route.

Link copied to clipboard
abstract val name: String

The route's name within context.

Functions

Link copied to clipboard
abstract suspend fun handle(call: RouteCall, request: RouteRequest): Any?

Calls the route's function with the parameters request reads, as call; its answer, Unit for none. A parameter that does not read as its type fails with MalformedRouteRequestException.