Team XSockets.NET

How to configure the connection

You have a few options when creating the connection, such as sub protocol, query strings and controllers.

How to specify query string parameters

You might wanna pass in query string parameters in the connection. This is done by setting the third parameter to key-value pairs of JSON-object.

var conn = new XSockets.WebSocket('ws://localhost:4502',['chat'],{username:'steve',age:35});

How to specify controllers

Since you can multiplex over several controllers on one connection you can specify the controllers to use when you create the connection. If you would like to connect to three controllers A, B and C you would do:

var conn = new XSockets.WebSocket('ws://localhost:4502',['a','b','c']);

The names of the controllers is not case sensitive so A is the same as a.

results matching ""

    No results matching ""