port_http_server / com.hexagonkt.http.server
This package defines the classes used in the HTTP DSL.
||HTTP request context. It holds client supplied data and methods to change the response.
data class CorsSettings
||Alias for errors' callbacks. Functions executed to handle a HTTP error code.
typealias ErrorCodeCallback =
||Alias for exceptions' callbacks. Functions executed when an exception is thrown.
typealias ExceptionCallback =
||Type of filter. Indicates when the filter is executed.
enum class FilterOrder
data class Part
abstract class PortHttpServerSamplesTest
||Lists would be initialized loading all elements when they are used (set it as lazy in implementations) this will have a performance penalty in favor of ease of use. The alternative would be using a 'Map/List wrapper that delegates calls to abstract methods in the interface (I won't do this just now).
abstract class Request
sealed class RequestHandler
||Check 'Request' comment. And also note that lists should be updated by engines after callback is processed, this data is like a buffer that needs to be dumped to the real response.
abstract class Response
||Alias for routes' and filters' callbacks. Functions executed when a route is matched.
typealias RouteCallback =
||Creates and initializes a Router based on a code block.
||A server that listen to HTTP connections on a port and address and route requests using a router.
data class Server
||Represents a server instance of one kind.
data class ServerSettings
||Provides session information.
abstract class Session