dolphindb 3.0.212 → 3.0.214

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 CHANGED
@@ -419,7 +419,7 @@ export interface ConvertOptions {
419
419
  /** `'ms'` timestamp 类型转换为字符串表示时显示到秒还是毫秒 */
420
420
  timestamp?: 's' | 'ms';
421
421
  }
422
- export declare function convert(type: DdbType, value: DdbValue, le: boolean, { blob, char, timestamp }?: ConvertOptions): string | number | bigint | boolean | number[] | Uint8Array<ArrayBufferLike> | DdbFunctionDefValue | DdbDurationValue | DdbDecimal32Value | DdbDecimal64Value | Int8Array<ArrayBufferLike> | Int16Array<ArrayBufferLike> | Int32Array<ArrayBufferLike> | Float32Array<ArrayBufferLike> | Float64Array<ArrayBufferLike> | BigInt64Array<ArrayBufferLike> | BigInt128Array | string[] | Uint8Array<ArrayBufferLike>[] | DdbObj<DdbValue>[] | IotVectorItemValue | DdbSymbolExtendedValue | DdbArrayVectorValue | DdbDecimal32VectorValue | DdbDecimal64VectorValue | DdbDecimal128VectorValue | DdbDurationVectorValue | DdbMatrixValue | DdbChartValue | DdbTensorValue;
422
+ export declare function convert(type: DdbType, value: DdbValue, le: boolean, { blob, char, timestamp }?: ConvertOptions): string | number | bigint | boolean | DdbFunctionDefValue | DdbDurationValue | DdbDecimal32Value | DdbDecimal64Value | DdbDecimal32VectorValue | DdbDecimal64VectorValue | DdbDecimal128VectorValue | BigInt128Array | DdbSymbolExtendedValue | string[] | DdbArrayVectorValue | DdbMatrixValue | Uint8Array<ArrayBufferLike> | Int8Array<ArrayBufferLike> | Int16Array<ArrayBufferLike> | Int32Array<ArrayBufferLike> | Float32Array<ArrayBufferLike> | Float64Array<ArrayBufferLike> | BigInt64Array<ArrayBufferLike> | Uint8Array<ArrayBufferLike>[] | DdbObj<DdbValue>[] | IotVectorItemValue | DdbDurationVectorValue | number[] | DdbTensorValue | DdbChartValue;
423
423
  /** 转换一个向量到 js 原生数组 */
424
424
  export declare function converts(type: DdbType, value: DdbVectorValue, rows: number, le: boolean, options?: ConvertOptions): any[] | Uint8Array;
425
425
  /** 构造 void 类型,默认为 `DdbVoidType.undefined` */
@@ -483,6 +483,9 @@ export declare class DdbVectorAny extends DdbObj {
483
483
  export declare class DdbVectorSymbol extends DdbObj<DdbSymbolExtendedValue> {
484
484
  constructor(strings: string[], name?: string);
485
485
  }
486
+ export declare class DdbVectorChar extends DdbObj<Int8Array> {
487
+ constructor(chars?: Uint8Array | Int8Array | ArrayBuffer, name?: string);
488
+ }
486
489
  export declare class DdbSetInt extends DdbObj<Int32Array> {
487
490
  constructor(ints: (number | null)[] | Set<number> | Int32Array);
488
491
  }
package/browser.js CHANGED
@@ -2421,6 +2421,29 @@ export class DdbVectorSymbol extends DdbObj {
2421
2421
  });
2422
2422
  }
2423
2423
  }
2424
+ export class DdbVectorChar extends DdbObj {
2425
+ constructor(chars, name) {
2426
+ let ints;
2427
+ if (!chars)
2428
+ ints = new Int8Array();
2429
+ else if (chars instanceof ArrayBuffer)
2430
+ ints = new Int8Array(chars);
2431
+ else if (chars instanceof Uint8Array)
2432
+ ints = new Int8Array(chars.buffer, chars.byteOffset, chars.byteLength);
2433
+ else {
2434
+ check(chars instanceof Int8Array);
2435
+ ints = chars;
2436
+ }
2437
+ super({
2438
+ form: DdbForm.vector,
2439
+ type: DdbType.char,
2440
+ rows: ints.length,
2441
+ cols: 1,
2442
+ value: ints,
2443
+ name
2444
+ });
2445
+ }
2446
+ }
2424
2447
  export class DdbSetInt extends DdbObj {
2425
2448
  constructor(ints) {
2426
2449
  super({