JavaWebSocket

class JavaWebSocket(port: Int = 8000, hostName: String = "0.0.0.0", drafts: List<Draft>? = null, val stopMode: ServerConfig.StopMode = ServerConfig.StopMode.Immediate, addShutdownHook: Boolean = true, startupTimeout: Duration = Duration.ofSeconds(5), configFn: WebSocketServer.() -> Unit = { isReuseAddr = true // Set SO_REUSEADDR by default }) : PolyServerConfig

Constructors

Link copied to clipboard
constructor(port: Int = 8000, hostName: String = "0.0.0.0", drafts: List<Draft>? = null, stopMode: ServerConfig.StopMode = ServerConfig.StopMode.Immediate, addShutdownHook: Boolean = true, startupTimeout: Duration = Duration.ofSeconds(5), configFn: WebSocketServer.() -> Unit = { isReuseAddr = true // Set SO_REUSEADDR by default })

Properties

Link copied to clipboard
open override val stopMode: ServerConfig.StopMode

Functions

Link copied to clipboard
open override fun toServer(http: HttpHandler): Http4kServer
open override fun toServer(http: <Error class: unknown class>?, ws: <Error class: unknown class>?, sse: <Error class: unknown class>?): Http4kServer
Link copied to clipboard
open fun toSseServer(sse: SseHandler): Http4kServer
Link copied to clipboard
open fun toWsServer(ws: WsHandler): Http4kServer