All Downloads are FREE. Search and download functionalities are using the official Maven repository.

utiel.flip-web.19.1-RELEASE.source-code._.js Maven / Gradle / Ivy

function _(path, cbs, key) {
	var ws;
	function con() {
		ws = new WebSocket("ws://" + document.location.host + path, key || ".");
		ws.onmessage = function(e) {
			try {
				var cb = JSON.parse(e.data);
				console.log("DBG: " + JSON.stringify(cb));
				cbs[cb.name].apply(null, cb.args);
			} catch (e) {
				console.log("ERR: " + e);
			}
		};
		ws.onerror = ws.onclose = function() {
			console.log("Connectioned Closed");
			setTimeout(con, 3000);
		};
	}
	con();
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy