Socket
Socket
Sign inDemoInstall

@skyway-sdk/room

Package Overview
Dependencies
4
Maintainers
3
Versions
120
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 0.3.0-beta.1 to 0.3.0-beta.2

dist/skyway_room-0.3.0-beta.2.js

2

dist/index.d.ts

@@ -15,4 +15,4 @@ export * from './member';

export * from '@skyway-sdk/common';
export { ChannelStatus, Codec, Event, Events, LocalAudioStream, LocalDataStream, LocalStream, LocalVideoStream, Logger, MediaDeviceManager, MemberSide, MemberStatus, MemberType, PublicationOptions, PublicationStatus, RemoteAudioStream, RemoteDataStream, RemoteStream, RemoteVideoStream, RtcApiConfig, RtcRpcApiConfig, SkyWayConfigOptions, SkyWayContext, SkyWayMediaDevices, SubscriptionStatus, TurnPolicy, } from '@skyway-sdk/core';
export { ChannelStatus, Codec, ContentType, EncodingParameters, Event, Events, LocalAudioStream, LocalDataStream, LocalStream, LocalVideoStream, Logger, MediaDeviceManager, MemberSide, MemberStatus, MemberType, PublicationOptions, PublicationStatus, RemoteAudioStream, RemoteDataStream, RemoteStream, RemoteVideoStream, RtcApiConfig, RtcRpcApiConfig, SkyWayConfigOptions, SkyWayContext, SkyWayMediaDevices, SubscriptionStatus, TurnPolicy, } from '@skyway-sdk/core';
export * from '@skyway-sdk/token';
//# sourceMappingURL=index.d.ts.map

@@ -7,17 +7,19 @@ import { SkyWayContext } from '@skyway-sdk/core';

export declare class SkyWayRoom {
/**@private */
constructor();
/**
* @description {japanese} Roomの作成
*/
static Create<Init extends RoomInit>(context: SkyWayContext, init: Init): Promise<Init["type"] extends "sfu" ? SfuRoom : P2PRoom>;
static Create: <Init extends RoomInit>(context: SkyWayContext, init: Init) => Promise<Init["type"] extends "sfu" ? SfuRoom : P2PRoom>;
/**
* @description {japanese} 既存のRoomの取得
*/
static Find<Type extends RoomType>(context: SkyWayContext, query: {
static Find: <Type extends "sfu" | "p2p">(context: SkyWayContext, query: {
id?: string;
name?: string;
}, roomType: Type, options?: Type extends 'sfu' ? SfuRoomOptions : void): Promise<Type extends "sfu" ? SfuRoom : P2PRoom>;
}, roomType: Type, options?: (Type extends "sfu" ? SfuRoomOptions : void) | undefined) => Promise<Type extends "sfu" ? SfuRoom : P2PRoom>;
/**
* @description {japanese} Roomの取得を試み、存在しなければ作成する
*/
static FindOrCreate<Init extends RoomInit>(context: SkyWayContext, init: Init): Promise<Init["type"] extends "p2p" ? P2PRoom : SfuRoom>;
static FindOrCreate: <Init extends RoomInit>(context: SkyWayContext, init: Init) => Promise<Init["type"] extends "p2p" ? P2PRoom : SfuRoom>;
private static _Factory;

@@ -24,0 +26,0 @@ }

@@ -11,2 +11,3 @@ "use strict";

};
var _a;
Object.defineProperty(exports, "__esModule", { value: true });

@@ -20,44 +21,4 @@ exports.roomTypes = exports.SkyWayRoom = void 0;

