Package-level declarations
Types
Link copied to clipboard
data class AfterHandler(val handlerPredicate: HttpPredicate = HttpPredicate(), val block: HttpCallbackType) : HttpHandler, Handler<HttpCall>
Link copied to clipboard
data class BeforeHandler(val handlerPredicate: HttpPredicate = HttpPredicate(), val block: HttpCallbackType) : HttpHandler, Handler<HttpCall>
Link copied to clipboard
data class ExceptionHandler<E : Exception>(val exception: KClass<E>, val clear: Boolean = true, val block: HttpExceptionCallbackType<E>) : HttpHandler, Handler<HttpCall>
Link copied to clipboard
data class FilterHandler(val handlerPredicate: HttpPredicate = HttpPredicate(), val block: HttpCallbackType) : HttpHandler, Handler<HttpCall>
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
data class HttpContext(val event: HttpCall, val predicate: (Context<HttpCall>) -> Boolean, val nextHandlers: List<Handler<HttpCall>> = emptyList(), val nextHandler: Int = 0, val exception: Exception? = null, val attributes: Map<*, *> = emptyMap<Any, Any>(), val handled: Boolean = false) : Context<HttpCall>
Link copied to clipboard
Utility to encapsulate a handler in a class. TODO
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
data class HttpPredicate(val methods: Set<HttpMethod> = emptySet(), val pathPattern: PathPattern = LiteralPathPattern(), val exception: KClass<out Exception>? = null, val status: HttpStatus? = null) : Function1<Context<HttpCall>, Boolean>
Link copied to clipboard
data class OnHandler(val handlerPredicate: HttpPredicate = HttpPredicate(), val block: HttpCallbackType) : HttpHandler, Handler<HttpCall>
Link copied to clipboard
data class PathHandler(val handlerPredicate: HttpPredicate, val handlers: List<HttpHandler>) : HttpHandler, Handler<HttpCall>
Functions
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
fun HttpCallbackType.process(request: HttpRequest, attributes: Map<*, *> = emptyMap<Any, Any>()): HttpContext
fun HttpCallbackType.process(method: HttpMethod = GET, protocol: HttpProtocol = HTTP, host: String = "localhost", port: Int = 80, path: String = "", queryParameters: QueryParameters = QueryParameters(), headers: Headers = Headers(), body: Any = "", parts: List<HttpPart> = emptyList(), formParameters: FormParameters = FormParameters(), cookies: List<Cookie> = emptyList(), contentType: ContentType? = null, certificateChain: List<X509Certificate> = emptyList(), accept: List<ContentType> = emptyList(), contentLength: Long = -1L, attributes: Map<*, *> = emptyMap<Any, Any>()): HttpContext
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard