public class WebSocketServer extends Object
A WebSocketServer contains a WebSocketHandler
to handle WebSocket handshakes.
A WebSocketServer must be attached to an HttpServer
; they share the same life cycle.
Constructor and Description |
---|
WebSocketServer(HttpServer httpServer,
WebSocketHandler handler)
Create a WebSocketServer, attach it to the HttpServer.
|
public WebSocketServer(HttpServer httpServer, WebSocketHandler handler)
This constructor must be called before the HttpServer is started.
public WebSocketServerConf conf()
WebSocketServerConf
for this server.
Changes to configuration must be done before the server is started.