class SkyWayRoom {
/**
* @description {japanese} Roomの作成
*/
static Create(context, init) {
var _a, _b, _c;
return __awaiter(this, void 0, void 0, function* () {
const plugin = new sfu_client_1.SfuClientPlugin((_b = (_a = init) === null || _a === void 0 ? void 0 : _a.options) === null || _b === void 0 ? void 0 : _b.sfu);
context.registerPlugin(plugin);
const channel = yield core_1.SkyWayChannel.Create(context, {
name: (_c = init.name) !== null && _c !== void 0 ? _c : (0, uuid_1.v4)(),
metadata: init.metadata,
});
const room = yield this._Factory(context, init.type, channel);
return room;
});
}
/**
* @description {japanese} 既存のRoomの取得
*/
static Find(context, query, roomType, options) {
var _a;
return __awaiter(this, void 0, void 0, function* () {
const plugin = new sfu_client_1.SfuClientPlugin((_a = options) === null || _a === void 0 ? void 0 : _a.sfu);
context.registerPlugin(plugin);
const channel = yield core_1.SkyWayChannel.Find(context, query);
const room = yield this._Factory(context, roomType, channel);
return room;
});
}
/**
* @description {japanese} Roomの取得を試み、存在しなければ作成する
*/
static FindOrCreate(context, init) {
var _a, _b;
return __awaiter(this, void 0, void 0, function* () {
const plugin = new sfu_client_1.SfuClientPlugin((_b = (_a = init) === null || _a === void 0 ? void 0 : _a.options) === null || _b === void 0 ? void 0 : _b.sfu);
context.registerPlugin(plugin);
const channel = yield core_1.SkyWayChannel.FindOrCreate(context, Object.assign({}, init));
const room = yield this._Factory(context, init.type, channel);
return room;
});
}
/**@private */
constructor() { }
static _Factory(context, roomType, channel) {

@@ -80,3 +41,40 @@ return __awaiter(this, void 0, void 0, function* () {

exports.SkyWayRoom = SkyWayRoom;
_a = SkyWayRoom;
/**
* @description {japanese} Roomの作成
*/
SkyWayRoom.Create = (context, init) => __awaiter(void 0, void 0, void 0, function* () {
var _b, _c, _d;
const plugin = new sfu_client_1.SfuClientPlugin((_c = (_b = init) === null || _b === void 0 ? void 0 : _b.options) === null || _c === void 0 ? void 0 : _c.sfu);
context.registerPlugin(plugin);
const channel = yield core_1.SkyWayChannel.Create(context, {
name: (_d = init.name) !== null && _d !== void 0 ? _d : (0, uuid_1.v4)(),
metadata: init.metadata,
});
const room = yield _a._Factory(context, init.type, channel);
return room;
});
/**
* @description {japanese} 既存のRoomの取得
*/
SkyWayRoom.Find = (context, query, roomType, options) => __awaiter(void 0, void 0, void 0, function* () {
var _e;
const plugin = new sfu_client_1.SfuClientPlugin((_e = options) === null || _e === void 0 ? void 0 : _e.sfu);
context.registerPlugin(plugin);
const channel = yield core_1.SkyWayChannel.Find(context, query);
const room = yield _a._Factory(context, roomType, channel);
return room;
});
/**
* @description {japanese} Roomの取得を試み、存在しなければ作成する
*/
SkyWayRoom.FindOrCreate = (context, init) => __awaiter(void 0, void 0, void 0, function* () {
var _f, _g;
const plugin = new sfu_client_1.SfuClientPlugin((_g = (_f = init) === null || _f === void 0 ? void 0 : _f.options) === null || _g === void 0 ? void 0 : _g.sfu);
context.registerPlugin(plugin);
const channel = yield core_1.SkyWayChannel.FindOrCreate(context, Object.assign({}, init));
const room = yield _a._Factory(context, init.type, channel);
return room;
});
exports.roomTypes = ['sfu', 'p2p'];
//# sourceMappingURL=index.js.map

@@ -1,2 +0,2 @@

export declare const PACKAGE_VERSION = "0.3.0-beta.1";
export declare const PACKAGE_VERSION = "0.3.0-beta.2";
//# sourceMappingURL=version.d.ts.map
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.PACKAGE_VERSION = void 0;
exports.PACKAGE_VERSION = '0.3.0-beta.1';
exports.PACKAGE_VERSION = '0.3.0-beta.2';
//# sourceMappingURL=version.js.map
{
"name": "@skyway-sdk/room",
"version": "0.3.0-beta.1",
"version": "0.3.0-beta.2",
"description": "The official Next Generation JavaScript SDK for SkyWay",

@@ -16,6 +16,7 @@ "homepage": "https://beta.skyway.ntt.com/",

"scripts": {
"bootstrap": "lerna bootstrap",
"build": "zx bundle.mjs",
"compile": "npm run compile:tsc && npm run compile:esbuild",
"compile:esbuild": "esbuild src/index.ts --bundle --format=esm --target=es6 --outfile=dist/index.mjs",
"compile:tsc": "rm -rf dist && tsc -p tsconfig.build.json",
"compile:esbuild": "esbuild src/index.ts --bundle --format=esm --target=es6 --outfile=dist/index.mjs",
"doc": "rm -rf docs/api/md && typedoc --excludePrivate --disableSources --excludeInternal --tsconfig ./tsconfig.build.json --out docs/api/md ./src/index.ts ",

@@ -27,4 +28,4 @@ "e2e": "karma start ./karma.e2e.js --single-run --browsers chrome_headless_with_fake_device",

"graph": "dependency-cruiser --include-only '^src' --output-type dot src | dot -T svg > docs/dependencygraph.svg",
"publish:alpha": "npm run build && npx can-npm-publish --verbose && npm publish --access public --tag alpha",
"publish:npm": "npx can-npm-publish --verbose && npm run build && npm publish --access public",
"publish:alpha": "npm run build && npx can-npm-publish --verbose && npm publish --access public --tag alpha",
"test": "karma start --single-run --browsers chrome_headless_with_fake_device",

@@ -39,3 +40,3 @@ "test:dev": "karma start --browsers chrome_with_fake_device",

"dependencies": {
"@skyway-sdk/common": "^0.2.0-beta.9",
"@skyway-sdk/common": "^0.2.0-beta.10",
"@skyway-sdk/core": "^0.2.0-beta.24",

@@ -42,0 +43,0 @@ "@skyway-sdk/sfu-client": "^0.3.0-beta.0",

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc