dolphindb 3.1.32 → 3.1.34
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/browser.d.ts +4 -0
- package/browser.js +10 -3
- package/browser.js.map +1 -1
- package/common.d.ts +2 -1
- package/common.js +1 -0
- package/common.js.map +1 -1
- package/index.d.ts +4 -0
- package/index.js +10 -3
- package/index.js.map +1 -1
- package/package.json +1 -1
package/browser.d.ts
CHANGED
|
@@ -44,6 +44,7 @@ export interface DdbChartValue {
|
|
|
44
44
|
chart: string;
|
|
45
45
|
x_axis: string;
|
|
46
46
|
y_axis: string;
|
|
47
|
+
z_axis?: string;
|
|
47
48
|
};
|
|
48
49
|
extras?: {
|
|
49
50
|
multi_y_axes: boolean;
|
|
@@ -616,6 +617,9 @@ export declare class DDB {
|
|
|
616
617
|
define(definition: string, { urgent }?: {
|
|
617
618
|
urgent?: boolean;
|
|
618
619
|
}): Promise<string>;
|
|
620
|
+
/** 在 undef all, 或运行 test 函数之后,由于函数定义在 server 侧被清空,需要同步清空 api 侧缓存,
|
|
621
|
+
使得下次调用 invoke, define 能够重新定义函数 */
|
|
622
|
+
reset_definitions(): void;
|
|
619
623
|
}
|
|
620
624
|
export interface DdbMessageListener {
|
|
621
625
|
(message: DdbMessage, _this: DDB): any;
|
package/browser.js
CHANGED
|
@@ -159,7 +159,7 @@ export class DdbObj {
|
|
|
159
159
|
return dict;
|
|
160
160
|
else {
|
|
161
161
|
const { chartType: type, stacking, binStart: bin_start, binEnd: bin_end, binCount: bin_count, title: titles, extras, data, ...others } = dict.to_dict();
|
|
162
|
-
const [chart, x_axis, y_axis] = titles.value;
|
|
162
|
+
const [chart, x_axis, y_axis, z_axis] = titles.value;
|
|
163
163
|
dict.form = DdbForm.chart;
|
|
164
164
|
dict.value = {
|
|
165
165
|
type: type.value,
|
|
@@ -168,6 +168,7 @@ export class DdbObj {
|
|
|
168
168
|
chart,
|
|
169
169
|
x_axis,
|
|
170
170
|
y_axis,
|
|
171
|
+
z_axis
|
|
171
172
|
},
|
|
172
173
|
...bin_start ? { bin_start, bin_end, } : {},
|
|
173
174
|
...bin_count ? { bin_count } : {},
|
|
@@ -948,13 +949,13 @@ export class DdbObj {
|
|
|
948
949
|
case DdbForm.dict:
|
|
949
950
|
return [value[0].pack(), value[1].pack()];
|
|
950
951
|
case DdbForm.chart: {
|
|
951
|
-
const { type, stacking, bin_start, bin_end, bin_count, titles: { chart, x_axis, y_axis }, extras, data } = this.value;
|
|
952
|
+
const { type, stacking, bin_start, bin_end, bin_count, titles: { chart, x_axis, y_axis, z_axis }, extras, data } = this.value;
|
|
952
953
|
const { value: [keys, values] } = new DdbDict({
|
|
953
954
|
chartType: new DdbInt(type),
|
|
954
955
|
stacking,
|
|
955
956
|
...bin_start ? { binStart: bin_start, binEnd: bin_end } : {},
|
|
956
957
|
...bin_count ? { binCount: bin_count } : {},
|
|
957
|
-
title: new DdbVectorString([chart, x_axis, y_axis]),
|
|
958
|
+
title: new DdbVectorString([chart, x_axis, y_axis, z_axis]),
|
|
958
959
|
...extras ? (() => {
|
|
959
960
|
const { multi_y_axes, ...extras_other } = extras;
|
|
960
961
|
return { extras: new DdbDict({ multiYAxes: multi_y_axes, ...extras_other }) };
|
|
@@ -3140,6 +3141,12 @@ export class DDB {
|
|
|
3140
3141
|
this.pdefinitions.delete(func_name);
|
|
3141
3142
|
return func_name;
|
|
3142
3143
|
}
|
|
3144
|
+
/** 在 undef all, 或运行 test 函数之后,由于函数定义在 server 侧被清空,需要同步清空 api 侧缓存,
|
|
3145
|
+
使得下次调用 invoke, define 能够重新定义函数 */
|
|
3146
|
+
reset_definitions() {
|
|
3147
|
+
this.definitions.clear();
|
|
3148
|
+
this.pdefinitions.clear();
|
|
3149
|
+
}
|
|
3143
3150
|
}
|
|
3144
3151
|
/** https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/SharedArrayBuffer#security_requirements
|
|
3145
3152
|
SharedArrayBuffer is disabled by default in most browsers as a security precaution to avoid Spectre attacks.
|