@rongcloud/engine 5.5.8-beem → 5.6.0-beem-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.d.ts +952 -619
- package/index.esm.js +1 -1
- package/index.js +1 -1
- package/package.json +1 -1
package/index.d.ts
CHANGED
|
@@ -251,110 +251,222 @@ declare class RongStreamWriter {
|
|
|
251
251
|
}
|
|
252
252
|
|
|
253
253
|
/**
|
|
254
|
-
*
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
254
|
+
* LogLevel 等级定义,与大数据服务器日志等级保持一致
|
|
255
|
+
*/
|
|
256
|
+
declare enum LogL {
|
|
257
|
+
/**
|
|
258
|
+
* IM 质量数据日志,控制台不打印
|
|
259
|
+
*/
|
|
260
|
+
STATISTICS = -2,
|
|
261
|
+
/**
|
|
262
|
+
* 未明确使用场景,暂未使用,控制台不打印
|
|
263
|
+
* TODO:
|
|
264
|
+
* 暂未明确使用场景,实时日志系统上报?
|
|
265
|
+
* 需要明确下为什么会有 -1,以及与 -2 的区别,并在注释中补充
|
|
266
|
+
*/
|
|
267
|
+
RECORD = -1,
|
|
268
|
+
/**
|
|
269
|
+
* 未明确使用场景,暂未使用,控制台不打印
|
|
270
|
+
*/
|
|
271
|
+
FATAL = 0,
|
|
272
|
+
/**
|
|
273
|
+
* ERROR 级
|
|
274
|
+
*/
|
|
275
|
+
ERROR = 1,
|
|
276
|
+
/**
|
|
277
|
+
* WARN 级
|
|
278
|
+
*/
|
|
279
|
+
WARN = 2,
|
|
280
|
+
/**
|
|
281
|
+
* INFO 级
|
|
282
|
+
*/
|
|
283
|
+
INFO = 3,
|
|
284
|
+
/**
|
|
285
|
+
* DEBUG 级
|
|
286
|
+
*/
|
|
287
|
+
DEBUG = 4
|
|
270
288
|
}
|
|
271
289
|
/**
|
|
272
|
-
*
|
|
273
|
-
* 写数据处理基类
|
|
290
|
+
* 有效的日志等级声明
|
|
274
291
|
*/
|
|
275
|
-
declare
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
292
|
+
declare type EnableLogL = LogL.DEBUG | LogL.INFO | LogL.WARN | LogL.ERROR;
|
|
293
|
+
|
|
294
|
+
declare type LogContent = string | number | boolean | null;
|
|
295
|
+
declare type LogType = 'IM' | 'RTC';
|
|
296
|
+
/**
|
|
297
|
+
* 对外暴露的 Logger 工具接口定义,以隐藏 BasicLogger 其他实现
|
|
298
|
+
*/
|
|
299
|
+
interface ILogger {
|
|
300
|
+
debug(tag: string, content?: LogContent, traceId?: string): void;
|
|
301
|
+
info(tag: string, content?: LogContent, traceId?: string): void;
|
|
302
|
+
warn(tag: string, content?: LogContent, traceId?: string): void;
|
|
303
|
+
error(tag: string, content?: LogContent, traceId?: string): void;
|
|
304
|
+
/**
|
|
305
|
+
* 设置日志打印等级,默认为 `LogL.WARN`
|
|
306
|
+
* @param level
|
|
307
|
+
*/
|
|
308
|
+
setOutputLevel(level?: EnableLogL): void;
|
|
309
|
+
/**
|
|
310
|
+
* 创建事务追踪 ID,全局唯一,便于跨进程、异步事务追踪,需要考虑多进程
|
|
311
|
+
*/
|
|
312
|
+
createTraceId(): string;
|
|
291
313
|
}
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
314
|
+
|
|
315
|
+
interface ILogData {
|
|
316
|
+
/**
|
|
317
|
+
* 日志原始内容
|
|
318
|
+
*/
|
|
319
|
+
content?: LogContent;
|
|
320
|
+
/**
|
|
321
|
+
* 日志标签,如 `L-INIT-O`
|
|
322
|
+
*/
|
|
323
|
+
tag: string;
|
|
324
|
+
/**
|
|
325
|
+
* logger 实例 Id,用于确定日志由谁埋点,如 `RCEngien` 为 engine 包埋点日志
|
|
326
|
+
*/
|
|
327
|
+
loggerId: string;
|
|
328
|
+
/**
|
|
329
|
+
* 日志生成时间
|
|
330
|
+
*/
|
|
331
|
+
time: number;
|
|
332
|
+
/**
|
|
333
|
+
* 应用的声明周期 sessionId
|
|
334
|
+
* @description
|
|
335
|
+
* Electron 环境下,以主进程 sessionId 入库,渲染进程 sessionId 存储于 content 内。
|
|
336
|
+
* 日志上报时,通过 `${mainSessionId}:${renderSessionId}` 形式作为 sessionId 上报
|
|
337
|
+
* @TODO 需确认服务是否允许 `${mainSessionId}:${renderSessionId}` 的方式,以及 sessionId 是否超出长度。
|
|
338
|
+
*/
|
|
339
|
+
sessionId: string;
|
|
340
|
+
/**
|
|
341
|
+
* 日志类型,仅用于大数据后台查阅统计
|
|
342
|
+
*/
|
|
343
|
+
type: 'IM' | 'RTC';
|
|
344
|
+
/**
|
|
345
|
+
* 日志等级,该等级与服务器统计等级保持一致,为入库等级
|
|
346
|
+
*/
|
|
347
|
+
level: LogL;
|
|
348
|
+
/**
|
|
349
|
+
* 事务跟踪 ID
|
|
350
|
+
*/
|
|
351
|
+
traceId?: string;
|
|
298
352
|
}
|
|
299
|
-
|
|
300
|
-
|
|
353
|
+
/**
|
|
354
|
+
* 日志数据库接口
|
|
355
|
+
*/
|
|
356
|
+
interface ILogDB {
|
|
357
|
+
/**
|
|
358
|
+
* 获取实时日志上报的时间戳记录
|
|
359
|
+
*/
|
|
360
|
+
getTimestamp4RealtimeLog(userId: string): Promise<number>;
|
|
361
|
+
/**
|
|
362
|
+
* 设置实时日志上报的时间戳记录
|
|
363
|
+
* @param userId 当前用户 ID
|
|
364
|
+
* @param timestamp
|
|
365
|
+
*/
|
|
366
|
+
setTimestamp4RealtimeLog(userId: string, timestamp: number): Promise<void>;
|
|
367
|
+
/**
|
|
368
|
+
* 根据时间戳和日志等级获取全量日志
|
|
369
|
+
* @param startTime
|
|
370
|
+
* @param endTime
|
|
371
|
+
* @param level
|
|
372
|
+
* @param includeStatistics 是否包含质量统计日志
|
|
373
|
+
*/
|
|
374
|
+
getLogs(startTime: number, endTime: number, level: LogL, includeStatistics: boolean): Promise<{
|
|
375
|
+
logs: ILogData[];
|
|
376
|
+
dbReady: boolean;
|
|
377
|
+
}>;
|
|
301
378
|
}
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
379
|
+
|
|
380
|
+
/**
|
|
381
|
+
* Logger 抽象基类,定义日志采集接口与进程内打印,
|
|
382
|
+
* 由子类继承实现入库逻辑
|
|
383
|
+
*/
|
|
384
|
+
declare abstract class BasicLogger implements ILogger {
|
|
385
|
+
protected readonly _appkey: string;
|
|
386
|
+
protected readonly _id: string;
|
|
387
|
+
protected readonly _type: LogType;
|
|
388
|
+
constructor(_appkey: string, _id: string, _type: LogType);
|
|
389
|
+
private _stdout;
|
|
390
|
+
/**
|
|
391
|
+
* 用户的打印日志等级配置
|
|
392
|
+
*/
|
|
393
|
+
private outputLevel;
|
|
394
|
+
setOutputLevel(level?: EnableLogL): void;
|
|
395
|
+
/**
|
|
396
|
+
* 由子类继承实现日志入库
|
|
397
|
+
* @override
|
|
398
|
+
*/
|
|
399
|
+
protected abstract flush(data: ILogData): void;
|
|
400
|
+
private _log;
|
|
401
|
+
debug: (tag: string, content?: LogContent | undefined, traceId?: string | undefined) => void;
|
|
402
|
+
info: (tag: string, content?: LogContent | undefined, traceId?: string | undefined) => void;
|
|
403
|
+
warn: (tag: string, content?: LogContent | undefined, traceId?: string | undefined) => void;
|
|
404
|
+
error: (tag: string, content?: LogContent | undefined, traceId?: string | undefined) => void;
|
|
405
|
+
/**
|
|
406
|
+
* 内部质量数据统计接口,仅限 IMLib 与 RTCLib 内部使用
|
|
407
|
+
*/
|
|
408
|
+
__statistics: (tag: string, content?: LogContent | undefined, traceId?: string | undefined) => void;
|
|
409
|
+
/**
|
|
410
|
+
* 创建事务追踪 ID,全局唯一,便于跨进程、异步事务追踪,需要考虑多进程
|
|
411
|
+
*/
|
|
412
|
+
createTraceId(): string;
|
|
413
|
+
/**
|
|
414
|
+
* 获取当前进程的 sessionId,全局唯一
|
|
415
|
+
* @returns
|
|
416
|
+
*/
|
|
417
|
+
getSessionId(): string;
|
|
313
418
|
}
|
|
419
|
+
|
|
314
420
|
/**
|
|
315
|
-
*
|
|
316
|
-
* 发消息使用
|
|
421
|
+
* 实现基于 IndexDB 存储的日志类
|
|
317
422
|
*/
|
|
318
|
-
declare class
|
|
319
|
-
|
|
320
|
-
data: any;
|
|
321
|
-
targetId: string;
|
|
322
|
-
date: any;
|
|
323
|
-
syncMsg: boolean;
|
|
324
|
-
identifier: string;
|
|
325
|
-
constructor(topic: string, data: any, targetId: string);
|
|
326
|
-
writeMessage(stream: RongStreamWriter): void;
|
|
423
|
+
declare class IndexDBLogger extends BasicLogger {
|
|
424
|
+
protected flush(data: ILogData): void;
|
|
327
425
|
}
|
|
426
|
+
|
|
328
427
|
/**
|
|
329
|
-
*
|
|
330
|
-
*
|
|
428
|
+
* 消息被拦截类型
|
|
429
|
+
* @category Enum
|
|
331
430
|
*/
|
|
332
|
-
declare
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
};
|
|
431
|
+
declare enum MessageBlockType {
|
|
432
|
+
/**
|
|
433
|
+
全局敏感词:命中了融云内置的全局敏感词
|
|
434
|
+
*/
|
|
435
|
+
GLOBAL = 1,
|
|
436
|
+
/**
|
|
437
|
+
自定义敏感词拦截:命中了客户在融云自定义的敏感词
|
|
438
|
+
*/
|
|
439
|
+
CUSTOM = 2,
|
|
440
|
+
/**
|
|
441
|
+
第三方审核拦截:命中了第三方(数美)或模板路由决定不下发的状态
|
|
442
|
+
*/
|
|
443
|
+
THIRD_PARTY = 3
|
|
346
444
|
}
|
|
347
445
|
/**
|
|
348
|
-
*
|
|
349
|
-
* Web 主动查询
|
|
446
|
+
* 消息被拦截源触发类型
|
|
350
447
|
*/
|
|
351
|
-
declare
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
448
|
+
declare enum MessageBlockSourceType {
|
|
449
|
+
/** 原始消息 */
|
|
450
|
+
MSG_ORIGINAL = 0,
|
|
451
|
+
/** 消息扩展 */
|
|
452
|
+
MSG_EXPANSION = 1,
|
|
453
|
+
/** 消息修改 */
|
|
454
|
+
MSG_MODIFY = 2
|
|
455
|
+
}
|
|
456
|
+
|
|
457
|
+
/**
|
|
458
|
+
* 消息方向
|
|
459
|
+
* @category Enum
|
|
460
|
+
*/
|
|
461
|
+
declare enum MessageDirection {
|
|
462
|
+
/**
|
|
463
|
+
* 己方发送消息
|
|
464
|
+
*/
|
|
465
|
+
SEND = 1,
|
|
466
|
+
/**
|
|
467
|
+
* 己方接收消息
|
|
468
|
+
*/
|
|
469
|
+
RECEIVE = 2
|
|
358
470
|
}
|
|
359
471
|
|
|
360
472
|
/**
|
|
@@ -395,21 +507,6 @@ declare enum FileType {
|
|
|
395
507
|
COMBINE_HTML = 6
|
|
396
508
|
}
|
|
397
509
|
|
|
398
|
-
/**
|
|
399
|
-
* 消息方向
|
|
400
|
-
* @category Enum
|
|
401
|
-
*/
|
|
402
|
-
declare enum MessageDirection {
|
|
403
|
-
/**
|
|
404
|
-
* 己方发送消息
|
|
405
|
-
*/
|
|
406
|
-
SEND = 1,
|
|
407
|
-
/**
|
|
408
|
-
* 己方接收消息
|
|
409
|
-
*/
|
|
410
|
-
RECEIVE = 2
|
|
411
|
-
}
|
|
412
|
-
|
|
413
510
|
/**
|
|
414
511
|
* IM 错误码范围段
|
|
415
512
|
* 2 开头为 IM Server 返回错误码
|
|
@@ -1384,6 +1481,7 @@ declare enum ChatroomEntryType {
|
|
|
1384
1481
|
}
|
|
1385
1482
|
|
|
1386
1483
|
/**
|
|
1484
|
+
* @deprecated
|
|
1387
1485
|
* 日志级别
|
|
1388
1486
|
* @category Enum
|
|
1389
1487
|
*/
|
|
@@ -1397,13 +1495,15 @@ declare enum LogLevel {
|
|
|
1397
1495
|
STATISTICS = 6,
|
|
1398
1496
|
NONE = 1000
|
|
1399
1497
|
}
|
|
1498
|
+
/**
|
|
1499
|
+
* @deprecated
|
|
1500
|
+
*/
|
|
1400
1501
|
declare enum LogSource {
|
|
1401
1502
|
IM = "IM",
|
|
1402
1503
|
RTC = "RTC"
|
|
1403
1504
|
}
|
|
1404
1505
|
/**
|
|
1405
1506
|
* IMLib 埋点日志 Id 枚举
|
|
1406
|
-
* @desc 参考文档-https://rongcloud.yuque.com/tbvylv/znhprz/dpt9wf#fE9u
|
|
1407
1507
|
*/
|
|
1408
1508
|
declare enum LogTagId {
|
|
1409
1509
|
L_IMSDK_VER_O = "L-imsdk_ver-O",
|
|
@@ -1412,7 +1512,6 @@ declare enum LogTagId {
|
|
|
1412
1512
|
L_INIT_O = "L-init-O",
|
|
1413
1513
|
A_DESTROY_O = "A_DESTROY_O",
|
|
1414
1514
|
L_DESTROY_O = "L_DESTROY_O",
|
|
1415
|
-
P_INIT_O = "P-init-O",
|
|
1416
1515
|
A_CONNECT_T = "A-connect-T",
|
|
1417
1516
|
A_CONNECT_R = "A-connect-R",
|
|
1418
1517
|
A_CONNECT_S = "A-connect-S",
|
|
@@ -1422,14 +1521,24 @@ declare enum LogTagId {
|
|
|
1422
1521
|
L_CONNECT_T = "L-connect-T",
|
|
1423
1522
|
L_CONNECT_R = "L-connect-R",
|
|
1424
1523
|
L_CONNECT_S = "L-connect-S",
|
|
1425
|
-
P_CONNECT_O = "P-connect-O",
|
|
1426
|
-
P_CONNECT_S = "P-connect-S",
|
|
1427
1524
|
L_NOTIFY_ULTRA_ONLINE_S = "L-notify-ultra-online-S",
|
|
1428
1525
|
L_ULTRA_SYNC_DONE_S = "L-ultra-sync-done-S",
|
|
1526
|
+
L_BATCH_MESSAGE_O = "L-BATCH_MESSAGE-O",
|
|
1527
|
+
/** 业务层 APIContext onmessage 回调报错 */
|
|
1528
|
+
A_MSG_LISTENER_E = "A-MSG_LISTENER-E",
|
|
1529
|
+
/**
|
|
1530
|
+
* @deprecated
|
|
1531
|
+
* 用于保留迁移前的日志,后续删除
|
|
1532
|
+
*/
|
|
1533
|
+
O = "L-original-O",
|
|
1534
|
+
/** 插件安装 */
|
|
1535
|
+
L_INSTALL_PLUGIN_T = "L-INSTALL_PLUGIN-T",
|
|
1536
|
+
/** 插件安装结果 */
|
|
1537
|
+
L_INSTALL_PLUGIN_R = "L-INSTALL_PLUGIN-R",
|
|
1538
|
+
/** navi 配置错误 */
|
|
1539
|
+
L_NAVI_CONF_E = "L-NAVI_CONF_ERROR-E",
|
|
1429
1540
|
A_SEND_MSG_T = "A-send_msg-T",
|
|
1430
1541
|
A_SEND_MSG_R = "A-send_msg-R",
|
|
1431
|
-
P_SEND_MSG_T = "P-send_msg-T",
|
|
1432
|
-
P_SEND_MSG_R = "P-send_msg-R",
|
|
1433
1542
|
L_SEND_MSG_T = "L-send_msg-T",
|
|
1434
1543
|
L_SEND_MSG_R = "L-send_msg-R",
|
|
1435
1544
|
L_PULL_MSG_T = "L-pull_msg-T",
|
|
@@ -1449,7 +1558,6 @@ declare enum LogTagId {
|
|
|
1449
1558
|
L_PULL_CONVERSATION_S = "L-pull_conversation-S",
|
|
1450
1559
|
L_RECALL_ULTRA_MSG_S = "L-recall_ultra_msg-S",
|
|
1451
1560
|
A_REGTYP_O = "A-regtyp-O",
|
|
1452
|
-
P_REGTYP_O = "P-regtype-O",
|
|
1453
1561
|
P_REGTYP_E = "P-regtype-E",
|
|
1454
1562
|
L_GET_NAVI_T = "L-get_navi-T",
|
|
1455
1563
|
L_GET_NAVI_R = "L-get_navi-R",
|
|
@@ -1487,7 +1595,26 @@ declare enum LogTagId {
|
|
|
1487
1595
|
L_NOTIFY_NAVI_CHANGE_E = "L-notify_navi_change-E",
|
|
1488
1596
|
L_REPORT_FULL_LOG_O = "L-report_full_log-O",
|
|
1489
1597
|
L_REPORT_FULL_LOG_T = "L-report_full_log-T",
|
|
1490
|
-
L_REPORT_FULL_LOG_R = "L-report_full_log-R"
|
|
1598
|
+
L_REPORT_FULL_LOG_R = "L-report_full_log-R",
|
|
1599
|
+
/** 解析 navi logPolicy 报错 */
|
|
1600
|
+
L_REPORT_LOG_POLICY_E = "L-parse_navi_logpolicy-E",
|
|
1601
|
+
/** 运行时环境不支持 IndexDB */
|
|
1602
|
+
L_UNSUPPORT_INDEXDB_O = "L-unsupport_IndexDB-O",
|
|
1603
|
+
L_LOGDB_OPEN_FAILED_E = "L-logDB_open_failed-E",
|
|
1604
|
+
L_LOGDB_CLOSED_S = "L-logDB_closed-S",
|
|
1605
|
+
L_LOGDB_ERROR_E = "L-logDB_error-S",
|
|
1606
|
+
L_LOGDB_ABORT_S = "L-logDB_abort-S",
|
|
1607
|
+
/** 实时日志上报 */
|
|
1608
|
+
L_REALTIME_LOG_R = "L_REALTIME_LOG_R",
|
|
1609
|
+
/** 实时日志上报结果 */
|
|
1610
|
+
L_REALTIME_LOG_T = "L_REALTIME_LOG_T",
|
|
1611
|
+
L_UNKNOWN_TOPIC_E = "L_UNKNOWN_TOPIC_E",
|
|
1612
|
+
L_RECV_RMTP_O = "L_RECV_RMTP_O",
|
|
1613
|
+
L_RECV_RMTP_E = "L_RECV_RMTP_E",
|
|
1614
|
+
/** 版本号上报 */
|
|
1615
|
+
L_VER_REPORT_T = "L-VER_REPORT-T",
|
|
1616
|
+
/** 版本号上报结果 */
|
|
1617
|
+
L_VER_REPORT_R = "L-VER_REPORT-R"
|
|
1491
1618
|
}
|
|
1492
1619
|
|
|
1493
1620
|
/**
|
|
@@ -1499,34 +1626,15 @@ declare enum ChatroomUserChangeType {
|
|
|
1499
1626
|
JOIN = 1
|
|
1500
1627
|
}
|
|
1501
1628
|
|
|
1502
|
-
|
|
1503
|
-
* 消息被拦截类型
|
|
1504
|
-
* @category Enum
|
|
1505
|
-
*/
|
|
1506
|
-
declare enum MessageBlockType {
|
|
1507
|
-
/**
|
|
1508
|
-
全局敏感词:命中了融云内置的全局敏感词
|
|
1509
|
-
*/
|
|
1510
|
-
GLOBAL = 1,
|
|
1629
|
+
declare enum StoreKeys {
|
|
1511
1630
|
/**
|
|
1512
|
-
|
|
1513
|
-
|
|
1514
|
-
|
|
1631
|
+
* Navi 数据缓存,暂未使用
|
|
1632
|
+
*/
|
|
1633
|
+
NAVI = "rc-navi",
|
|
1515
1634
|
/**
|
|
1516
|
-
|
|
1517
|
-
|
|
1518
|
-
|
|
1519
|
-
}
|
|
1520
|
-
/**
|
|
1521
|
-
* 消息被拦截源触发类型
|
|
1522
|
-
*/
|
|
1523
|
-
declare enum MessageBlockSourceType {
|
|
1524
|
-
/** 原始消息 */
|
|
1525
|
-
MSG_ORIGINAL = 0,
|
|
1526
|
-
/** 消息扩展 */
|
|
1527
|
-
MSG_EXPANSION = 1,
|
|
1528
|
-
/** 消息修改 */
|
|
1529
|
-
MSG_MODIFY = 2
|
|
1635
|
+
* 实时日志已上报的时间戳
|
|
1636
|
+
*/
|
|
1637
|
+
REALTIME_LOG_TIMESTAMP = "rc-realtime-log-timestamp"
|
|
1530
1638
|
}
|
|
1531
1639
|
|
|
1532
1640
|
declare enum UltraGroupChannelType {
|
|
@@ -1649,102 +1757,6 @@ declare enum RTCJoinType {
|
|
|
1649
1757
|
COEXIST = 2
|
|
1650
1758
|
}
|
|
1651
1759
|
|
|
1652
|
-
/**
|
|
1653
|
-
* 会话属性
|
|
1654
|
-
* @category Interface
|
|
1655
|
-
*/
|
|
1656
|
-
interface IConversationOption {
|
|
1657
|
-
conversationType: ConversationType;
|
|
1658
|
-
targetId: string;
|
|
1659
|
-
channelId?: string;
|
|
1660
|
-
}
|
|
1661
|
-
interface IServerRTCRoomEntry {
|
|
1662
|
-
key: string;
|
|
1663
|
-
value: string;
|
|
1664
|
-
status: number;
|
|
1665
|
-
timestamp: number;
|
|
1666
|
-
uid: string;
|
|
1667
|
-
}
|
|
1668
|
-
interface IChrmKVEntry {
|
|
1669
|
-
key: string;
|
|
1670
|
-
value?: string;
|
|
1671
|
-
isSendNotification?: boolean;
|
|
1672
|
-
notificationExtra?: string;
|
|
1673
|
-
isOverwrite?: boolean;
|
|
1674
|
-
isAutoDelete?: boolean;
|
|
1675
|
-
timestamp?: number;
|
|
1676
|
-
userId?: string;
|
|
1677
|
-
type?: number;
|
|
1678
|
-
isDeleted?: boolean;
|
|
1679
|
-
version?: number;
|
|
1680
|
-
}
|
|
1681
|
-
interface IChrmKVEntries {
|
|
1682
|
-
entries: {
|
|
1683
|
-
key: string;
|
|
1684
|
-
value?: string;
|
|
1685
|
-
timestamp?: number;
|
|
1686
|
-
version?: number;
|
|
1687
|
-
}[];
|
|
1688
|
-
notificationExtra?: string;
|
|
1689
|
-
isOverwrite?: boolean;
|
|
1690
|
-
isAutoDelete?: boolean;
|
|
1691
|
-
timestamp?: number;
|
|
1692
|
-
userId?: string;
|
|
1693
|
-
type?: number;
|
|
1694
|
-
isDeleted?: boolean;
|
|
1695
|
-
}
|
|
1696
|
-
interface IChrmKVPullData {
|
|
1697
|
-
kvEntries: IChrmKVEntry[];
|
|
1698
|
-
isFullUpdate?: boolean;
|
|
1699
|
-
syncTime?: number;
|
|
1700
|
-
}
|
|
1701
|
-
interface IServerConversationStatus {
|
|
1702
|
-
conversationType: number;
|
|
1703
|
-
targetId: string;
|
|
1704
|
-
updatedTime?: number;
|
|
1705
|
-
notificationStatus?: number;
|
|
1706
|
-
notificationLevel?: number;
|
|
1707
|
-
isTop?: boolean;
|
|
1708
|
-
type?: number;
|
|
1709
|
-
tags?: IConversationTag[];
|
|
1710
|
-
channelId?: string;
|
|
1711
|
-
}
|
|
1712
|
-
interface IUserSettingItem {
|
|
1713
|
-
targetId: number;
|
|
1714
|
-
type: number;
|
|
1715
|
-
key: string;
|
|
1716
|
-
value: any;
|
|
1717
|
-
version: number;
|
|
1718
|
-
status: number;
|
|
1719
|
-
tags: IConversationTag[];
|
|
1720
|
-
}
|
|
1721
|
-
interface IServerUserSetting {
|
|
1722
|
-
settings: {
|
|
1723
|
-
[key: string]: IUserSettingItem;
|
|
1724
|
-
};
|
|
1725
|
-
version: number;
|
|
1726
|
-
}
|
|
1727
|
-
interface ISyncMsgArgs {
|
|
1728
|
-
inboxTime: number;
|
|
1729
|
-
sendboxTime: number;
|
|
1730
|
-
broadcastSyncTime?: number;
|
|
1731
|
-
}
|
|
1732
|
-
interface IGetMsgOption {
|
|
1733
|
-
timestamp?: number;
|
|
1734
|
-
count?: number;
|
|
1735
|
-
order?: number;
|
|
1736
|
-
channelId?: string;
|
|
1737
|
-
}
|
|
1738
|
-
interface IGetConversationListOption {
|
|
1739
|
-
type?: number;
|
|
1740
|
-
count?: number;
|
|
1741
|
-
startTime?: number;
|
|
1742
|
-
order?: 0 | 1;
|
|
1743
|
-
}
|
|
1744
|
-
interface IClearMsgOption {
|
|
1745
|
-
timestamp?: number;
|
|
1746
|
-
}
|
|
1747
|
-
|
|
1748
1760
|
/**
|
|
1749
1761
|
* @category Interface
|
|
1750
1762
|
*/
|
|
@@ -2405,189 +2417,6 @@ interface IUltraUnreadMsg {
|
|
|
2405
2417
|
mentionedType?: number;
|
|
2406
2418
|
}
|
|
2407
2419
|
|
|
2408
|
-
/**
|
|
2409
|
-
* TODO: 确定对外暴露的必要性
|
|
2410
|
-
* @deprecated
|
|
2411
|
-
*/
|
|
2412
|
-
declare const DelayTimer: {
|
|
2413
|
-
_delayTime: number;
|
|
2414
|
-
/**
|
|
2415
|
-
* 方法并未引用,getTimer 实际返回值始终为 Date.now()
|
|
2416
|
-
* @deprecated
|
|
2417
|
-
*/
|
|
2418
|
-
setTime: (time: number) => void;
|
|
2419
|
-
getTime: () => number;
|
|
2420
|
-
};
|
|
2421
|
-
|
|
2422
|
-
declare enum HttpMethod {
|
|
2423
|
-
GET = "GET",
|
|
2424
|
-
POST = "POST"
|
|
2425
|
-
}
|
|
2426
|
-
interface IRequest {
|
|
2427
|
-
url: string;
|
|
2428
|
-
/**
|
|
2429
|
-
* @default `HttpMethod.GET`
|
|
2430
|
-
*/
|
|
2431
|
-
method?: HttpMethod | 'GET' | 'POST';
|
|
2432
|
-
/**
|
|
2433
|
-
* 查询数据
|
|
2434
|
-
*/
|
|
2435
|
-
query?: {
|
|
2436
|
-
[key: string]: string | number | null;
|
|
2437
|
-
};
|
|
2438
|
-
/**
|
|
2439
|
-
* Request Header 信息
|
|
2440
|
-
*/
|
|
2441
|
-
headers?: {
|
|
2442
|
-
[key: string]: string;
|
|
2443
|
-
};
|
|
2444
|
-
/**
|
|
2445
|
-
* Request Body 数据
|
|
2446
|
-
*/
|
|
2447
|
-
body?: Object | string;
|
|
2448
|
-
/**
|
|
2449
|
-
* 超时设置,默认 `60s`
|
|
2450
|
-
*/
|
|
2451
|
-
timeout?: number;
|
|
2452
|
-
/**
|
|
2453
|
-
* 【Alipay-Only】
|
|
2454
|
-
* 期望返回的数据格式,如果为 json 则返回后会对返回的数据进行一次 JSON.parse
|
|
2455
|
-
*/
|
|
2456
|
-
dataType?: 'json' | 'text' | 'base64' | 'arraybuffer';
|
|
2457
|
-
}
|
|
2458
|
-
interface IStorage {
|
|
2459
|
-
setItem(key: string, value: string): void;
|
|
2460
|
-
getItem(key: string): string | null;
|
|
2461
|
-
removeItem(key: string): void;
|
|
2462
|
-
clear(): void;
|
|
2463
|
-
}
|
|
2464
|
-
interface IResponse {
|
|
2465
|
-
status: number;
|
|
2466
|
-
data?: string;
|
|
2467
|
-
}
|
|
2468
|
-
/**
|
|
2469
|
-
* 网络状态枚举
|
|
2470
|
-
*/
|
|
2471
|
-
declare enum NetworkType {
|
|
2472
|
-
WIFI = "wifi",
|
|
2473
|
-
FOUR_G = "4g",
|
|
2474
|
-
THREE_G = "3g",
|
|
2475
|
-
TWO_G = "2g",
|
|
2476
|
-
FIVE_G = "2g",
|
|
2477
|
-
THREE_GENT = "3gnet",
|
|
2478
|
-
UNKONWN = "unknown"
|
|
2479
|
-
}
|
|
2480
|
-
interface IWebSocket {
|
|
2481
|
-
/**
|
|
2482
|
-
* 监听连接建立事件,此时 WebSocket 实例已准备好收发数据
|
|
2483
|
-
* @param callback
|
|
2484
|
-
*/
|
|
2485
|
-
onOpen(callback: () => void): void;
|
|
2486
|
-
/**
|
|
2487
|
-
* 监听连接关闭事件
|
|
2488
|
-
* @param callback
|
|
2489
|
-
*/
|
|
2490
|
-
onClose(callback: (code?: number, reason?: string) => void): void;
|
|
2491
|
-
/**
|
|
2492
|
-
* 监听接收服务器消息事件
|
|
2493
|
-
* @param callback
|
|
2494
|
-
*/
|
|
2495
|
-
onMessage(callback: (data: string | ArrayBuffer) => void): void;
|
|
2496
|
-
/**
|
|
2497
|
-
* 监听链接错误事件
|
|
2498
|
-
* @param callback
|
|
2499
|
-
*/
|
|
2500
|
-
onError(callback: (error: unknown) => void): void;
|
|
2501
|
-
/**
|
|
2502
|
-
* 向服务器发送数据
|
|
2503
|
-
* @param data
|
|
2504
|
-
*/
|
|
2505
|
-
send(data: ArrayBuffer | string): void;
|
|
2506
|
-
/**
|
|
2507
|
-
* 关闭连接
|
|
2508
|
-
* @param code
|
|
2509
|
-
* @param reason
|
|
2510
|
-
*/
|
|
2511
|
-
close(code?: number, reason?: string): void;
|
|
2512
|
-
}
|
|
2513
|
-
/**
|
|
2514
|
-
* 平台运行时抽象
|
|
2515
|
-
*/
|
|
2516
|
-
interface IRuntime {
|
|
2517
|
-
/**
|
|
2518
|
-
* 平台标识
|
|
2519
|
-
*/
|
|
2520
|
-
tag: string;
|
|
2521
|
-
/**
|
|
2522
|
-
* 发送 http 请求
|
|
2523
|
-
* @param options
|
|
2524
|
-
*/
|
|
2525
|
-
httpReq(options: IRequest): Promise<IResponse>;
|
|
2526
|
-
/**
|
|
2527
|
-
* 是否使用导航
|
|
2528
|
-
*/
|
|
2529
|
-
useNavi: boolean;
|
|
2530
|
-
/**
|
|
2531
|
-
* websocket 地址上附加的平台字段
|
|
2532
|
-
*/
|
|
2533
|
-
connectPlatform: string;
|
|
2534
|
-
/**
|
|
2535
|
-
* websocket 地址上 apiVer 字段,代表代码是否来源于 uniapp
|
|
2536
|
-
*/
|
|
2537
|
-
isFromUniapp: boolean;
|
|
2538
|
-
/**
|
|
2539
|
-
* 创建长连接实例
|
|
2540
|
-
*/
|
|
2541
|
-
createWebSocket?(url: string, protocols?: string[]): IWebSocket;
|
|
2542
|
-
/**
|
|
2543
|
-
* 存储模块
|
|
2544
|
-
*/
|
|
2545
|
-
localStorage: IStorage;
|
|
2546
|
-
/**
|
|
2547
|
-
* 在某些非浏览器平台,其等同于 localStorage
|
|
2548
|
-
*/
|
|
2549
|
-
sessionStorage: IStorage;
|
|
2550
|
-
/**
|
|
2551
|
-
* 获取网络状态
|
|
2552
|
-
* 2g 3g 4g wifi unkown
|
|
2553
|
-
*/
|
|
2554
|
-
getNetworkType(): Promise<NetworkType>;
|
|
2555
|
-
}
|
|
2556
|
-
|
|
2557
|
-
/**
|
|
2558
|
-
* @category Interface
|
|
2559
|
-
*/
|
|
2560
|
-
interface IAsyncRes<T = void> {
|
|
2561
|
-
/**
|
|
2562
|
-
* Promise 执行结果
|
|
2563
|
-
*/
|
|
2564
|
-
code: ErrorCode;
|
|
2565
|
-
/**
|
|
2566
|
-
* 结果数据
|
|
2567
|
-
*/
|
|
2568
|
-
data?: T;
|
|
2569
|
-
/**
|
|
2570
|
-
* 错误消息
|
|
2571
|
-
*/
|
|
2572
|
-
msg?: string;
|
|
2573
|
-
}
|
|
2574
|
-
/**
|
|
2575
|
-
* 异步任务结果定义
|
|
2576
|
-
* @description
|
|
2577
|
-
* 通过 `Promise.resolve` 来处理预期内的异常,进而通过 Uncatch Promise Error 暴露预期外的异常
|
|
2578
|
-
*/
|
|
2579
|
-
declare type IPromiseResult<T = void> = Promise<IAsyncRes<T>>;
|
|
2580
|
-
interface IConnectResult {
|
|
2581
|
-
/**
|
|
2582
|
-
* 连接错误码
|
|
2583
|
-
*/
|
|
2584
|
-
code: ErrorCode;
|
|
2585
|
-
/**
|
|
2586
|
-
* 导航获取成功后即可有相应的值,在导航数据获取完成之前该值为 undefined
|
|
2587
|
-
*/
|
|
2588
|
-
userId?: string;
|
|
2589
|
-
}
|
|
2590
|
-
|
|
2591
2420
|
/**
|
|
2592
2421
|
* 从服务器拉取到的会话数据结构
|
|
2593
2422
|
* @category Interface
|
|
@@ -2929,8 +2758,13 @@ interface INaviInfo {
|
|
|
2929
2758
|
*/
|
|
2930
2759
|
logSwitch: number;
|
|
2931
2760
|
/**
|
|
2932
|
-
*
|
|
2933
|
-
* @example `'{
|
|
2761
|
+
* 实时日志上传策略,值为 JSON 字符串
|
|
2762
|
+
* @example `'{
|
|
2763
|
+
* "url": "logcollection.ronghub.com", // 上传地址
|
|
2764
|
+
* "level": 1, // 日志等级
|
|
2765
|
+
* "itv": 6, // 上传频率,即时间间隔,单位 s
|
|
2766
|
+
* "times": 5 // 重试次数?
|
|
2767
|
+
* }'`
|
|
2934
2768
|
*/
|
|
2935
2769
|
logPolicy: string;
|
|
2936
2770
|
/**
|
|
@@ -3278,64 +3112,233 @@ interface IUploadAuth {
|
|
|
3278
3112
|
*/
|
|
3279
3113
|
s3BucketName: string;
|
|
3280
3114
|
/**
|
|
3281
|
-
* stc Authorization 头
|
|
3115
|
+
* stc Authorization 头
|
|
3116
|
+
*/
|
|
3117
|
+
stcAuthorization: string;
|
|
3118
|
+
/**
|
|
3119
|
+
* stc xAmzContentSha256
|
|
3120
|
+
*/
|
|
3121
|
+
stcContentSha256: string;
|
|
3122
|
+
/**
|
|
3123
|
+
* stc date
|
|
3124
|
+
*/
|
|
3125
|
+
stcDate: string;
|
|
3126
|
+
/**
|
|
3127
|
+
* stc 存储空间名称
|
|
3128
|
+
*/
|
|
3129
|
+
stcBucketName: string;
|
|
3130
|
+
}
|
|
3131
|
+
|
|
3132
|
+
interface IRTCRoomInfo {
|
|
3133
|
+
roomId: string;
|
|
3134
|
+
roomData: unknown[];
|
|
3135
|
+
userCount: number;
|
|
3136
|
+
list: unknown[];
|
|
3137
|
+
}
|
|
3138
|
+
interface IRtcTokenData {
|
|
3139
|
+
rtcToken: string;
|
|
3140
|
+
}
|
|
3141
|
+
interface IRTCUsers {
|
|
3142
|
+
users: {
|
|
3143
|
+
[userId: string]: {
|
|
3144
|
+
/**
|
|
3145
|
+
* 发布的资源数据,是一个 JSON 字符串,解析后为发布的资源列表
|
|
3146
|
+
*/
|
|
3147
|
+
uris?: string;
|
|
3148
|
+
/**
|
|
3149
|
+
* 加房间的身份标识,保存主房间 roomId
|
|
3150
|
+
*/
|
|
3151
|
+
extra?: string;
|
|
3152
|
+
};
|
|
3153
|
+
};
|
|
3154
|
+
}
|
|
3155
|
+
interface IJoinRTCRoomData extends IRTCUsers {
|
|
3156
|
+
token: string;
|
|
3157
|
+
sessionId: string;
|
|
3158
|
+
roomInfo: {
|
|
3159
|
+
key: string;
|
|
3160
|
+
value: string;
|
|
3161
|
+
}[];
|
|
3162
|
+
kvEntries: IServerRTCRoomEntry[];
|
|
3163
|
+
offlineKickTime: number;
|
|
3164
|
+
}
|
|
3165
|
+
interface KVString {
|
|
3166
|
+
[key: string]: string;
|
|
3167
|
+
}
|
|
3168
|
+
/**
|
|
3169
|
+
* 设置 RTC 人员 inner、outer 数据
|
|
3170
|
+
*/
|
|
3171
|
+
interface IRTCUserData {
|
|
3172
|
+
[key: string]: string;
|
|
3173
|
+
}
|
|
3174
|
+
|
|
3175
|
+
/**
|
|
3176
|
+
* @category Interface
|
|
3177
|
+
*/
|
|
3178
|
+
interface IAsyncRes<T = void> {
|
|
3179
|
+
/**
|
|
3180
|
+
* Promise 执行结果
|
|
3181
|
+
*/
|
|
3182
|
+
code: ErrorCode;
|
|
3183
|
+
/**
|
|
3184
|
+
* 结果数据
|
|
3185
|
+
*/
|
|
3186
|
+
data?: T;
|
|
3187
|
+
/**
|
|
3188
|
+
* 错误消息
|
|
3189
|
+
*/
|
|
3190
|
+
msg?: string;
|
|
3191
|
+
}
|
|
3192
|
+
/**
|
|
3193
|
+
* 异步任务结果定义
|
|
3194
|
+
* @description
|
|
3195
|
+
* 通过 `Promise.resolve` 来处理预期内的异常,进而通过 Uncatch Promise Error 暴露预期外的异常
|
|
3196
|
+
*/
|
|
3197
|
+
declare type IPromiseResult<T = void> = Promise<IAsyncRes<T>>;
|
|
3198
|
+
interface IConnectResult {
|
|
3199
|
+
/**
|
|
3200
|
+
* 连接错误码
|
|
3201
|
+
*/
|
|
3202
|
+
code: ErrorCode;
|
|
3203
|
+
/**
|
|
3204
|
+
* 导航获取成功后即可有相应的值,在导航数据获取完成之前该值为 undefined
|
|
3205
|
+
*/
|
|
3206
|
+
userId?: string;
|
|
3207
|
+
}
|
|
3208
|
+
|
|
3209
|
+
declare enum HttpMethod {
|
|
3210
|
+
GET = "GET",
|
|
3211
|
+
POST = "POST"
|
|
3212
|
+
}
|
|
3213
|
+
interface IRequest {
|
|
3214
|
+
url: string;
|
|
3215
|
+
/**
|
|
3216
|
+
* @default `HttpMethod.GET`
|
|
3217
|
+
*/
|
|
3218
|
+
method?: HttpMethod | 'GET' | 'POST';
|
|
3219
|
+
/**
|
|
3220
|
+
* 查询数据
|
|
3221
|
+
*/
|
|
3222
|
+
query?: {
|
|
3223
|
+
[key: string]: string | number | null;
|
|
3224
|
+
};
|
|
3225
|
+
/**
|
|
3226
|
+
* Request Header 信息
|
|
3227
|
+
*/
|
|
3228
|
+
headers?: {
|
|
3229
|
+
[key: string]: string;
|
|
3230
|
+
};
|
|
3231
|
+
/**
|
|
3232
|
+
* Request Body 数据
|
|
3233
|
+
*/
|
|
3234
|
+
body?: Object | string;
|
|
3235
|
+
/**
|
|
3236
|
+
* 超时设置,默认 `60s`
|
|
3237
|
+
*/
|
|
3238
|
+
timeout?: number;
|
|
3239
|
+
/**
|
|
3240
|
+
* 【Alipay-Only】
|
|
3241
|
+
* 期望返回的数据格式,如果为 json 则返回后会对返回的数据进行一次 JSON.parse
|
|
3242
|
+
*/
|
|
3243
|
+
dataType?: 'json' | 'text' | 'base64' | 'arraybuffer';
|
|
3244
|
+
}
|
|
3245
|
+
interface IStorage {
|
|
3246
|
+
setItem(key: string, value: string): void;
|
|
3247
|
+
getItem(key: string): string | null;
|
|
3248
|
+
removeItem(key: string): void;
|
|
3249
|
+
clear(): void;
|
|
3250
|
+
}
|
|
3251
|
+
interface IResponse {
|
|
3252
|
+
status: number;
|
|
3253
|
+
data?: string;
|
|
3254
|
+
}
|
|
3255
|
+
/**
|
|
3256
|
+
* 网络状态枚举
|
|
3257
|
+
*/
|
|
3258
|
+
declare enum NetworkType {
|
|
3259
|
+
WIFI = "wifi",
|
|
3260
|
+
FOUR_G = "4g",
|
|
3261
|
+
THREE_G = "3g",
|
|
3262
|
+
TWO_G = "2g",
|
|
3263
|
+
FIVE_G = "2g",
|
|
3264
|
+
THREE_GENT = "3gnet",
|
|
3265
|
+
UNKONWN = "unknown"
|
|
3266
|
+
}
|
|
3267
|
+
interface IWebSocket {
|
|
3268
|
+
/**
|
|
3269
|
+
* 监听连接建立事件,此时 WebSocket 实例已准备好收发数据
|
|
3270
|
+
* @param callback
|
|
3271
|
+
*/
|
|
3272
|
+
onOpen(callback: () => void): void;
|
|
3273
|
+
/**
|
|
3274
|
+
* 监听连接关闭事件
|
|
3275
|
+
* @param callback
|
|
3276
|
+
*/
|
|
3277
|
+
onClose(callback: (code?: number, reason?: string) => void): void;
|
|
3278
|
+
/**
|
|
3279
|
+
* 监听接收服务器消息事件
|
|
3280
|
+
* @param callback
|
|
3281
|
+
*/
|
|
3282
|
+
onMessage(callback: (data: string | ArrayBuffer) => void): void;
|
|
3283
|
+
/**
|
|
3284
|
+
* 监听链接错误事件
|
|
3285
|
+
* @param callback
|
|
3286
|
+
*/
|
|
3287
|
+
onError(callback: (error: unknown) => void): void;
|
|
3288
|
+
/**
|
|
3289
|
+
* 向服务器发送数据
|
|
3290
|
+
* @param data
|
|
3291
|
+
*/
|
|
3292
|
+
send(data: ArrayBuffer | string): void;
|
|
3293
|
+
/**
|
|
3294
|
+
* 关闭连接
|
|
3295
|
+
* @param code
|
|
3296
|
+
* @param reason
|
|
3297
|
+
*/
|
|
3298
|
+
close(code?: number, reason?: string): void;
|
|
3299
|
+
}
|
|
3300
|
+
/**
|
|
3301
|
+
* 平台运行时抽象
|
|
3302
|
+
*/
|
|
3303
|
+
interface IRuntime {
|
|
3304
|
+
/**
|
|
3305
|
+
* 平台标识
|
|
3306
|
+
*/
|
|
3307
|
+
tag: string;
|
|
3308
|
+
/**
|
|
3309
|
+
* 发送 http 请求
|
|
3310
|
+
* @param options
|
|
3311
|
+
*/
|
|
3312
|
+
httpReq(options: IRequest): Promise<IResponse>;
|
|
3313
|
+
/**
|
|
3314
|
+
* 是否使用导航
|
|
3315
|
+
*/
|
|
3316
|
+
useNavi: boolean;
|
|
3317
|
+
/**
|
|
3318
|
+
* websocket 地址上附加的平台字段
|
|
3319
|
+
*/
|
|
3320
|
+
connectPlatform: string;
|
|
3321
|
+
/**
|
|
3322
|
+
* websocket 地址上 apiVer 字段,代表代码是否来源于 uniapp
|
|
3323
|
+
*/
|
|
3324
|
+
isFromUniapp: boolean;
|
|
3325
|
+
/**
|
|
3326
|
+
* 创建长连接实例
|
|
3282
3327
|
*/
|
|
3283
|
-
|
|
3328
|
+
createWebSocket?(url: string, protocols?: string[]): IWebSocket;
|
|
3284
3329
|
/**
|
|
3285
|
-
*
|
|
3330
|
+
* 存储模块
|
|
3286
3331
|
*/
|
|
3287
|
-
|
|
3332
|
+
localStorage: IStorage;
|
|
3288
3333
|
/**
|
|
3289
|
-
*
|
|
3334
|
+
* 在某些非浏览器平台,其等同于 localStorage
|
|
3290
3335
|
*/
|
|
3291
|
-
|
|
3336
|
+
sessionStorage: IStorage;
|
|
3292
3337
|
/**
|
|
3293
|
-
*
|
|
3338
|
+
* 获取网络状态
|
|
3339
|
+
* 2g 3g 4g wifi unkown
|
|
3294
3340
|
*/
|
|
3295
|
-
|
|
3296
|
-
}
|
|
3297
|
-
|
|
3298
|
-
interface IRTCRoomInfo {
|
|
3299
|
-
roomId: string;
|
|
3300
|
-
roomData: unknown[];
|
|
3301
|
-
userCount: number;
|
|
3302
|
-
list: unknown[];
|
|
3303
|
-
}
|
|
3304
|
-
interface IRtcTokenData {
|
|
3305
|
-
rtcToken: string;
|
|
3306
|
-
}
|
|
3307
|
-
interface IRTCUsers {
|
|
3308
|
-
users: {
|
|
3309
|
-
[userId: string]: {
|
|
3310
|
-
/**
|
|
3311
|
-
* 发布的资源数据,是一个 JSON 字符串,解析后为发布的资源列表
|
|
3312
|
-
*/
|
|
3313
|
-
uris?: string;
|
|
3314
|
-
/**
|
|
3315
|
-
* 加房间的身份标识,保存主房间 roomId
|
|
3316
|
-
*/
|
|
3317
|
-
extra?: string;
|
|
3318
|
-
};
|
|
3319
|
-
};
|
|
3320
|
-
}
|
|
3321
|
-
interface IJoinRTCRoomData extends IRTCUsers {
|
|
3322
|
-
token: string;
|
|
3323
|
-
sessionId: string;
|
|
3324
|
-
roomInfo: {
|
|
3325
|
-
key: string;
|
|
3326
|
-
value: string;
|
|
3327
|
-
}[];
|
|
3328
|
-
kvEntries: IServerRTCRoomEntry[];
|
|
3329
|
-
offlineKickTime: number;
|
|
3330
|
-
}
|
|
3331
|
-
interface KVString {
|
|
3332
|
-
[key: string]: string;
|
|
3333
|
-
}
|
|
3334
|
-
/**
|
|
3335
|
-
* 设置 RTC 人员 inner、outer 数据
|
|
3336
|
-
*/
|
|
3337
|
-
interface IRTCUserData {
|
|
3338
|
-
[key: string]: string;
|
|
3341
|
+
getNetworkType(): Promise<NetworkType>;
|
|
3339
3342
|
}
|
|
3340
3343
|
|
|
3341
3344
|
/**
|
|
@@ -4202,73 +4205,411 @@ interface IGroupMessageDeliveredStatusInfo {
|
|
|
4202
4205
|
MessageUId: string;
|
|
4203
4206
|
deliveryCount: number;
|
|
4204
4207
|
}
|
|
4205
|
-
interface IGroupMessageDeliverStatus {
|
|
4206
|
-
totalCount: number;
|
|
4207
|
-
list: IGroupMessageDeliveredStatusInfo[];
|
|
4208
|
+
interface IGroupMessageDeliverStatus {
|
|
4209
|
+
totalCount: number;
|
|
4210
|
+
list: IGroupMessageDeliveredStatusInfo[];
|
|
4211
|
+
}
|
|
4212
|
+
|
|
4213
|
+
/**
|
|
4214
|
+
* IndexDB中存储的log数据
|
|
4215
|
+
*/
|
|
4216
|
+
interface ILogInfo {
|
|
4217
|
+
sessionId: string;
|
|
4218
|
+
time: number;
|
|
4219
|
+
level: LogLevel;
|
|
4220
|
+
content: string;
|
|
4221
|
+
userId?: string;
|
|
4222
|
+
logSource?: LogSource;
|
|
4223
|
+
tagId?: LogTagId;
|
|
4224
|
+
}
|
|
4225
|
+
interface IRealTimeLog {
|
|
4226
|
+
level: LogLevel;
|
|
4227
|
+
content: string;
|
|
4228
|
+
}
|
|
4229
|
+
interface ILogExtensions {
|
|
4230
|
+
traceId?: string;
|
|
4231
|
+
logSource?: LogSource;
|
|
4232
|
+
}
|
|
4233
|
+
interface ILogInit {
|
|
4234
|
+
userId?: string;
|
|
4235
|
+
localLogLevel?: LogLevel;
|
|
4236
|
+
customLogPrint?: (logLevel: LogLevel, msg: string) => void;
|
|
4237
|
+
}
|
|
4238
|
+
interface IInitBigDataOption {
|
|
4239
|
+
runtime?: IRuntime;
|
|
4240
|
+
appkey?: string;
|
|
4241
|
+
version?: string;
|
|
4242
|
+
userId?: string;
|
|
4243
|
+
}
|
|
4244
|
+
interface IBigdataLogInit extends IInitBigDataOption {
|
|
4245
|
+
logUrl: string;
|
|
4246
|
+
sessionId: string;
|
|
4247
|
+
}
|
|
4248
|
+
|
|
4249
|
+
/**
|
|
4250
|
+
* 定义已废弃,请使用 `IRemoveChatroomEntries` 替换
|
|
4251
|
+
* @deprecated
|
|
4252
|
+
*/
|
|
4253
|
+
declare type IRemoveChatRoomEntries = IRemoveChatroomEntries;
|
|
4254
|
+
/**
|
|
4255
|
+
* 定义已废弃,请使用 `IChatroomEntry` 替换
|
|
4256
|
+
* @deprecated
|
|
4257
|
+
*/
|
|
4258
|
+
declare type IChatRoomEntry = IChatroomEntry;
|
|
4259
|
+
/**
|
|
4260
|
+
* 定义已废弃,请使用 `IChatroomEntries` 替换
|
|
4261
|
+
* @deprecated
|
|
4262
|
+
*/
|
|
4263
|
+
declare type IChatRoomEntries = IChatroomEntries;
|
|
4264
|
+
/**
|
|
4265
|
+
* 定义已废弃,请使用 `IRemoveChatroomEntry` 替换
|
|
4266
|
+
* @deprecated
|
|
4267
|
+
*/
|
|
4268
|
+
declare type IRemoveChatRoomEntry = IRemoveChatroomEntry;
|
|
4269
|
+
|
|
4270
|
+
/**
|
|
4271
|
+
* 日志上报工具,负责处理实时日志上报和下消息拉日志业务。
|
|
4272
|
+
* 通过 DB 和 Logger 两个抽象接口组合使用,
|
|
4273
|
+
* 避免业务与不同平台不同的 DB 数据库耦合,从而最大限度代码复用,
|
|
4274
|
+
* 上报工具仅处理业务,无需关心 DB 和 Logger 的实际类型
|
|
4275
|
+
*/
|
|
4276
|
+
declare abstract class BasicReporter {
|
|
4277
|
+
private appkey;
|
|
4278
|
+
private deviceId;
|
|
4279
|
+
/**
|
|
4280
|
+
* 设备描述信息
|
|
4281
|
+
*/
|
|
4282
|
+
private deviceInfo;
|
|
4283
|
+
/**
|
|
4284
|
+
* Logger 数据库实例,有日志数据库的读写方法,使上报与数据库解耦
|
|
4285
|
+
*/
|
|
4286
|
+
protected readonly logDB: ILogDB;
|
|
4287
|
+
/**
|
|
4288
|
+
* logger 实例
|
|
4289
|
+
*/
|
|
4290
|
+
protected readonly logger: BasicLogger;
|
|
4291
|
+
/**
|
|
4292
|
+
* 当前用户 id
|
|
4293
|
+
*/
|
|
4294
|
+
protected userId: string;
|
|
4295
|
+
constructor(appkey: string, deviceId: string,
|
|
4296
|
+
/**
|
|
4297
|
+
* 设备描述信息
|
|
4298
|
+
*/
|
|
4299
|
+
deviceInfo: string,
|
|
4300
|
+
/**
|
|
4301
|
+
* Logger 数据库实例,有日志数据库的读写方法,使上报与数据库解耦
|
|
4302
|
+
*/
|
|
4303
|
+
logDB: ILogDB,
|
|
4304
|
+
/**
|
|
4305
|
+
* logger 实例
|
|
4306
|
+
*/
|
|
4307
|
+
logger: BasicLogger);
|
|
4308
|
+
private timer;
|
|
4309
|
+
protected started: boolean;
|
|
4310
|
+
/**
|
|
4311
|
+
* 根据配置启动实时日志上报,在导航获取完成后启动,导航中包含 userId 信息
|
|
4312
|
+
* 实时日志仅获取当前时间 - 10s 以前的日志上报,避免多页面并行写库造成数据遗漏
|
|
4313
|
+
*/
|
|
4314
|
+
checkStart(navi: INaviInfo): Promise<void>;
|
|
4315
|
+
/**
|
|
4316
|
+
* 实时日志上报
|
|
4317
|
+
* @override IndexDBReporter 重载此方法,增加同设备多页面多端时进程竞争检测
|
|
4318
|
+
*/
|
|
4319
|
+
protected realtimeReport(url: string, level: LogL, itv: number): Promise<void>;
|
|
4320
|
+
private sendLogs;
|
|
4321
|
+
/**
|
|
4322
|
+
* 处理下消息拉日志,以拉取包含 `LogL.DEBUG` 级别的全量日志
|
|
4323
|
+
* @param startTime 拉取起始时间
|
|
4324
|
+
* @param endTime 拉取结束时间
|
|
4325
|
+
* @param platform 平台
|
|
4326
|
+
* @param uri 本次拉取的上传地址,若无值,使用导航配置下发地址
|
|
4327
|
+
* @param logId 拉取事务 Id,用于上传日志时的 Http 请求
|
|
4328
|
+
* @param messageUId 消息 messageUId
|
|
4329
|
+
*/
|
|
4330
|
+
report(startTime: number, endTime: number, platform: string, uri: string, logId: string, messageUId: string): Promise<void>;
|
|
4331
|
+
private transcsv;
|
|
4332
|
+
/**
|
|
4333
|
+
* 以 `POST` 方法向服务发送日志数据
|
|
4334
|
+
* @param url
|
|
4335
|
+
* @param content
|
|
4336
|
+
*/
|
|
4337
|
+
protected abstract send(req: IRequest): Promise<IResponse>;
|
|
4338
|
+
/**
|
|
4339
|
+
* 清理计时器,停止定时任务
|
|
4340
|
+
*/
|
|
4341
|
+
stop(): void;
|
|
4342
|
+
}
|
|
4343
|
+
|
|
4344
|
+
declare class IndexDBReporter extends BasicReporter {
|
|
4345
|
+
private runtime;
|
|
4346
|
+
/**
|
|
4347
|
+
* 客户端配置的上报等级,仅限 Beem IndexDB 日志版本可用,不设置时,以服务器 navi 下发配置为准
|
|
4348
|
+
*/
|
|
4349
|
+
private clientReportLevel?;
|
|
4350
|
+
constructor(appkey: string, runtime: IRuntime, logger: BasicLogger,
|
|
4351
|
+
/**
|
|
4352
|
+
* 客户端配置的上报等级,仅限 Beem IndexDB 日志版本可用,不设置时,以服务器 navi 下发配置为准
|
|
4353
|
+
*/
|
|
4354
|
+
clientReportLevel?: EnableLogL | undefined);
|
|
4355
|
+
protected send(req: IRequest): Promise<IResponse>;
|
|
4356
|
+
/**
|
|
4357
|
+
* @override 重写实现
|
|
4358
|
+
*/
|
|
4359
|
+
checkStart(navi: INaviInfo): Promise<void>;
|
|
4360
|
+
/**
|
|
4361
|
+
* 进程竞争检测,检查是否为执行上报的进程
|
|
4362
|
+
* @param callback
|
|
4363
|
+
* @returns
|
|
4364
|
+
*/
|
|
4365
|
+
private isReporter;
|
|
4366
|
+
/**
|
|
4367
|
+
* @param startTime
|
|
4368
|
+
* @param endTime
|
|
4369
|
+
* @param platform
|
|
4370
|
+
* @param uri
|
|
4371
|
+
* @param logId
|
|
4372
|
+
* @param messageUId
|
|
4373
|
+
*/
|
|
4374
|
+
report(startTime: number, endTime: number, platform: string, uri: string, logId: string, messageUId: string): Promise<void>;
|
|
4375
|
+
protected realtimeReport(url: string, level: LogL, itv: number): Promise<void>;
|
|
4376
|
+
}
|
|
4377
|
+
|
|
4378
|
+
/**
|
|
4379
|
+
* 初始化 DB 模块,按 APPKEY 分库,后续需要将日志与业务数据库也分开
|
|
4380
|
+
* @param appkey
|
|
4381
|
+
*/
|
|
4382
|
+
declare const initLogDB: (appkey: string, logger: ILogger) => void;
|
|
4383
|
+
/**
|
|
4384
|
+
* IndexDB 日志数据库反初始化,在切换 APPKEY 时调用
|
|
4385
|
+
* @returns
|
|
4386
|
+
*/
|
|
4387
|
+
declare const deInitLogDB: () => Promise<void>;
|
|
4388
|
+
|
|
4389
|
+
/**
|
|
4390
|
+
* @description
|
|
4391
|
+
* 读数据处理基类
|
|
4392
|
+
*/
|
|
4393
|
+
declare class BaseReader {
|
|
4394
|
+
readonly header: Header;
|
|
4395
|
+
messageId: number;
|
|
4396
|
+
timestamp: number;
|
|
4397
|
+
syncMsg: boolean;
|
|
4398
|
+
protected identifier: string;
|
|
4399
|
+
constructor(header: Header);
|
|
4400
|
+
getIdentifier(): string | number;
|
|
4401
|
+
read(logger: ILogger, stream: RongStreamReader, length: number, protocolVer: ConnAckProtocolVer): void;
|
|
4402
|
+
readMessage(logger: ILogger, stream: RongStreamReader, length?: number, protocolVer?: ConnAckProtocolVer): {
|
|
4403
|
+
stream: RongStreamReader;
|
|
4404
|
+
length: number | undefined;
|
|
4405
|
+
};
|
|
4406
|
+
}
|
|
4407
|
+
/**
|
|
4408
|
+
* @description
|
|
4409
|
+
* 写数据处理基类
|
|
4410
|
+
*/
|
|
4411
|
+
declare abstract class BaseWriter {
|
|
4412
|
+
private _header;
|
|
4413
|
+
lengthSize: number;
|
|
4414
|
+
data: any;
|
|
4415
|
+
messageId: number;
|
|
4416
|
+
topic: string;
|
|
4417
|
+
targetId: string;
|
|
4418
|
+
identifier: string;
|
|
4419
|
+
constructor(headerType: OperationType);
|
|
4420
|
+
getIdentifier(): string | number;
|
|
4421
|
+
write(stream: RongStreamWriter): void;
|
|
4422
|
+
abstract writeMessage(stream: RongStreamWriter): void;
|
|
4423
|
+
setHeaderQos(qos: number): void;
|
|
4424
|
+
getHeaderFlag(): number;
|
|
4425
|
+
getLengthSize(): number;
|
|
4426
|
+
getBufferData(): Int8Array;
|
|
4427
|
+
}
|
|
4428
|
+
declare class RetryableReader extends BaseReader {
|
|
4429
|
+
messageId: number;
|
|
4430
|
+
readMessage(logger: ILogger, stream: RongStreamReader, length: number): {
|
|
4431
|
+
stream: RongStreamReader;
|
|
4432
|
+
length: number;
|
|
4433
|
+
};
|
|
4434
|
+
}
|
|
4435
|
+
declare class RetryableWriter extends BaseWriter {
|
|
4436
|
+
writeMessage(stream: RongStreamWriter): void;
|
|
4437
|
+
}
|
|
4438
|
+
declare class PublishReader extends RetryableReader {
|
|
4439
|
+
topic: string;
|
|
4440
|
+
data: any;
|
|
4441
|
+
targetId: string;
|
|
4442
|
+
date: any;
|
|
4443
|
+
syncMsg: boolean;
|
|
4444
|
+
identifier: string;
|
|
4445
|
+
readMessage(logger: ILogger, stream: RongStreamReader, length: number): {
|
|
4446
|
+
stream: RongStreamReader;
|
|
4447
|
+
length: number;
|
|
4448
|
+
};
|
|
4449
|
+
}
|
|
4450
|
+
/**
|
|
4451
|
+
* @description
|
|
4452
|
+
* 发消息使用
|
|
4453
|
+
*/
|
|
4454
|
+
declare class PublishWriter extends RetryableWriter {
|
|
4455
|
+
topic: string;
|
|
4456
|
+
data: any;
|
|
4457
|
+
targetId: string;
|
|
4458
|
+
date: any;
|
|
4459
|
+
syncMsg: boolean;
|
|
4460
|
+
identifier: string;
|
|
4461
|
+
constructor(topic: string, data: any, targetId: string);
|
|
4462
|
+
writeMessage(stream: RongStreamWriter): void;
|
|
4463
|
+
}
|
|
4464
|
+
/**
|
|
4465
|
+
* @description
|
|
4466
|
+
* 发消息, Server 给的 Ack 回执
|
|
4467
|
+
*/
|
|
4468
|
+
declare class PubAckReader extends RetryableReader {
|
|
4469
|
+
status: number;
|
|
4470
|
+
date: number;
|
|
4471
|
+
data: any;
|
|
4472
|
+
millisecond: number;
|
|
4473
|
+
messageUId: string;
|
|
4474
|
+
timestamp: number;
|
|
4475
|
+
identifier: string;
|
|
4476
|
+
topic: string;
|
|
4477
|
+
targetId: string;
|
|
4478
|
+
readMessage(logger: ILogger, stream: RongStreamReader, length: number): {
|
|
4479
|
+
stream: RongStreamReader;
|
|
4480
|
+
length: number;
|
|
4481
|
+
};
|
|
4482
|
+
}
|
|
4483
|
+
/**
|
|
4484
|
+
* @description
|
|
4485
|
+
* Web 主动查询
|
|
4486
|
+
*/
|
|
4487
|
+
declare class QueryWriter extends RetryableWriter {
|
|
4488
|
+
topic: string;
|
|
4489
|
+
data: any;
|
|
4490
|
+
targetId: string;
|
|
4491
|
+
identifier: string;
|
|
4492
|
+
constructor(topic: string, data: any, targetId: string);
|
|
4493
|
+
writeMessage(stream: RongStreamWriter): void;
|
|
4208
4494
|
}
|
|
4209
4495
|
|
|
4210
4496
|
/**
|
|
4211
|
-
*
|
|
4497
|
+
* 会话属性
|
|
4498
|
+
* @category Interface
|
|
4212
4499
|
*/
|
|
4213
|
-
interface
|
|
4214
|
-
|
|
4215
|
-
|
|
4216
|
-
|
|
4217
|
-
content: string;
|
|
4218
|
-
userId?: string;
|
|
4219
|
-
logSource?: LogSource;
|
|
4220
|
-
tagId?: LogTagId;
|
|
4221
|
-
}
|
|
4222
|
-
interface IRealTimeLog {
|
|
4223
|
-
level: LogLevel;
|
|
4224
|
-
content: string;
|
|
4500
|
+
interface IConversationOption {
|
|
4501
|
+
conversationType: ConversationType;
|
|
4502
|
+
targetId: string;
|
|
4503
|
+
channelId?: string;
|
|
4225
4504
|
}
|
|
4226
|
-
interface
|
|
4227
|
-
|
|
4228
|
-
|
|
4505
|
+
interface IServerRTCRoomEntry {
|
|
4506
|
+
key: string;
|
|
4507
|
+
value: string;
|
|
4508
|
+
status: number;
|
|
4509
|
+
timestamp: number;
|
|
4510
|
+
uid: string;
|
|
4229
4511
|
}
|
|
4230
|
-
interface
|
|
4512
|
+
interface IChrmKVEntry {
|
|
4513
|
+
key: string;
|
|
4514
|
+
value?: string;
|
|
4515
|
+
isSendNotification?: boolean;
|
|
4516
|
+
notificationExtra?: string;
|
|
4517
|
+
isOverwrite?: boolean;
|
|
4518
|
+
isAutoDelete?: boolean;
|
|
4519
|
+
timestamp?: number;
|
|
4231
4520
|
userId?: string;
|
|
4232
|
-
|
|
4233
|
-
|
|
4521
|
+
type?: number;
|
|
4522
|
+
isDeleted?: boolean;
|
|
4523
|
+
version?: number;
|
|
4234
4524
|
}
|
|
4235
|
-
interface
|
|
4236
|
-
|
|
4237
|
-
|
|
4238
|
-
|
|
4525
|
+
interface IChrmKVEntries {
|
|
4526
|
+
entries: {
|
|
4527
|
+
key: string;
|
|
4528
|
+
value?: string;
|
|
4529
|
+
timestamp?: number;
|
|
4530
|
+
version?: number;
|
|
4531
|
+
}[];
|
|
4532
|
+
notificationExtra?: string;
|
|
4533
|
+
isOverwrite?: boolean;
|
|
4534
|
+
isAutoDelete?: boolean;
|
|
4535
|
+
timestamp?: number;
|
|
4239
4536
|
userId?: string;
|
|
4537
|
+
type?: number;
|
|
4538
|
+
isDeleted?: boolean;
|
|
4240
4539
|
}
|
|
4241
|
-
interface
|
|
4242
|
-
|
|
4243
|
-
|
|
4540
|
+
interface IChrmKVPullData {
|
|
4541
|
+
kvEntries: IChrmKVEntry[];
|
|
4542
|
+
isFullUpdate?: boolean;
|
|
4543
|
+
syncTime?: number;
|
|
4544
|
+
}
|
|
4545
|
+
interface IServerConversationStatus {
|
|
4546
|
+
conversationType: number;
|
|
4547
|
+
targetId: string;
|
|
4548
|
+
updatedTime?: number;
|
|
4549
|
+
notificationStatus?: number;
|
|
4550
|
+
notificationLevel?: number;
|
|
4551
|
+
isTop?: boolean;
|
|
4552
|
+
type?: number;
|
|
4553
|
+
tags?: IConversationTag[];
|
|
4554
|
+
channelId?: string;
|
|
4555
|
+
}
|
|
4556
|
+
interface IUserSettingItem {
|
|
4557
|
+
targetId: number;
|
|
4558
|
+
type: number;
|
|
4559
|
+
key: string;
|
|
4560
|
+
value: any;
|
|
4561
|
+
version: number;
|
|
4562
|
+
status: number;
|
|
4563
|
+
tags: IConversationTag[];
|
|
4564
|
+
}
|
|
4565
|
+
interface IServerUserSetting {
|
|
4566
|
+
settings: {
|
|
4567
|
+
[key: string]: IUserSettingItem;
|
|
4568
|
+
};
|
|
4569
|
+
version: number;
|
|
4570
|
+
}
|
|
4571
|
+
interface ISyncMsgArgs {
|
|
4572
|
+
inboxTime: number;
|
|
4573
|
+
sendboxTime: number;
|
|
4574
|
+
broadcastSyncTime?: number;
|
|
4575
|
+
}
|
|
4576
|
+
interface IGetMsgOption {
|
|
4577
|
+
timestamp?: number;
|
|
4578
|
+
count?: number;
|
|
4579
|
+
order?: number;
|
|
4580
|
+
channelId?: string;
|
|
4581
|
+
}
|
|
4582
|
+
interface IGetConversationListOption {
|
|
4583
|
+
type?: number;
|
|
4584
|
+
count?: number;
|
|
4585
|
+
startTime?: number;
|
|
4586
|
+
order?: 0 | 1;
|
|
4587
|
+
}
|
|
4588
|
+
interface IClearMsgOption {
|
|
4589
|
+
timestamp?: number;
|
|
4244
4590
|
}
|
|
4245
4591
|
|
|
4246
4592
|
/**
|
|
4247
|
-
*
|
|
4248
|
-
* @deprecated
|
|
4249
|
-
*/
|
|
4250
|
-
declare type IRemoveChatRoomEntries = IRemoveChatroomEntries;
|
|
4251
|
-
/**
|
|
4252
|
-
* 定义已废弃,请使用 `IChatroomEntry` 替换
|
|
4253
|
-
* @deprecated
|
|
4254
|
-
*/
|
|
4255
|
-
declare type IChatRoomEntry = IChatroomEntry;
|
|
4256
|
-
/**
|
|
4257
|
-
* 定义已废弃,请使用 `IChatroomEntries` 替换
|
|
4258
|
-
* @deprecated
|
|
4259
|
-
*/
|
|
4260
|
-
declare type IChatRoomEntries = IChatroomEntries;
|
|
4261
|
-
/**
|
|
4262
|
-
* 定义已废弃,请使用 `IRemoveChatroomEntry` 替换
|
|
4593
|
+
* TODO: 确定对外暴露的必要性
|
|
4263
4594
|
* @deprecated
|
|
4264
4595
|
*/
|
|
4265
|
-
declare
|
|
4596
|
+
declare const DelayTimer: {
|
|
4597
|
+
_delayTime: number;
|
|
4598
|
+
/**
|
|
4599
|
+
* 方法并未引用,getTimer 实际返回值始终为 Date.now()
|
|
4600
|
+
* @deprecated
|
|
4601
|
+
*/
|
|
4602
|
+
setTime: (time: number) => void;
|
|
4603
|
+
getTime: () => number;
|
|
4604
|
+
};
|
|
4266
4605
|
|
|
4267
4606
|
/**
|
|
4268
4607
|
* 序列化、反序列化数据通道
|
|
4269
4608
|
*/
|
|
4270
4609
|
declare class DataCodec {
|
|
4610
|
+
private logger;
|
|
4271
4611
|
private _codec;
|
|
4612
|
+
constructor(logger: BasicLogger);
|
|
4272
4613
|
private static createPBCodec;
|
|
4273
4614
|
/**
|
|
4274
4615
|
* PB 数据 转为 rmtp 数据 反序列化 通用数据
|
|
@@ -4550,6 +4891,7 @@ interface IDataChannelWatcher {
|
|
|
4550
4891
|
declare class WebSocketChannel {
|
|
4551
4892
|
private _runtime;
|
|
4552
4893
|
private _watcher;
|
|
4894
|
+
private logger;
|
|
4553
4895
|
readonly codec: DataCodec;
|
|
4554
4896
|
connectedTime: number;
|
|
4555
4897
|
userId: string;
|
|
@@ -4564,7 +4906,7 @@ declare class WebSocketChannel {
|
|
|
4564
4906
|
* 接收多端同步消息时,等待 PubAck 的 Promise.resolve 函数
|
|
4565
4907
|
*/
|
|
4566
4908
|
private _syncMessageIds;
|
|
4567
|
-
constructor(_runtime: IRuntime, _watcher: IDataChannelWatcher);
|
|
4909
|
+
constructor(_runtime: IRuntime, _watcher: IDataChannelWatcher, logger: BasicLogger);
|
|
4568
4910
|
/**
|
|
4569
4911
|
* 建立连接,连接成功则返回 Websocket 实例,否则返回连接错误码
|
|
4570
4912
|
* @param appkey
|
|
@@ -4691,10 +5033,6 @@ interface IAPIContextOption {
|
|
|
4691
5033
|
* IMLib 版本号
|
|
4692
5034
|
*/
|
|
4693
5035
|
apiVersion: string;
|
|
4694
|
-
/**
|
|
4695
|
-
* IMLib 包名
|
|
4696
|
-
*/
|
|
4697
|
-
apiPKGName?: string;
|
|
4698
5036
|
/**
|
|
4699
5037
|
* 自定义导航地址:
|
|
4700
5038
|
* 1. 私有云环境下该值为必填项
|
|
@@ -4706,55 +5044,18 @@ interface IAPIContextOption {
|
|
|
4706
5044
|
* 7. 公有云默认使用 https 协议
|
|
4707
5045
|
*/
|
|
4708
5046
|
navigators: string[];
|
|
4709
|
-
/**
|
|
4710
|
-
* (参数已废弃)~~c++ 协议栈数据库地址~~
|
|
4711
|
-
* @deprecated
|
|
4712
|
-
*/
|
|
4713
|
-
dbPath?: string;
|
|
4714
5047
|
/**
|
|
4715
5048
|
* 小程序的 CMP 代理地址
|
|
4716
5049
|
*/
|
|
4717
5050
|
miniCMPProxy: string[];
|
|
4718
|
-
/**
|
|
4719
|
-
* 修改 engine log 打印等级
|
|
4720
|
-
*/
|
|
4721
|
-
logLevel?: LogLevel;
|
|
4722
|
-
/**
|
|
4723
|
-
* 修改默认的 log 输出函数
|
|
4724
|
-
*/
|
|
4725
|
-
logStdout?: (logLevel: LogLevel, content: string) => void;
|
|
4726
|
-
/**
|
|
4727
|
-
* (已废弃)私有云标识
|
|
4728
|
-
* @deprecated
|
|
4729
|
-
*/
|
|
4730
|
-
isEnterPrise?: boolean;
|
|
4731
5051
|
/**
|
|
4732
5052
|
* typing状态过期时间
|
|
4733
5053
|
*/
|
|
4734
5054
|
typingExpireTime?: number;
|
|
4735
|
-
/**
|
|
4736
|
-
* 是否打开 IndexDB 存储,默认为 true
|
|
4737
|
-
*/
|
|
4738
|
-
indexDBSwitch?: boolean;
|
|
4739
5055
|
/**
|
|
4740
5056
|
* 是否校验证书,默认为 true
|
|
4741
5057
|
*/
|
|
4742
5058
|
checkCA?: boolean;
|
|
4743
|
-
/**
|
|
4744
|
-
* TODO: 自定义策略覆盖服务策略有安全风险,等产品确认通用化逻辑,是否前后端共同建立双重开关
|
|
4745
|
-
* 目前仅 Beem Web-Meeting 使用
|
|
4746
|
-
* @deprecated
|
|
4747
|
-
* @hidden
|
|
4748
|
-
* 实时日志收集功能自定义上传策略
|
|
4749
|
-
* @param {number} logSwitch 日志收集功能开关,0 关闭;1 开启
|
|
4750
|
-
* @param {LogLevel} level 日志上传级别
|
|
4751
|
-
* @param {number} itv: interval 即日志上传间隔,单位秒,最小时间间隔 1 秒
|
|
4752
|
-
*/
|
|
4753
|
-
logPolicy?: {
|
|
4754
|
-
logSwitch?: number;
|
|
4755
|
-
level?: LogLevel;
|
|
4756
|
-
itv?: number;
|
|
4757
|
-
};
|
|
4758
5059
|
/**
|
|
4759
5060
|
* 开启后,SDK 内的 HTTP 请求将由 Electron 主进程内发送。
|
|
4760
5061
|
* @since 5.6.0
|
|
@@ -4766,6 +5067,16 @@ interface IAPIContextOption {
|
|
|
4766
5067
|
* @defautl `false`
|
|
4767
5068
|
*/
|
|
4768
5069
|
httpInMainProcess: boolean;
|
|
5070
|
+
/**
|
|
5071
|
+
* 修改内部日志打印等级,默认输出 `LogL.WARN` 及以上级别
|
|
5072
|
+
*/
|
|
5073
|
+
logOutputLevel?: EnableLogL;
|
|
5074
|
+
/**
|
|
5075
|
+
* 自定义实时日志上报等级。当实时日志开启时,该等级配置会覆盖服务下发配置!不配置时,以服务下发配置为准。
|
|
5076
|
+
* @hidden
|
|
5077
|
+
* @deprecated
|
|
5078
|
+
*/
|
|
5079
|
+
__reportLogLevel?: EnableLogL;
|
|
4769
5080
|
}
|
|
4770
5081
|
|
|
4771
5082
|
interface IPluginGenerator<API, InitOption> {
|
|
@@ -4806,12 +5117,20 @@ declare class Codec<T> {
|
|
|
4806
5117
|
* Key 对应的 Value 结构映射表,用于不同 Key 数据的编解码
|
|
4807
5118
|
*/
|
|
4808
5119
|
private pbmaps;
|
|
5120
|
+
/**
|
|
5121
|
+
* 允许不传 logger 实例以向前兼容
|
|
5122
|
+
*/
|
|
5123
|
+
private logger?;
|
|
4809
5124
|
private readonly pbModules;
|
|
4810
5125
|
constructor(
|
|
4811
5126
|
/**
|
|
4812
5127
|
* Key 对应的 Value 结构映射表,用于不同 Key 数据的编解码
|
|
4813
5128
|
*/
|
|
4814
|
-
pbmaps: T, pbDefined: string
|
|
5129
|
+
pbmaps: T, pbDefined: string,
|
|
5130
|
+
/**
|
|
5131
|
+
* 允许不传 logger 实例以向前兼容
|
|
5132
|
+
*/
|
|
5133
|
+
logger?: ILogger | undefined);
|
|
4815
5134
|
getModule(pbname: string): any;
|
|
4816
5135
|
/**
|
|
4817
5136
|
* 数据序列化
|
|
@@ -4856,7 +5175,6 @@ declare class APIContext {
|
|
|
4856
5175
|
readonly coreVersion: string;
|
|
4857
5176
|
readonly appkey: string;
|
|
4858
5177
|
readonly apiVersion: string;
|
|
4859
|
-
readonly apiPKGName: string;
|
|
4860
5178
|
private readonly _options;
|
|
4861
5179
|
private _versionInfo;
|
|
4862
5180
|
private _typingInfo;
|
|
@@ -4869,6 +5187,10 @@ declare class APIContext {
|
|
|
4869
5187
|
* 包括向 CppEngine 提供 RTC 业务编解码能力
|
|
4870
5188
|
*/
|
|
4871
5189
|
private readonly _rtcCodec;
|
|
5190
|
+
/**
|
|
5191
|
+
* engine 内部日志工具
|
|
5192
|
+
*/
|
|
5193
|
+
readonly logger: BasicLogger;
|
|
4872
5194
|
constructor(_runtime: IRuntime, options: IAPIContextOption);
|
|
4873
5195
|
createCodec<T extends CodecPBMaps>(keymaps: T, pbDesc: string): Codec<T>;
|
|
4874
5196
|
/**
|
|
@@ -5570,6 +5892,7 @@ declare class APIContext {
|
|
|
5570
5892
|
getConversationListWithAllChannel(): Promise<IAsyncRes<IReceivedConversation[]>>;
|
|
5571
5893
|
getConversationListWithAllChannelByPage(index: number, limit: number): Promise<IAsyncRes<IReceivedConversation[]>>;
|
|
5572
5894
|
clearData(): Promise<IAsyncRes<boolean>>;
|
|
5895
|
+
createLogger(id: string, type: LogType): BasicLogger;
|
|
5573
5896
|
rtcSignaling(roomId: string, method: string, isQuery: boolean, sourceData: any): Promise<{
|
|
5574
5897
|
code: ErrorCode;
|
|
5575
5898
|
buffer?: Uint8Array;
|
|
@@ -5744,6 +6067,12 @@ declare class PluginContext {
|
|
|
5744
6067
|
key: string;
|
|
5745
6068
|
value: string;
|
|
5746
6069
|
}>;
|
|
6070
|
+
/**
|
|
6071
|
+
* 创建 logger 实例
|
|
6072
|
+
* @param id 日志工具 ID,用于区分日志实例,以确定日志调用者身份
|
|
6073
|
+
* @param type 目前仅支持 `IM` 与 `RTC` 两个值
|
|
6074
|
+
*/
|
|
6075
|
+
createLogger(id: string, type: LogType): BasicLogger;
|
|
5747
6076
|
}
|
|
5748
6077
|
|
|
5749
6078
|
declare class RTCPluginContext extends PluginContext {
|
|
@@ -5934,7 +6263,6 @@ declare class RTCPluginContext extends PluginContext {
|
|
|
5934
6263
|
onrtcdatachange?(data: IServerRTCRoomEntry[], roomdId?: string): void;
|
|
5935
6264
|
/**
|
|
5936
6265
|
* 获取加入 RTC 房间的用户信息(当前仅能查自己的)
|
|
5937
|
-
* @deprecated
|
|
5938
6266
|
*/
|
|
5939
6267
|
getRTCJoinedUserInfo(userId: string): IPromiseResult<IRTCJoinedInfo[]>;
|
|
5940
6268
|
}
|
|
@@ -5984,6 +6312,7 @@ declare abstract class AEngine implements IEngine {
|
|
|
5984
6312
|
readonly rtcCodec: Codec<RTCKeyMaps>;
|
|
5985
6313
|
protected readonly _watcher: IEngineWatcher;
|
|
5986
6314
|
protected readonly _options: IAPIContextOption;
|
|
6315
|
+
protected readonly logger: BasicLogger;
|
|
5987
6316
|
/**
|
|
5988
6317
|
* 连接时间
|
|
5989
6318
|
*/
|
|
@@ -5996,7 +6325,7 @@ declare abstract class AEngine implements IEngine {
|
|
|
5996
6325
|
* 引擎初始化
|
|
5997
6326
|
* @param _appkey
|
|
5998
6327
|
*/
|
|
5999
|
-
constructor(runtime: IRuntime, rtcCodec: Codec<RTCKeyMaps>, _watcher: IEngineWatcher, _options: IAPIContextOption);
|
|
6328
|
+
constructor(runtime: IRuntime, rtcCodec: Codec<RTCKeyMaps>, _watcher: IEngineWatcher, _options: IAPIContextOption, logger: BasicLogger);
|
|
6000
6329
|
protected _rtcSignalingListener?: (buffer: Uint8Array) => void;
|
|
6001
6330
|
/**
|
|
6002
6331
|
* 注册 RTC KV 变更监听器
|
|
@@ -6005,6 +6334,14 @@ declare abstract class AEngine implements IEngine {
|
|
|
6005
6334
|
registerRTCSignalingListener(listener: ((buffer: Uint8Array) => void) | undefined): void;
|
|
6006
6335
|
abstract requestNaviInfo(uris: string[], appkey: string, token: string, checkCA?: boolean): Promise<INaviInfo | null>;
|
|
6007
6336
|
abstract updateNaviInfo(naviInfo: INaviInfo): void;
|
|
6337
|
+
/**
|
|
6338
|
+
* 为非 engine 包创建 logger 工具实例
|
|
6339
|
+
*/
|
|
6340
|
+
abstract createLogger(id: string, type: LogType): BasicLogger;
|
|
6341
|
+
/**
|
|
6342
|
+
* 获取 engine 包内部 logger 工具
|
|
6343
|
+
*/
|
|
6344
|
+
getInnerLogger(): BasicLogger;
|
|
6008
6345
|
/**
|
|
6009
6346
|
* 获取导航数据
|
|
6010
6347
|
* @param token
|
|
@@ -6737,6 +7074,10 @@ declare abstract class AEngine implements IEngine {
|
|
|
6737
7074
|
* 接收 rtc 资源变更
|
|
6738
7075
|
*/
|
|
6739
7076
|
protected _receiveRtcKv(buffer: Uint8Array): void;
|
|
7077
|
+
/**
|
|
7078
|
+
* Engine 反初始化
|
|
7079
|
+
*/
|
|
7080
|
+
destroy(): void;
|
|
6740
7081
|
}
|
|
6741
7082
|
|
|
6742
7083
|
declare class AppStorage {
|
|
@@ -6894,8 +7235,8 @@ declare const isValidExpansion: (expansion: {
|
|
|
6894
7235
|
[key: string]: string;
|
|
6895
7236
|
} | undefined) => IIsValidExpansion;
|
|
6896
7237
|
|
|
6897
|
-
declare const sessionId: string;
|
|
6898
7238
|
/**
|
|
7239
|
+
* @deprecated
|
|
6899
7240
|
* logLevelTransformer
|
|
6900
7241
|
* @description 数据中心与前端日志规范LogLevel定义不统一
|
|
6901
7242
|
* WebLogLevel(前端日志级别) -> ServerLogLevel(服务器日志级别)
|
|
@@ -6904,40 +7245,40 @@ declare const sessionId: string;
|
|
|
6904
7245
|
*/
|
|
6905
7246
|
declare function logLevelTransformer(level: LogLevel): number;
|
|
6906
7247
|
/**
|
|
6907
|
-
*
|
|
6908
|
-
*
|
|
7248
|
+
* @deprecated
|
|
7249
|
+
* Trace ID 生成器
|
|
6909
7250
|
*/
|
|
6910
|
-
declare
|
|
6911
|
-
/**
|
|
6912
|
-
* 缓存日志
|
|
6913
|
-
* @param logLevel 打印等级
|
|
6914
|
-
* @param logObj 日志内容
|
|
6915
|
-
* @param tagId 日志tag
|
|
6916
|
-
*/
|
|
6917
|
-
declare function insertIntoLogCache(logLevel: LogLevel, tagId: string, logObj: any, logSource?: LogSource): ILogInfo;
|
|
7251
|
+
declare function ID(): string;
|
|
6918
7252
|
/**
|
|
6919
|
-
*
|
|
6920
|
-
* @param level
|
|
6921
|
-
* @param args
|
|
7253
|
+
* @deprecated
|
|
6922
7254
|
*/
|
|
6923
|
-
declare function
|
|
7255
|
+
declare function init(userLogInfo: ILogInit): void;
|
|
6924
7256
|
/**
|
|
6925
|
-
*
|
|
7257
|
+
* @deprecated
|
|
6926
7258
|
*/
|
|
6927
|
-
declare function ID(): string;
|
|
6928
|
-
declare function init(userLogInfo: ILogInit): void;
|
|
6929
7259
|
declare function log(logLevel: LogLevel, tagId: LogTagId | string, logObj?: Object, logExtens?: ILogExtensions): void;
|
|
7260
|
+
/**
|
|
7261
|
+
* @deprecated
|
|
7262
|
+
*/
|
|
6930
7263
|
declare const debug: (tagId: string, logObj?: Object | undefined, logExtens?: ILogExtensions | undefined) => void;
|
|
7264
|
+
/**
|
|
7265
|
+
* @deprecated
|
|
7266
|
+
*/
|
|
6931
7267
|
declare const info: (tagId: string, logObj?: Object | undefined, logExtens?: ILogExtensions | undefined) => void;
|
|
7268
|
+
/**
|
|
7269
|
+
* @deprecated
|
|
7270
|
+
*/
|
|
6932
7271
|
declare const warn: (tagId: string, logObj?: Object | undefined, logExtens?: ILogExtensions | undefined) => void;
|
|
7272
|
+
/**
|
|
7273
|
+
* @deprecated
|
|
7274
|
+
*/
|
|
6933
7275
|
declare const error: (tagId: string, logObj?: Object | undefined, logExtens?: ILogExtensions | undefined) => void;
|
|
7276
|
+
/**
|
|
7277
|
+
* @deprecated
|
|
7278
|
+
*/
|
|
6934
7279
|
declare const fatal: (tagId: string, logObj?: Object | undefined, logExtens?: ILogExtensions | undefined) => void;
|
|
6935
7280
|
|
|
6936
|
-
declare const base_sessionId: typeof sessionId;
|
|
6937
7281
|
declare const base_logLevelTransformer: typeof logLevelTransformer;
|
|
6938
|
-
declare const base_formatLogObj: typeof formatLogObj;
|
|
6939
|
-
declare const base_insertIntoLogCache: typeof insertIntoLogCache;
|
|
6940
|
-
declare const base__defaultStdout: typeof _defaultStdout;
|
|
6941
7282
|
declare const base_ID: typeof ID;
|
|
6942
7283
|
declare const base_init: typeof init;
|
|
6943
7284
|
declare const base_log: typeof log;
|
|
@@ -6948,11 +7289,7 @@ declare const base_error: typeof error;
|
|
|
6948
7289
|
declare const base_fatal: typeof fatal;
|
|
6949
7290
|
declare namespace base {
|
|
6950
7291
|
export {
|
|
6951
|
-
base_sessionId as sessionId,
|
|
6952
7292
|
base_logLevelTransformer as logLevelTransformer,
|
|
6953
|
-
base_formatLogObj as formatLogObj,
|
|
6954
|
-
base_insertIntoLogCache as insertIntoLogCache,
|
|
6955
|
-
base__defaultStdout as _defaultStdout,
|
|
6956
7293
|
base_ID as ID,
|
|
6957
7294
|
base_init as init,
|
|
6958
7295
|
base_log as log,
|
|
@@ -6964,18 +7301,8 @@ declare namespace base {
|
|
|
6964
7301
|
};
|
|
6965
7302
|
}
|
|
6966
7303
|
|
|
6967
|
-
/** *********************实时日志上报***************** */
|
|
6968
|
-
|
|
6969
7304
|
/**
|
|
6970
7305
|
* @deprecated
|
|
6971
|
-
* 缓存日志实时
|
|
6972
|
-
* @param {LogLevel} logLevel 日志等级
|
|
6973
|
-
* @param tagId 日志标签
|
|
6974
|
-
* @param content 日志内容
|
|
6975
|
-
*/
|
|
6976
|
-
declare function reportLog(logLevel: LogLevel, tagId: string, content: string, logSource?: LogSource): void;
|
|
6977
|
-
|
|
6978
|
-
/**
|
|
6979
7306
|
* @description 兼容旧版用法,建议用Logger静态方法
|
|
6980
7307
|
* 1、不符合新版Web日志规范
|
|
6981
7308
|
* 2、不支持自定义TagId
|
|
@@ -6993,31 +7320,39 @@ declare class Logger {
|
|
|
6993
7320
|
*/
|
|
6994
7321
|
constructor(tagId: string, logSource?: LogSource | undefined, initiator?: string | undefined);
|
|
6995
7322
|
/**
|
|
6996
|
-
*
|
|
6997
|
-
*/
|
|
6998
|
-
private _localLogLevel;
|
|
6999
|
-
/**
|
|
7000
|
-
* 自定义本地日志输出函数
|
|
7001
|
-
*/
|
|
7002
|
-
private _customLogPrint?;
|
|
7003
|
-
/**
|
|
7004
|
-
* 为向前兼容,暂不删除
|
|
7005
|
-
*/
|
|
7006
|
-
private _stdout?;
|
|
7007
|
-
/**
|
|
7323
|
+
* @deprecated
|
|
7008
7324
|
* 自定义本地打印日志级别
|
|
7009
7325
|
* @param logLevel
|
|
7010
7326
|
*/
|
|
7011
7327
|
setLogLevel(logLevel?: LogLevel): void;
|
|
7012
7328
|
/**
|
|
7329
|
+
* @deprecated
|
|
7013
7330
|
* 自定义本地打印函数
|
|
7014
7331
|
*/
|
|
7015
7332
|
setLogStdout(stdout?: (level: LogLevel, content: string) => void): void;
|
|
7016
|
-
|
|
7333
|
+
/**
|
|
7334
|
+
* @deprecated
|
|
7335
|
+
*/
|
|
7336
|
+
private log;
|
|
7337
|
+
/**
|
|
7338
|
+
* @deprecated
|
|
7339
|
+
*/
|
|
7017
7340
|
debug: (...args: any[]) => void;
|
|
7341
|
+
/**
|
|
7342
|
+
* @deprecated
|
|
7343
|
+
*/
|
|
7018
7344
|
info: (...args: any[]) => void;
|
|
7345
|
+
/**
|
|
7346
|
+
* @deprecated
|
|
7347
|
+
*/
|
|
7019
7348
|
warn: (...args: any[]) => void;
|
|
7349
|
+
/**
|
|
7350
|
+
* @deprecated
|
|
7351
|
+
*/
|
|
7020
7352
|
error: (...args: any[]) => void;
|
|
7353
|
+
/**
|
|
7354
|
+
* @deprecated
|
|
7355
|
+
*/
|
|
7021
7356
|
fatal: (...args: any[]) => void;
|
|
7022
7357
|
/**
|
|
7023
7358
|
* @deprecated
|
|
@@ -7030,9 +7365,11 @@ declare class Logger {
|
|
|
7030
7365
|
* @deprecated
|
|
7031
7366
|
*/
|
|
7032
7367
|
setStdout(stdout?: (level: LogLevel, msgTag: string, ...args: any[]) => void): void;
|
|
7033
|
-
reportLog: typeof reportLog;
|
|
7034
7368
|
}
|
|
7035
|
-
|
|
7369
|
+
/**
|
|
7370
|
+
* @deprecated
|
|
7371
|
+
*/
|
|
7372
|
+
declare const logger: Logger;
|
|
7036
7373
|
|
|
7037
7374
|
declare const getUUID: () => string;
|
|
7038
7375
|
declare const getUUID22: () => string;
|
|
@@ -7106,10 +7443,6 @@ declare const assert: (key: string, value: any, validator: AssertRules | ((value
|
|
|
7106
7443
|
*/
|
|
7107
7444
|
declare const validate: (key: string, value: any, validator: AssertRules | ((value?: any) => boolean), required?: boolean) => boolean;
|
|
7108
7445
|
|
|
7109
|
-
/**
|
|
7110
|
-
* engine 层业务相关工具方法
|
|
7111
|
-
*/
|
|
7112
|
-
|
|
7113
7446
|
/**
|
|
7114
7447
|
* 通过文件类型生成上传唯一文件名
|
|
7115
7448
|
*/
|
|
@@ -7128,7 +7461,7 @@ declare const pushConfigsToJSON: (iOSConfig?: IiOSPushConfig, androidConfig?: IA
|
|
|
7128
7461
|
* 将服务端返回的 push 信息格式化
|
|
7129
7462
|
* @param pushStr
|
|
7130
7463
|
*/
|
|
7131
|
-
declare const pushJSONToConfigs: (pushStr: string, pushId: string) => {
|
|
7464
|
+
declare const pushJSONToConfigs: (logger: BasicLogger, pushStr: string, pushId: string) => {
|
|
7132
7465
|
iOSConfig: IiOSPushConfig;
|
|
7133
7466
|
androidConfig: IAndroidPushConfig;
|
|
7134
7467
|
};
|
|
@@ -7286,4 +7619,4 @@ declare type AbsCodec<T> = Codec<T>;
|
|
|
7286
7619
|
*/
|
|
7287
7620
|
declare const version: string;
|
|
7288
7621
|
|
|
7289
|
-
export { AEngine, APIContext, AbsCodec, AppStorage, AssertRules, CPP_PROTOCAL_MSGTYPE_OPTION, CallLibMsgType, ChatroomEntryType, ChatroomUserChangeType, Codec, CodecPBMaps, ConnectResultCode, ConnectionStatus, ConversationType, DB_LOG_FLUSH_FREQUENCY, DB_LOG_MAX_SIZE, DelayTimer, ErrorCode, EventEmitter, FileType, HTTP_TIMEOUT, HttpMethod, IAPIContextOption, IAndroidPushConfig, IAsyncRes, IBaseConversationInfo, IBigdataLogInit, IBlockedMessageInfo, ICancelRoomPKOptions, IChatRoomEntries, IChatRoomEntry, IChatroomEntries, IChatroomEntry, IChatroomEntryListenerData, IChatroomInfo, IChatroomListener, IChatroomListenerData, IChatroomRejoinedFailed, IChatroomRejoinedInfo, IChatroomRejoinedSuccessed, IChatroomUser, IChatroomUserChangeInfo, IChrmKVEntries, IChrmKVEntry, IConnectResult, IConnectionStatusListener, IConversationOption, IConversationState, IConversationStateListener, IConversationTag, IConversationTagListener, IDeletedExpansion, IDeliveredUser, IEndRoomPKOptions, IEngine, IEngineWatcher, IEventListener, IExpansionListener, IExpansionListenerData, IExpansionMsgContent, IExtraMethod, IGetMsgOption, IGetUltraGroupListOption, IGooglePushConfig, IGroupMessageDeliverInfo, IGroupMessageDeliverStatus, IInitBigDataOption, IInsertMsgOptions, IIsValidExpansion, IJoinRTCRoomData, ILocalReadReceiptInfo, ILocalTagStatus, ILogExtensions, ILogInfo, ILogInit, IM_CHATROOM_PULL_INTERVAL_TIME, IM_PING_INTERVAL_TIME, IM_PING_MIN_TIMEOUT, IM_PING_TIMEOUT, IM_SIGNAL_TIMEOUT, IMessageDeliver, IMessageDeliveredListener, IMessageListnenr, IMessageReader, IMessageReaderResponse, IMetionedData, INaviInfo, IOSInfo, IOperateStatusNotify, IPluginGenerator, IProcessInfo, IPromiseResult, IPushConfig, IRTCInnerListener, IRTCJoinedInfo, IRTCRoomBindOption, IRTCRoomInfo, IRTCUserData, IRTCUsers, IReadReceiptInfo, IRealTimeLog, IRecallMsgContent, IRecallMsgOptions, IReceivedConversation, IReceivedConversationByTag, IReceivedMessage, IRemoveChatRoomEntries, IRemoveChatRoomEntry, IRemoveChatroomEntries, IRemoveChatroomEntry, IReqRoomPKOptions, IRequest, IResRoomPKOptions, IResponse, IRtcTokenData, IRuntime, ISendExMsgOptions, ISendMsgOptions, IServerConversationStatus, IServerRTCRoomEntry, IServerUserSetting, ISetConversationStatusOptions, IStorage, ITagInfo, ITagListener, ITagParam, ITagStatus, ITypingInfo, ITypingMessage, ITypingUser, IUltraChannelChangeInfo, IUltraChannelDeleteInfo, IUltraChannelUserKickedInfo, IUltraExMsgOptions, IUltraGroupConversation, IUltraGroupOption, IUltraGroupUnreadMentionedOption, IUltraModifyMsgOptions, IUltraMsgQueryOptions, IUltraUnreadConversation, IUltraUnreadMsg, IUpdatedConversation, IUpdatedExpansion, IUploadAuth, IUserProfile, IWatcher, IWebSocket, IiOSPushConfig, RTCKeyMaps as InnerRTCKeyMaps, ItypingStateListener, KVString, LOG_REPORT_URI, LiveRole, LiveType, LogLevel, LogSource, LogTagId, Logger, MAX_MESSAGE_CONTENT_BYTES, MAX_MESSAGE_EXPANSION_KEY_LENGTH, MAX_MESSAGE_EXPANSION_VAL_LENGTH, MINI_SOCKET_CONNECT_URIS, MentionedType, MessageBlockSourceType, MessageBlockType, MessageDirection, MessageType, NAVI_CACHE_DURATION, NAVI_REQ_TIMEOUT, NetworkType, NotificationLevel, NotificationStatus, ONE_LOG_SIZE_MAX, OperateStatus, PUBLIC_CLOUD_NAVI_URIS, PluginContext, RCAssertError, REAT_TIME_LOG_SIZE, RTCApiType, RTCIdentityChangeType, RTCJoinType, RTCMode, RTCPluginContext, ReceivedStatus, SEND_MESSAGE_TYPE_OPTION, STATUS_MESSAGE, STORAGE_ROOT_KEY, TagChangeType, UltraGroupChannelChangeType, UltraGroupChannelType, UltraMsgChangeType, UltraMsgSubChangeType, UploadMethod, VersionManage, WEB_SOCKET_TIMEOUT, WebSocketChannel, appendUrl, assert, clone, cloneByJSON,
|
|
7622
|
+
export { AEngine, APIContext, AbsCodec, AppStorage, AssertRules, BasicLogger, BasicReporter, CPP_PROTOCAL_MSGTYPE_OPTION, CallLibMsgType, ChatroomEntryType, ChatroomUserChangeType, Codec, CodecPBMaps, ConnectResultCode, ConnectionStatus, ConversationType, DB_LOG_FLUSH_FREQUENCY, DB_LOG_MAX_SIZE, DelayTimer, EnableLogL, ErrorCode, EventEmitter, FileType, HTTP_TIMEOUT, HttpMethod, IAPIContextOption, IAndroidPushConfig, IAsyncRes, IBaseConversationInfo, IBigdataLogInit, IBlockedMessageInfo, ICancelRoomPKOptions, IChatRoomEntries, IChatRoomEntry, IChatroomEntries, IChatroomEntry, IChatroomEntryListenerData, IChatroomInfo, IChatroomListener, IChatroomListenerData, IChatroomRejoinedFailed, IChatroomRejoinedInfo, IChatroomRejoinedSuccessed, IChatroomUser, IChatroomUserChangeInfo, IChrmKVEntries, IChrmKVEntry, IConnectResult, IConnectionStatusListener, IConversationOption, IConversationState, IConversationStateListener, IConversationTag, IConversationTagListener, IDeletedExpansion, IDeliveredUser, IEndRoomPKOptions, IEngine, IEngineWatcher, IEventListener, IExpansionListener, IExpansionListenerData, IExpansionMsgContent, IExtraMethod, IGetMsgOption, IGetUltraGroupListOption, IGooglePushConfig, IGroupMessageDeliverInfo, IGroupMessageDeliverStatus, IInitBigDataOption, IInsertMsgOptions, IIsValidExpansion, IJoinRTCRoomData, ILocalReadReceiptInfo, ILocalTagStatus, ILogDB, ILogData, ILogExtensions, ILogInfo, ILogInit, ILogger, IM_CHATROOM_PULL_INTERVAL_TIME, IM_PING_INTERVAL_TIME, IM_PING_MIN_TIMEOUT, IM_PING_TIMEOUT, IM_SIGNAL_TIMEOUT, IMessageDeliver, IMessageDeliveredListener, IMessageListnenr, IMessageReader, IMessageReaderResponse, IMetionedData, INaviInfo, IOSInfo, IOperateStatusNotify, IPluginGenerator, IProcessInfo, IPromiseResult, IPushConfig, IRTCInnerListener, IRTCJoinedInfo, IRTCRoomBindOption, IRTCRoomInfo, IRTCUserData, IRTCUsers, IReadReceiptInfo, IRealTimeLog, IRecallMsgContent, IRecallMsgOptions, IReceivedConversation, IReceivedConversationByTag, IReceivedMessage, IRemoveChatRoomEntries, IRemoveChatRoomEntry, IRemoveChatroomEntries, IRemoveChatroomEntry, IReqRoomPKOptions, IRequest, IResRoomPKOptions, IResponse, IRtcTokenData, IRuntime, ISendExMsgOptions, ISendMsgOptions, IServerConversationStatus, IServerRTCRoomEntry, IServerUserSetting, ISetConversationStatusOptions, IStorage, ITagInfo, ITagListener, ITagParam, ITagStatus, ITypingInfo, ITypingMessage, ITypingUser, IUltraChannelChangeInfo, IUltraChannelDeleteInfo, IUltraChannelUserKickedInfo, IUltraExMsgOptions, IUltraGroupConversation, IUltraGroupOption, IUltraGroupUnreadMentionedOption, IUltraModifyMsgOptions, IUltraMsgQueryOptions, IUltraUnreadConversation, IUltraUnreadMsg, IUpdatedConversation, IUpdatedExpansion, IUploadAuth, IUserProfile, IWatcher, IWebSocket, IiOSPushConfig, IndexDBLogger, IndexDBReporter, RTCKeyMaps as InnerRTCKeyMaps, ItypingStateListener, KVString, LOG_REPORT_URI, LiveRole, LiveType, LogContent, LogL, LogLevel, LogSource, LogTagId, LogType, Logger, MAX_MESSAGE_CONTENT_BYTES, MAX_MESSAGE_EXPANSION_KEY_LENGTH, MAX_MESSAGE_EXPANSION_VAL_LENGTH, MINI_SOCKET_CONNECT_URIS, MentionedType, MessageBlockSourceType, MessageBlockType, MessageDirection, MessageType, NAVI_CACHE_DURATION, NAVI_REQ_TIMEOUT, NetworkType, NotificationLevel, NotificationStatus, ONE_LOG_SIZE_MAX, OperateStatus, PUBLIC_CLOUD_NAVI_URIS, PluginContext, RCAssertError, REAT_TIME_LOG_SIZE, RTCApiType, RTCIdentityChangeType, RTCJoinType, RTCMode, RTCPluginContext, ReceivedStatus, SEND_MESSAGE_TYPE_OPTION, STATUS_MESSAGE, STORAGE_ROOT_KEY, StoreKeys, TagChangeType, UltraGroupChannelChangeType, UltraGroupChannelType, UltraMsgChangeType, UltraMsgSubChangeType, UploadMethod, VersionManage, WEB_SOCKET_TIMEOUT, WebSocketChannel, appendUrl, assert, clone, cloneByJSON, deInitLogDB, logger as engineLogger, forEach, formatConnectResponseCode, getBrowser, getClientMessageId, getMimeKey, getUUID, getUUID22, getUploadFileName, indexOf, initLogDB, isArray, isArrayBuffer, isBoolean, isFunction, isHttpUrl, isInObject, isInclude, isNull, isNumber, isObject, isString, isUndefined, isValidChannelId, isValidChrmEntryKey, isValidChrmEntryValue, isValidConversationType, isValidExpansion, isValidFileType, isValidNotificationLevel, base as logger, map, notEmptyArray, notEmptyObject, notEmptyString, pushConfigsToJSON, pushJSONToConfigs, todo, usingCppEngine, validate, version };
|