dolphindb 3.0.27 → 3.0.29

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 CHANGED
@@ -515,6 +515,8 @@ export interface StreamingMessage<TRows = any> extends StreamingParams {
515
515
  rows: number;
516
516
  /** 每次接收到的 data 组成的数组 An array of data received each time */
517
517
  segments: DdbTableData<TRows>[];
518
+ /** 每次接收到的 obj 组成的数组 An array of obj received each time */
519
+ objs: DdbObj<DdbVectorObj[]>[];
518
520
  };
519
521
  /** 成功订阅后,后续推送过来的 message 解析错误,则会设置 error 并调用 handler
520
522
  After successfully subscribed, if the subsequently pushed message is parsed incorrectly, the error will be set and the handler will be called. */
package/index.js CHANGED
@@ -3044,6 +3044,7 @@ export class DDB {
3044
3044
  offset: 0,
3045
3045
  rows: 0,
3046
3046
  segments: [],
3047
+ objs: []
3047
3048
  };
3048
3049
  let schema;
3049
3050
  console.log(t('订阅流表成功:'),
@@ -3089,6 +3090,7 @@ export class DDB {
3089
3090
  };
3090
3091
  win.rows += rows;
3091
3092
  win.segments.push(data);
3093
+ win.objs.push(obj);
3092
3094
  if (win.rows >= winsize * 2 && win.segments.length >= 2) {
3093
3095
  let winsize_ = 0;
3094
3096
  let i = win.segments.length - 1;
@@ -3096,6 +3098,7 @@ export class DDB {
3096
3098
  for (; winsize_ < winsize; i--)
3097
3099
  winsize_ += win.segments[i].data.length;
3098
3100
  win.segments = win.segments.slice(i);
3101
+ win.objs = win.objs.slice(i);
3099
3102
  win.offset += win.rows - winsize_;
3100
3103
  win.rows = winsize_;
3101
3104
  }