libhyperproxy/dist/proxies/basic.js

15 lines
576 B
JavaScript
Raw Normal View History

2023-04-15 22:40:09 +00:00
"use strict";
var __importDefault = (this && this.__importDefault) || function (mod) {
return (mod && mod.__esModule) ? mod : { "default": mod };
};
Object.defineProperty(exports, "__esModule", { value: true });
const proxy_js_1 = __importDefault(require("../proxy.js"));
2023-04-16 02:17:57 +00:00
const peer_js_1 = __importDefault(require("./basic/peer.js"));
2023-04-15 22:40:09 +00:00
class BasicProxy extends proxy_js_1.default {
2023-04-16 02:17:57 +00:00
handlePeer({ peer, muxer, ...options }) {
const conn = new peer_js_1.default({ proxy: this, peer, muxer, ...options });
conn.init();
}
2023-04-15 22:40:09 +00:00
}
exports.default = BasicProxy;