Module vibe.http.websockets

Implements WebSocket support and fallbacks for older browsers.

Examples

void handleConn(WebSocket sock)
{
	// simple echo server
	while( sock.connected ){
		auto msg = sock.receive();
		sock.send(msg);
	}
}

static this {
	auto router = new UrlRouter;
	router.get("/websocket", handleWebSockets(&handleConn))

	// Start HTTP server...
}

Functions

Name Description
handleWebSockets

Classes

Name Description
IncommingWebSocketMessage
OutgoingWebSocketMessage
WebSocket

Structs

Name Description
Frame

Enums

Name Description
FrameOpcode

Authors

Jan Krüger

Copyright

© 2012 RejectedSoftware e.K.

License

Subject to the terms of the MIT license, as written in the included LICENSE.txt file.