start(callback) {
		if (this.options.tcp) {
			// just for internal debugging
			this.server = net.createServer(() => this.socketListen());
		} else {
			this.server = http.createServer((request, response) => this.listen(request, response));

			this.wsServer = new WebSocketServer({
				httpServer: this.server,
				// OK only because this is for testing only
				autoAcceptConnections: false,
			});
		}
		this.server.on('error', error => {
			if (error.code == 'EADDRINUSE') {
				return this.createError('Port ' + this.port + ' in use, please free it and retry again', callback);
			}
			return this.createError('Could not start server on port ' + this.port + ': ' + error, callback);
		});
		this.server.listen(this.port, () => {
			if (!this.options.quiet) console.info(`Listening on http://localhost:${this.port}/`)
			callback(null, this)
		});
		this.wsServer.on('request', request => {
			// explicity omitting origin check here.
			const connection = request.accept(null, request.origin);
			connection.on('message', message => {
				if (message.type === 'utf8') {
					connection.sendUTF(message.utf8Data);
				} else if (message.type === 'binary') {
					connection.sendBytes(message.binaryData);
				}
			});
			connection.on('close', () => {
				if (!this.options.quiet) console.info('Peer %s disconnected', connection.remoteAddress);
			});
		});
		return this
	}
Start the server.
The callback parameter will be called after the server has started.