@rongcloud/engine 5.32.0-c-rtc-alpha.1 → 5.32.0-c-rtc-alpha.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.cjs +1 -10
- package/index.cjs.js +1 -10
- package/index.d.ts +25 -34
- package/index.esm.js +1 -10
- package/index.mjs +1 -10
- package/package.json +1 -1
package/index.d.ts
CHANGED
|
@@ -4712,13 +4712,24 @@ declare const isValidGroupId: (value: any) => boolean;
|
|
|
4712
4712
|
declare const isValidFileType: (fileType: number) => boolean;
|
|
4713
4713
|
|
|
4714
4714
|
declare class Codec$1<T> {
|
|
4715
|
-
private
|
|
4715
|
+
#private;
|
|
4716
|
+
private readonly pbModules;
|
|
4717
|
+
constructor(
|
|
4718
|
+
/**
|
|
4719
|
+
* proto 协议描述
|
|
4720
|
+
*/
|
|
4721
|
+
desc: string);
|
|
4716
4722
|
/**
|
|
4717
|
-
*
|
|
4718
|
-
* @param
|
|
4723
|
+
* PB 数据序列化
|
|
4724
|
+
* @param pbname - PB 名称
|
|
4725
|
+
* @param params - 待序列化数据
|
|
4719
4726
|
*/
|
|
4720
|
-
constructor(desc: string);
|
|
4721
4727
|
encode<K extends keyof T>(key: K, params: T[K]): ArrayBuffer;
|
|
4728
|
+
/**
|
|
4729
|
+
* 数据反序列化,反序列化的结果为未加工的原始数据,decode 函数本身不处理 format 过程
|
|
4730
|
+
* @param pbname 待解码数据的 PB 名
|
|
4731
|
+
* @param data 待解码数据
|
|
4732
|
+
*/
|
|
4722
4733
|
decode<K extends keyof T>(pbname: K, uint8array: Uint8Array): T[K];
|
|
4723
4734
|
}
|
|
4724
4735
|
|
|
@@ -9292,12 +9303,6 @@ interface INetwork {
|
|
|
9292
9303
|
type: NetworkType;
|
|
9293
9304
|
}
|
|
9294
9305
|
|
|
9295
|
-
interface IRTCRoomInfo {
|
|
9296
|
-
roomId: string;
|
|
9297
|
-
roomData: unknown[];
|
|
9298
|
-
userCount: number;
|
|
9299
|
-
list: unknown[];
|
|
9300
|
-
}
|
|
9301
9306
|
/** @deprecated */
|
|
9302
9307
|
interface IRtcTokenData {
|
|
9303
9308
|
rtcToken: string;
|
|
@@ -12127,7 +12132,7 @@ interface IIPCMethods {
|
|
|
12127
12132
|
/**
|
|
12128
12133
|
* 断开连接
|
|
12129
12134
|
*/
|
|
12130
|
-
disconnect(closeDB?: boolean, disablePush?: boolean): Promise<
|
|
12135
|
+
disconnect(closeDB?: boolean, disablePush?: boolean): Promise<RCResult>;
|
|
12131
12136
|
/**
|
|
12132
12137
|
* 消息注册
|
|
12133
12138
|
* @description
|
|
@@ -13577,10 +13582,6 @@ interface IRuntime {
|
|
|
13577
13582
|
* 存储模块
|
|
13578
13583
|
*/
|
|
13579
13584
|
localStorage: IStorage;
|
|
13580
|
-
/**
|
|
13581
|
-
* 在某些非浏览器平台,其等同于 localStorage
|
|
13582
|
-
*/
|
|
13583
|
-
sessionStorage: IStorage;
|
|
13584
13585
|
/**
|
|
13585
13586
|
* 获取网络状态
|
|
13586
13587
|
* 2g 3g 4g wifi unkown
|
|
@@ -13947,7 +13948,7 @@ declare type ModuleType<T> = {
|
|
|
13947
13948
|
* @deprecated 因该工具已向 RTC 业务暴露,因此暂时不可删除,待 RTC 迁移到新工具后删除
|
|
13948
13949
|
*/
|
|
13949
13950
|
declare class Codec<T> {
|
|
13950
|
-
private readonly
|
|
13951
|
+
private readonly pbCodec;
|
|
13951
13952
|
/** @deprecated */
|
|
13952
13953
|
constructor(pbDefined: string);
|
|
13953
13954
|
/**
|
|
@@ -13982,6 +13983,7 @@ declare type AbsCodec<T> = Codec<T>;
|
|
|
13982
13983
|
declare const RTCPBMap: CodecPBMaps;
|
|
13983
13984
|
/**
|
|
13984
13985
|
* 仅限 RCCppEngine 内用于类型约束,RTCLib 内不可直接使用
|
|
13986
|
+
* @deprecated
|
|
13985
13987
|
*/
|
|
13986
13988
|
declare type InnerRTCKeyMaps = typeof RTCPBMap;
|
|
13987
13989
|
|
|
@@ -13992,7 +13994,11 @@ declare class PluginContext {
|
|
|
13992
13994
|
* 获取 context
|
|
13993
13995
|
*/
|
|
13994
13996
|
__getContext(): APIContext;
|
|
13995
|
-
/**
|
|
13997
|
+
/**
|
|
13998
|
+
* 创建 PB 编解码器,目前仅对 RTC 业务使用
|
|
13999
|
+
* @param _ 废弃参数
|
|
14000
|
+
* @param pbDesc PB 描述
|
|
14001
|
+
*/
|
|
13996
14002
|
createCodec<T extends CodecPBMaps>(_: T, pbDesc: string): Codec<T>;
|
|
13997
14003
|
createPBCodec<T>(desc: string, _?: Map<string, keyof T>): Codec$1<T>;
|
|
13998
14004
|
/**
|
|
@@ -14676,12 +14682,6 @@ declare class APIContext {
|
|
|
14676
14682
|
readonly dataHosting: DataHosting;
|
|
14677
14683
|
private _versionInfo;
|
|
14678
14684
|
private _typingInfo;
|
|
14679
|
-
/**
|
|
14680
|
-
* RTC 相关的编解码模块,用于向前兼容 RTC 旧版本的编解码,
|
|
14681
|
-
* 包括向 CppEngine 提供 RTC 业务编解码能力
|
|
14682
|
-
* @deprecated
|
|
14683
|
-
*/
|
|
14684
|
-
readonly rtcCodec: Codec<InnerRTCKeyMaps>;
|
|
14685
14685
|
/**
|
|
14686
14686
|
* engine 内部日志工具
|
|
14687
14687
|
*/
|
|
@@ -15447,14 +15447,6 @@ declare class RTCPluginContext extends PluginContext {
|
|
|
15447
15447
|
* 新版本 rtc ping 返回值增加 version 信息
|
|
15448
15448
|
*/
|
|
15449
15449
|
rtcPingResVersion(roomId: string, mode: number, broadcastType?: number): Promise<RCResult<any>>;
|
|
15450
|
-
/**
|
|
15451
|
-
* @deprecated 兼容 rtc v3 方法调用
|
|
15452
|
-
*/
|
|
15453
|
-
getRTCRoomInfo(roomId: string): IPromiseResult<IRTCRoomInfo>;
|
|
15454
|
-
/**
|
|
15455
|
-
* @deprecated 兼容 rtc v3 方法调用
|
|
15456
|
-
*/
|
|
15457
|
-
getRTCUserInfoList(roomId: string): IPromiseResult<IRTCUsers>;
|
|
15458
15450
|
/**
|
|
15459
15451
|
* @deprecated
|
|
15460
15452
|
*/
|
|
@@ -15627,7 +15619,6 @@ declare type IUserSettingsModule = Pick<IIPCMethods, 'setTranslationLanguage' |
|
|
|
15627
15619
|
|
|
15628
15620
|
declare type IIPCMethodsInEngine = Pick<IIPCMethods, 'searchMessagesWithParams' | 'createTag' | 'removeTag' | 'updateTag' | 'getTagList' | 'translateWithParams' | 'getFileUrl' | 'saveTextMessageDraft' | 'getTextMessageDraft' | 'clearTextMessageDraft' | 'getHistoryMessage' | 'clearLocalMessages' | 'deleteLocalMessages' | 'deleteLocalMessagesByTimestamp' | 'batchClearLocalMessagesByTimestamp' | 'insertMessage' | 'batchInsertMessage' | 'setMessageContent' | 'getLocalMessageCount' | 'recallMsg' | 'getSubscribeUsersOnlineStatus' | 'getSubscribeUserStatus' | 'subscribeUser' | 'unSubscribeUser' | 'getSubscribeUserList' | 'getUserProfiles' | 'getMyUserProfile' | 'updateMyUserProfile' | 'sendMessage' | 'connect' | 'disconnect' | 'addToBlacklist' | 'removeFromBlacklist' | 'getBlacklist' | 'getBlacklistStatus' | 'setMessageReceivedStatus' | 'setMessageSentStatus' | 'setCheckDuplicateMessage' | 'setProxy' | 'getProxy' | 'testProxy' | 'setUserStatusListener' | 'getFileToken' | 'rtcSignaling' | 'rtcPing' | 'setCallInfo' | 'getUserStatus' | 'searchConversationByContentWithAllChannel'>;
|
|
15629
15621
|
declare abstract class BasicEngine implements IIPCMethodsInEngine, IModuleContext {
|
|
15630
|
-
protected readonly rtcCodec: Codec<InnerRTCKeyMaps>;
|
|
15631
15622
|
protected readonly _watcher: IEngineWatcher;
|
|
15632
15623
|
protected readonly _options: IAPIContextOption;
|
|
15633
15624
|
private readonly _logger;
|
|
@@ -15661,7 +15652,7 @@ declare abstract class BasicEngine implements IIPCMethodsInEngine, IModuleContex
|
|
|
15661
15652
|
* 引擎初始化
|
|
15662
15653
|
* @param _appkey
|
|
15663
15654
|
*/
|
|
15664
|
-
constructor(
|
|
15655
|
+
constructor(_watcher: IEngineWatcher, _options: IAPIContextOption, _logger: BasicLogger);
|
|
15665
15656
|
protected _rtcSignalingListener?: (buffer: Uint8Array) => void;
|
|
15666
15657
|
/**
|
|
15667
15658
|
* 注册 RTC KV 变更监听器
|
|
@@ -15718,7 +15709,7 @@ declare abstract class BasicEngine implements IIPCMethodsInEngine, IModuleContex
|
|
|
15718
15709
|
* @param closeDB 是否关闭数据库,默认为 true,仅 Electron 平台有效
|
|
15719
15710
|
* @param disablePush 是否禁用推送,默认为 false(≥ 5.20.0)
|
|
15720
15711
|
*/
|
|
15721
|
-
abstract disconnect(closeDB?: boolean, disablePush?: boolean): Promise<
|
|
15712
|
+
abstract disconnect(closeDB?: boolean, disablePush?: boolean): Promise<RCResult>;
|
|
15722
15713
|
/**
|
|
15723
15714
|
* 消息注册
|
|
15724
15715
|
* @description
|