RouteSelector

abstract class RouteSelector

Base type for all routing selectors

Parameters

quality - indicates how good this selector is compared to siblings

Constructors

<init>

RouteSelector(quality: Double)

Base type for all routing selectors

Properties

quality

val quality: Double

indicates how good this selector is compared to siblings

Functions

evaluate

abstract fun evaluate(
    context: RoutingResolveContext,
    segmentIndex: Int
): RouteSelectorEvaluation

Evaluates this selector against context and a path segment at segmentIndex

Inheritors

AndRouteSelector

data class AndRouteSelector : RouteSelector

Evaluates a route as a result of the AND operation using two other selectors

AuthenticationRouteSelector

class AuthenticationRouteSelector : RouteSelector

An authentication route node that is used by Authentication feature and usually created by Route.authenticate DSL function so generally there is no need to instantiate it directly unless you are writing an extension

ConstantParameterRouteSelector

data class ConstantParameterRouteSelector : RouteSelector

Evaluates a route against a constant query parameter value

HostRouteSelector

data class HostRouteSelector : RouteSelector

Evaluates a route against a request’s host and port

HttpAcceptRouteSelector

data class HttpAcceptRouteSelector : RouteSelector

Evaluates a route against a content-type in the HttpHeaders.Accept header in the request

HttpHeaderRouteSelector

data class HttpHeaderRouteSelector : RouteSelector

Evaluates a route against a header in the request

HttpMethodRouteSelector

data class HttpMethodRouteSelector : RouteSelector

Evaluates a route against an HttpMethod

OptionalParameterRouteSelector

data class OptionalParameterRouteSelector : RouteSelector

Evaluates a route against an optional query parameter value and captures its value, if found

OrRouteSelector

data class OrRouteSelector : RouteSelector

Evaluates a route as a result of the OR operation using two other selectors

ParameterRouteSelector

data class ParameterRouteSelector : RouteSelector

Evaluates a route against a query parameter value and captures its value

PathSegmentConstantRouteSelector

data class PathSegmentConstantRouteSelector : RouteSelector

Evaluates a route against a constant path segment

PathSegmentOptionalParameterRouteSelector

data class PathSegmentOptionalParameterRouteSelector : 
    RouteSelector

Evaluates a route against an optional parameter path segment and captures its value, if any

PathSegmentParameterRouteSelector

data class PathSegmentParameterRouteSelector : RouteSelector

Evaluates a route against a parameter path segment and captures its value

PathSegmentTailcardRouteSelector

data class PathSegmentTailcardRouteSelector : RouteSelector

Evaluates a route against any number of trailing path segments, and captures their values

PathSegmentWildcardRouteSelector

object PathSegmentWildcardRouteSelector : RouteSelector

Evaluates a route against any single path segment

RootRouteSelector

class RootRouteSelector : RouteSelector

The selector for routing root.