dolphindb 2.0.958 → 2.0.960

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/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "dolphindb",
3
3
  "description": "DolphinDB JavaScript API",
4
- "version": "2.0.958",
4
+ "version": "2.0.960",
5
5
  "type": "module",
6
6
  "main": "./index.js",
7
7
  "browser": "./browser.js",
@@ -25,10 +25,10 @@
25
25
  "JavaScript"
26
26
  ],
27
27
  "devDependencies": {
28
- "@types/node": "^18.15.11",
29
- "@typescript-eslint/eslint-plugin": "^5.58.0",
30
- "@typescript-eslint/parser": "^5.58.0",
31
- "eslint": "^8.38.0",
28
+ "@types/node": "^20.1.0",
29
+ "@typescript-eslint/eslint-plugin": "^5.59.2",
30
+ "@typescript-eslint/parser": "^5.59.2",
31
+ "eslint": "^8.40.0",
32
32
  "typescript": "^5.0.4"
33
33
  },
34
34
  "dependencies": {
@@ -39,8 +39,9 @@
39
39
  },
40
40
  "scripts": {
41
41
  "build": "tsc",
42
- "test": "tsc && node ./test/index.js",
42
+ "test": "tsc && node ./test.js",
43
43
  "lint": "eslint \"**/*.{ts,tsx}\"",
44
- "fix": "eslint --fix \"**/*.{ts,tsx}\""
44
+ "fix": "eslint --fix \"**/*.{ts,tsx}\"",
45
+ "scan": "i18n-scan --input \"**/*.{ts,tsx}\""
45
46
  }
46
47
  }
package/test.d.ts CHANGED
@@ -1,3 +1,3 @@
1
1
  import { DDB } from './index.js';
2
- export declare const url: "ws://115.239.209.123:8892";
2
+ export declare const url: "ws://192.168.0.29:9002";
3
3
  export declare function test_types(ddb: DDB): Promise<void>;
package/test.js CHANGED
@@ -1,9 +1,11 @@
1
1
  import { assert, inspect, set_inspect_options, WebSocketConnectionError } from 'xshell';
2
2
  import { keywords } from './language.js';
3
- import { DDB, DdbConnectionError, DdbDatabaseError, DdbForm, DdbInt, DdbLong, DdbObj, DdbType, DdbVectorAny, DdbVectorDouble, DdbVectorSymbol, month2ms } from './index.js';
3
+ import { DDB, DdbConnectionError, DdbDatabaseError, DdbForm, DdbInt, DdbLong, DdbObj, DdbType, DdbVectorAny, DdbVectorDouble, DdbVectorSymbol, month2ms, DdbDurationUnit } from './index.js';
4
4
  set_inspect_options();
5
5
  // linux
6
- export const url = 'ws://115.239.209.123:8892';
6
+ // export const url = 'ws://115.239.209.123:8892' as const
7
+ // export const url = 'ws://192.168.0.16:20002' as const
8
+ export const url = 'ws://192.168.0.29:9002';
7
9
  (async function test() {
8
10
  console.log('--- 测试开始 ---'.green);
9
11
  let ddb = new DDB(url);
@@ -248,5 +250,18 @@ export async function test_types(ddb) {
248
250
  assert(value === 'DataSource< select [7] * from tb where id == 1 >');
249
251
  // 如果直接构造 DdbObj Datasource,将其送入 ddb.call, ddb将仍然认为送入的是一个 STRING
250
252
  assert((await ddb.call('typestr', [ds])).value === 'STRING', '从 js 构建的 Datasource DdbObj 会被识别为 STRING');
253
+ console.log('测试 pair<duration>');
254
+ const dp = await ddb.eval('pair(duration("20d"), duration("2H"))');
255
+ console.log(dp);
256
+ assert(dp.type === DdbType.duration, 'dp 的返回值应该为 Duration');
257
+ assert(dp.value[0].data === 20 && dp.value[0].unit === DdbDurationUnit.d, 'pair<duration> 的 value 应该已解析');
258
+ console.log('测试 void vector');
259
+ const table = await ddb.eval('select *, NULL as val from table(1..100 as id)');
260
+ const { value: [ints, voids] } = table;
261
+ console.log(voids);
262
+ assert(voids.rows === ints.rows, 'void vector 应该具有正常的 vector length');
263
+ assert(voids.length === 10, 'void vector 应该具有正确的数据长度');
264
+ assert(voids.value === null, 'void vector 的值应该为 null');
265
+ await ddb.upload(['voidtable'], [table]);
251
266
  }
252
267
  //# sourceMappingURL=test.js.map
package/test.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"test.js","sourceRoot":"","sources":["test.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,OAAO,EAAE,mBAAmB,EAAE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;IAEF,MAAM,GAAG,CAAC,MAAM,CAAC,CAAC,GAAG,CAAC,EAAE;QACpB,IAAI,MAAM,CAAC;YACP,IAAI,EAAE,OAAO,CAAC,MAAM;YACpB,IAAI,EAAE,OAAO,CAAC,MAAM;YACpB,MAAM,EAAE,CAAC;YACT,IAAI,EAAE,MAAM,CAAC,MAAM;YACnB,IAAI,EAAE,CAAC;YACP,KAAK,EAAE,MAAM;SAChB,CAAC;KACL,CAAC,CAAA;IAEF,MAAM,CAAC,CACH,MAAM,GAAG,CAAC,IAAI,CAAkB,GAAG,CAAC,CACvC,CAAC,IAAI,KAAK,MAAM,CAAC,MAAM,CAAC,CAAA;IAGzB,OAAO,CAAC,GAAG,CAAC,eAAe,CAAC,CAAA;IAE5B,MAAM,EAAE,GAAG,CAAC,MAAM,GAAG,CAAC,IAAI,CACtB,qCAAqC;QACrC,kBAAkB;QAClB,uCAAuC;QACvC,oBAAoB;QACpB,2CAA2C;QAC3C,+CAA+C;QAC/C,mBAAmB;QACnB,uDAAuD;QACvD,IAAI;QACJ,oCAAoC;QACpC,0CAA0C,CAC7C,CAAC,CAAC,KAAK,CAAC,CAAC,CAAiB,CAAA;IAE3B,MAAM,EAAE,IAAI,EAAE,IAAI,EAAE,KAAK,EAAE,GAAG,EAAE,CAAA;IAEhC,MAAM,CAAC,IAAI,KAAK,OAAO,CAAC,UAAU,IAAI,IAAI,KAAK,OAAO,CAAC,MAAM,EAAE,8BAA8B,CAAC,CAAA;IAE9F,MAAM,CAAC,KAAK,KAAK,kDAAkD,CAAC,CAAA;IAEpE,iEAAiE;IACjE,MAAM,CACF,CAAC,MAAM,GAAG,CAAC,IAAI,CAAe,SAAS,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,KAAK,KAAK,QAAQ,EAClE,yCAAyC,CAC5C,CAAA;AACL,CAAC","sourcesContent":["import { assert, inspect, set_inspect_options, WebSocketConnectionError } from 'xshell'\n\nimport { keywords } from './language.js'\nimport { DDB, DdbConnectionError, DdbDatabaseError, DdbForm, DdbInt, DdbLong, DdbObj, DdbType, DdbVectorAny, DdbVectorDouble, DdbVectorSymbol, month2ms, type DdbStringObj, type DdbVectorAnyObj } from './index.js'\n\n\nset_inspect_options()\n\n\n// linux\nexport const url = 'ws://115.239.209.123:8892' as const\n// export const url = 'ws://192.168.0.16:20002' as const\n\n// windows\n// export const url = 'ws://192.168.0.29:9002' as const\n\n// local 8848\n// export const url = 'ws://127.0.0.1:8848' as const\n\n\n;(async function test () {\n console.log('--- 测试开始 ---'.green)\n \n let ddb = new DDB(url)\n \n const tests = [\n test_repl,\n \n test_keywords,\n test_types,\n test_reconnection,\n test_print,\n test_time,\n test_streaming,\n test_error,\n ]\n \n for (const fn_test of tests)\n await fn_test(ddb)\n \n ddb.disconnect()\n \n console.log('--- 测试通过 ---'.green)\n})()\n\n\n\nfunction test_keywords () {\n assert(new Set(keywords).size === keywords.length, 'keywords 中不能有重复的项')\n}\n\n\nasync function get_printed (ddb: DDB, code: string) {\n return new Promise<string>(async (resolve, reject) => {\n try {\n let resolved = false\n await ddb.eval(\n `print(${code})`,\n {\n listener ({ type, data }) {\n if (type === 'print' && !resolved) {\n resolved = true\n resolve(data)\n }\n }\n }\n )\n if (!resolved)\n reject(new Error('未输出 print 消息'))\n } catch (error) {\n reject(error)\n }\n })\n}\n\n\nasync function test_repl (ddb: DDB) {\n \n}\n\n\nasync function test_reconnection (ddb: DDB) {\n let _ddb = new DDB(url)\n \n await _ddb.connect()\n _ddb.disconnect()\n \n let error: DdbConnectionError\n \n try {\n await _ddb.connect()\n } catch (_error) {\n error = _error\n }\n \n assert(error && error instanceof DdbConnectionError)\n}\n\n\nasync function test_error (ddb: DDB) {\n console.log('测试 DdbDatabaseError 和 DdbConnectionError')\n \n const error_message = '错误消息'\n const error_script = `throw ${error_message.quote()}`\n \n let database_error: DdbDatabaseError\n \n try {\n await ddb.eval(error_script)\n } catch (error) {\n database_error = error\n }\n \n assert(database_error)\n assert(database_error instanceof DdbDatabaseError)\n assert(database_error.message === `throw ${error_message.quote('double')} => ${error_message}`)\n assert(database_error.name === 'DdbDatabaseError')\n assert(database_error.ddb === ddb)\n assert(database_error.type === 'script')\n assert(database_error.options.script === error_script)\n assert(database_error.stack.includes('test_error'))\n \n \n let ddbtest = new DDB(url)\n let connection_error: DdbConnectionError\n try {\n await ddbtest.connect()\n ddbtest.disconnect()\n await ddbtest.eval('1')\n } catch (error) {\n connection_error = error\n }\n \n assert(connection_error)\n assert(connection_error instanceof DdbConnectionError)\n assert(connection_error.ddb === ddbtest)\n \n \n // --- 首次连接失败也会抛出 DdbConnectionError\n let ddbtest2 = new DDB('ws://dolphindb.com/')\n let connection_error2: DdbConnectionError\n try {\n await ddbtest2.connect()\n } catch (error) {\n connection_error2 = error\n }\n \n assert(connection_error2)\n assert(connection_error2 instanceof DdbConnectionError)\n assert(connection_error2.cause && connection_error2.cause instanceof WebSocketConnectionError)\n}\n\n\nasync function test_print (ddb: DDB) {\n console.log('测试 print message')\n \n const str = 'test print message\\n中文'\n \n assert(await get_printed(ddb, str.quote()) === str)\n \n console.log('测试 verbose 输出')\n \n let vddb = new DDB(url, { verbose: true })\n \n await vddb.call('typestr', [\n new DdbVectorAny([\n new DdbVectorSymbol(['a', 'b', 'a', 'b', 'a', 'b']),\n new DdbLong(3n)\n ])\n ])\n \n vddb.disconnect()\n}\n\n\nasync function test_streaming (ddb: DDB) {\n console.log('测试流数据')\n \n await ddb.eval(\n 'try {\\n' +\n \" if (!defined('prices', SHARED)) {\\n\" +\n ' share(\\n' +\n ' streamTable(\\n' +\n ' 10000:0,\\n' +\n \" ['time', 'stock', 'price'],\\n\" +\n ' [TIMESTAMP, SYMBOL, DOUBLE]\\n' +\n ' ),\\n' +\n \" 'prices'\\n\" +\n ' )\\n' +\n \" print('prices 流表创建成功')\\n\" +\n ' } else\\n' +\n \" print('prices 流表已存在')\\n\" +\n '} catch (error) {\\n' +\n \" print('prices 流表创建失败')\\n\" +\n ' print(error)\\n' +\n '}\\n'\n )\n \n let rows = 0\n let resolve: Function\n let promise = new Promise(_resolve => resolve = _resolve)\n \n let sddb = new DDB(url, {\n streaming: {\n table: 'prices',\n handler (message) {\n // console.log(message)\n rows += message.rows\n if (rows === 50)\n resolve()\n },\n }\n })\n \n await sddb.connect()\n \n await ddb.eval(\n 'n = 5\\n' +\n '\\n' +\n 'for (i in 0..9)\\n' +\n ' append!(\\n' +\n ' prices,\\n' +\n ' table([\\n' +\n ' (now() + 0..(n-1)) as time,\\n' +\n \" take(['MSFT', 'FUTU'], n) as stock,\\n\" +\n ' (0..(n-1) \\\\ 10) as price\\n' +\n ' ])\\n' +\n ' )\\n'\n )\n \n await promise\n console.log('流数据已全部收齐')\n \n sddb.disconnect()\n}\n\n\nasync function test_time (ddb: DDB) {\n console.log('测试时间显示')\n\n await time2str_equal(ddb, '2022-09-01T14:30:01.095')\n await time2str_equal(ddb, '2022-07-01T00:00:00.000')\n await time2str_equal(ddb, '2022-07-02T00:00:00.000')\n await time2str_equal(ddb, '2022-06-30T00:00:00.000')\n await time2str_equal(ddb, '2022-12-22T16:57:30.248')\n \n \n console.log('测试 month2ms')\n assert(\n month2ms(\n (\n await ddb.eval<DdbObj<number>>('2022.12M')\n ).value\n ) === new Date('2022.12.01').valueOf()\n )\n}\n\n\nasync function time2str_equal (ddb: DDB, timestr: string) {\n const code = `temporalParse('${timestr}', 'yyyy-MM-ddTHH:mm:sss.SSS')`\n \n assert(\n inspect(\n await ddb.eval(code),\n { colors: false }\n ).slice('timestamp('.length, -1) === \n (\n await get_printed(ddb, code)\n ).replace('T', ' ')\n )\n}\n\n\nexport async function test_types (ddb: DDB) {\n console.log('测试通过 ddb.call 调用 getNodeAlias 函数')\n console.log(await ddb.call('getNodeAlias'))\n \n console.log('测试 ddb.call 上传不同类型的变量')\n const result0 = await ddb.call('typestr', [new DdbInt(1)])\n console.log(result0)\n assert(result0.form === DdbForm.scalar)\n assert(result0.type === DdbType.string)\n assert(result0.value === 'INT')\n \n console.log('测试 ddb.call 上传不同类型的变量')\n const result1 = await ddb.call('typestr', [new DdbVectorDouble([0.1, 0.2, 0.3])])\n console.log(result1)\n assert(result1.form === DdbForm.scalar)\n assert(result1.type === DdbType.string)\n assert(result1.value === 'FAST DOUBLE VECTOR')\n \n console.log('测试 array vector')\n const av = await ddb.eval(\n 'av = array(INT[], 0, 3)\\n' +\n 'append!(av, [1..4])\\n' +\n 'append!(av, [1..70000])\\n' +\n 'av\\n'\n )\n \n console.log(av)\n assert(av.form === DdbForm.vector)\n assert(av.type === DdbType.int + 64) // array vector 的 type 比较特殊,需要偏移 64\n assert(av.rows === 2)\n \n \n console.log('测试大数据')\n let bigarr = new Float64Array(10)\n bigarr.fill(0.5)\n \n await ddb.call<DdbStringObj>('typestr', [\n new DdbObj({\n form: DdbForm.vector,\n type: DdbType.double,\n length: 0,\n rows: bigarr.length,\n cols: 1,\n value: bigarr\n })\n ])\n \n await ddb.upload(['a'], [\n new DdbObj({\n form: DdbForm.vector,\n type: DdbType.double,\n length: 0,\n rows: bigarr.length,\n cols: 1,\n value: bigarr\n })\n ])\n \n assert((\n await ddb.eval<DdbVectorDouble>('a')\n ).rows === bigarr.length)\n \n \n console.log('测试 datasource')\n \n const ds = (await ddb.eval<DdbVectorAnyObj>(\n 'db_path = \"dfs://test-datasource\"\\n' + \n 'tb_name = \"db\"\\n' + \n 'if (!existsTable(db_path, tb_name))\\n' + \n ' createTable(\\n' + \n ' database(db_path, VALUE , [1]),\\n' +\n ' table(1:0,`id`name, [INT, STRING]),\\n' +\n ' tb_name\\n' +\n ' ).append!(table(1 2 as id, `str1`str2 as name))\\n' +\n '\\n' +\n 'tb = loadTable(db_path, tb_name)\\n' +\n 'sqlDS(<select * from tb where id = 1>)\\n'\n )).value[0] as DdbStringObj\n \n const { type, form, value } = ds\n \n assert(type === DdbType.datasource && form === DdbForm.scalar, '返回的 DdbObj 具有正确的 type 和 form')\n \n assert(value === 'DataSource< select [7] * from tb where id == 1 >')\n \n // 如果直接构造 DdbObj Datasource,将其送入 ddb.call, ddb将仍然认为送入的是一个 STRING \n assert(\n (await ddb.call<DdbStringObj>('typestr', [ds])).value === 'STRING', \n '从 js 构建的 Datasource DdbObj 会被识别为 STRING'\n )\n}\n\n"]}
1
+ {"version":3,"file":"test.js","sourceRoot":"","sources":["test.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,OAAO,EAAE,mBAAmB,EAAE,wBAAwB,EAAE,MAAM,QAAQ,CAAA;AAEvF,OAAO,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAA;AACxC,OAAO,EAAE,GAAG,EAAE,kBAAkB,EAAE,gBAAgB,EAAE,OAAO,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,EAAE,OAAO,EAAE,YAAY,EAAE,eAAe,EAAE,eAAe,EAAE,QAAQ,EAAwE,eAAe,EAAuC,MAAM,YAAY,CAAA;AAGvS,mBAAmB,EAAE,CAAA;AAGrB,QAAQ;AACR,0DAA0D;AAC1D,wDAAwD;AACxD,MAAM,CAAC,MAAM,GAAG,GAAG,wBAAiC,CASnD;AAAA,CAAC,KAAK,UAAU,IAAI;IACjB,OAAO,CAAC,GAAG,CAAC,cAAc,CAAC,KAAK,CAAC,CAAA;IAEjC,IAAI,GAAG,GAAG,IAAI,GAAG,CAAC,GAAG,CAAC,CAAA;IAEtB,MAAM,KAAK,GAAG;QACV,SAAS;QAET,aAAa;QACb,UAAU;QACV,iBAAiB;QACjB,UAAU;QACV,SAAS;QACT,cAAc;QACd,UAAU;KACb,CAAA;IAED,KAAK,MAAM,OAAO,IAAI,KAAK;QACvB,MAAM,OAAO,CAAC,GAAG,CAAC,CAAA;IAEtB,GAAG,CAAC,UAAU,EAAE,CAAA;IAEhB,OAAO,CAAC,GAAG,CAAC,cAAc,CAAC,KAAK,CAAC,CAAA;AACrC,CAAC,CAAC,EAAE,CAAA;AAIJ,SAAS,aAAa;IAClB,MAAM,CAAC,IAAI,GAAG,CAAC,QAAQ,CAAC,CAAC,IAAI,KAA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CAAC","sourcesContent":["import { assert, inspect, set_inspect_options, WebSocketConnectionError } from 'xshell'\n\nimport { keywords } from './language.js'\nimport { DDB, DdbConnectionError, DdbDatabaseError, DdbForm, DdbInt, DdbLong, DdbObj, DdbType, DdbVectorAny, DdbVectorDouble, DdbVectorSymbol, month2ms, type DdbStringObj, type DdbVectorAnyObj, type DdbDurationVectorValue, DdbDurationUnit, type DdbVectorObj, type DdbTableObj } from './index.js'\n\n\nset_inspect_options()\n\n\n// linux\n// export const url = 'ws://115.239.209.123:8892' as const\n// export const url = 'ws://192.168.0.16:20002' as const\nexport const url = 'ws://192.168.0.29:9002' as const\n\n// windows\n// export const url = 'ws://192.168.0.29:9002' as const\n\n// local 8848\n// export const url = 'ws://127.0.0.1:8848' as const\n\n\n;(async function test () {\n console.log('--- 测试开始 ---'.green)\n \n let ddb = new DDB(url)\n \n const tests = [\n test_repl,\n \n test_keywords,\n test_types,\n test_reconnection,\n test_print,\n test_time,\n test_streaming,\n test_error,\n ]\n \n for (const fn_test of tests)\n await fn_test(ddb)\n \n ddb.disconnect()\n \n console.log('--- 测试通过 ---'.green)\n})()\n\n\n\nfunction test_keywords () {\n assert(new Set(keywords).size === keywords.length, 'keywords 中不能有重复的项')\n}\n\n\nasync function get_printed (ddb: DDB, code: string) {\n return new Promise<string>(async (resolve, reject) => {\n try {\n let resolved = false\n await ddb.eval(\n `print(${code})`,\n {\n listener ({ type, data }) {\n if (type === 'print' && !resolved) {\n resolved = true\n resolve(data)\n }\n }\n }\n )\n if (!resolved)\n reject(new Error('未输出 print 消息'))\n } catch (error) {\n reject(error)\n }\n })\n}\n\n\nasync function test_repl (ddb: DDB) {\n \n}\n\n\nasync function test_reconnection (ddb: DDB) {\n let _ddb = new DDB(url)\n \n await _ddb.connect()\n _ddb.disconnect()\n \n let error: DdbConnectionError\n \n try {\n await _ddb.connect()\n } catch (_error) {\n error = _error\n }\n \n assert(error && error instanceof DdbConnectionError)\n}\n\n\nasync function test_error (ddb: DDB) {\n console.log('测试 DdbDatabaseError 和 DdbConnectionError')\n \n const error_message = '错误消息'\n const error_script = `throw ${error_message.quote()}`\n \n let database_error: DdbDatabaseError\n \n try {\n await ddb.eval(error_script)\n } catch (error) {\n database_error = error\n }\n \n assert(database_error)\n assert(database_error instanceof DdbDatabaseError)\n assert(database_error.message === `throw ${error_message.quote('double')} => ${error_message}`)\n assert(database_error.name === 'DdbDatabaseError')\n assert(database_error.ddb === ddb)\n assert(database_error.type === 'script')\n assert(database_error.options.script === error_script)\n assert(database_error.stack.includes('test_error'))\n \n \n let ddbtest = new DDB(url)\n let connection_error: DdbConnectionError\n try {\n await ddbtest.connect()\n ddbtest.disconnect()\n await ddbtest.eval('1')\n } catch (error) {\n connection_error = error\n }\n \n assert(connection_error)\n assert(connection_error instanceof DdbConnectionError)\n assert(connection_error.ddb === ddbtest)\n \n \n // --- 首次连接失败也会抛出 DdbConnectionError\n let ddbtest2 = new DDB('ws://dolphindb.com/')\n let connection_error2: DdbConnectionError\n try {\n await ddbtest2.connect()\n } catch (error) {\n connection_error2 = error\n }\n \n assert(connection_error2)\n assert(connection_error2 instanceof DdbConnectionError)\n assert(connection_error2.cause && connection_error2.cause instanceof WebSocketConnectionError)\n}\n\n\nasync function test_print (ddb: DDB) {\n console.log('测试 print message')\n \n const str = 'test print message\\n中文'\n \n assert(await get_printed(ddb, str.quote()) === str)\n \n console.log('测试 verbose 输出')\n \n let vddb = new DDB(url, { verbose: true })\n \n await vddb.call('typestr', [\n new DdbVectorAny([\n new DdbVectorSymbol(['a', 'b', 'a', 'b', 'a', 'b']),\n new DdbLong(3n)\n ])\n ])\n \n vddb.disconnect()\n}\n\n\nasync function test_streaming (ddb: DDB) {\n console.log('测试流数据')\n \n await ddb.eval(\n 'try {\\n' +\n \" if (!defined('prices', SHARED)) {\\n\" +\n ' share(\\n' +\n ' streamTable(\\n' +\n ' 10000:0,\\n' +\n \" ['time', 'stock', 'price'],\\n\" +\n ' [TIMESTAMP, SYMBOL, DOUBLE]\\n' +\n ' ),\\n' +\n \" 'prices'\\n\" +\n ' )\\n' +\n \" print('prices 流表创建成功')\\n\" +\n ' } else\\n' +\n \" print('prices 流表已存在')\\n\" +\n '} catch (error) {\\n' +\n \" print('prices 流表创建失败')\\n\" +\n ' print(error)\\n' +\n '}\\n'\n )\n \n let rows = 0\n let resolve: Function\n let promise = new Promise(_resolve => resolve = _resolve)\n \n let sddb = new DDB(url, {\n streaming: {\n table: 'prices',\n handler (message) {\n // console.log(message)\n rows += message.rows\n if (rows === 50)\n resolve()\n },\n }\n })\n \n await sddb.connect()\n \n await ddb.eval(\n 'n = 5\\n' +\n '\\n' +\n 'for (i in 0..9)\\n' +\n ' append!(\\n' +\n ' prices,\\n' +\n ' table([\\n' +\n ' (now() + 0..(n-1)) as time,\\n' +\n \" take(['MSFT', 'FUTU'], n) as stock,\\n\" +\n ' (0..(n-1) \\\\ 10) as price\\n' +\n ' ])\\n' +\n ' )\\n'\n )\n \n await promise\n console.log('流数据已全部收齐')\n \n sddb.disconnect()\n}\n\n\nasync function test_time (ddb: DDB) {\n console.log('测试时间显示')\n\n await time2str_equal(ddb, '2022-09-01T14:30:01.095')\n await time2str_equal(ddb, '2022-07-01T00:00:00.000')\n await time2str_equal(ddb, '2022-07-02T00:00:00.000')\n await time2str_equal(ddb, '2022-06-30T00:00:00.000')\n await time2str_equal(ddb, '2022-12-22T16:57:30.248')\n \n \n console.log('测试 month2ms')\n assert(\n month2ms(\n (\n await ddb.eval<DdbObj<number>>('2022.12M')\n ).value\n ) === new Date('2022.12.01').valueOf()\n )\n}\n\n\nasync function time2str_equal (ddb: DDB, timestr: string) {\n const code = `temporalParse('${timestr}', 'yyyy-MM-ddTHH:mm:sss.SSS')`\n \n assert(\n inspect(\n await ddb.eval(code),\n { colors: false }\n ).slice('timestamp('.length, -1) === \n (\n await get_printed(ddb, code)\n ).replace('T', ' ')\n )\n}\n\n\nexport async function test_types (ddb: DDB) {\n console.log('测试通过 ddb.call 调用 getNodeAlias 函数')\n console.log(await ddb.call('getNodeAlias'))\n \n console.log('测试 ddb.call 上传不同类型的变量')\n const result0 = await ddb.call('typestr', [new DdbInt(1)])\n console.log(result0)\n assert(result0.form === DdbForm.scalar)\n assert(result0.type === DdbType.string)\n assert(result0.value === 'INT')\n \n console.log('测试 ddb.call 上传不同类型的变量')\n const result1 = await ddb.call('typestr', [new DdbVectorDouble([0.1, 0.2, 0.3])])\n console.log(result1)\n assert(result1.form === DdbForm.scalar)\n assert(result1.type === DdbType.string)\n assert(result1.value === 'FAST DOUBLE VECTOR')\n \n console.log('测试 array vector')\n const av = await ddb.eval(\n 'av = array(INT[], 0, 3)\\n' +\n 'append!(av, [1..4])\\n' +\n 'append!(av, [1..70000])\\n' +\n 'av\\n'\n )\n \n console.log(av)\n assert(av.form === DdbForm.vector)\n assert(av.type === DdbType.int + 64) // array vector 的 type 比较特殊,需要偏移 64\n assert(av.rows === 2)\n \n \n console.log('测试大数据')\n let bigarr = new Float64Array(10)\n bigarr.fill(0.5)\n \n await ddb.call<DdbStringObj>('typestr', [\n new DdbObj({\n form: DdbForm.vector,\n type: DdbType.double,\n length: 0,\n rows: bigarr.length,\n cols: 1,\n value: bigarr\n })\n ])\n \n await ddb.upload(['a'], [\n new DdbObj({\n form: DdbForm.vector,\n type: DdbType.double,\n length: 0,\n rows: bigarr.length,\n cols: 1,\n value: bigarr\n })\n ])\n \n assert((\n await ddb.eval<DdbVectorDouble>('a')\n ).rows === bigarr.length)\n \n \n console.log('测试 datasource')\n \n const ds = (await ddb.eval<DdbVectorAnyObj>(\n 'db_path = \"dfs://test-datasource\"\\n' + \n 'tb_name = \"db\"\\n' + \n 'if (!existsTable(db_path, tb_name))\\n' + \n ' createTable(\\n' + \n ' database(db_path, VALUE , [1]),\\n' +\n ' table(1:0,`id`name, [INT, STRING]),\\n' +\n ' tb_name\\n' +\n ' ).append!(table(1 2 as id, `str1`str2 as name))\\n' +\n '\\n' +\n 'tb = loadTable(db_path, tb_name)\\n' +\n 'sqlDS(<select * from tb where id = 1>)\\n'\n )).value[0] as DdbStringObj\n \n const { type, form, value } = ds\n \n assert(type === DdbType.datasource && form === DdbForm.scalar, '返回的 DdbObj 具有正确的 type 和 form')\n \n assert(value === 'DataSource< select [7] * from tb where id == 1 >')\n \n // 如果直接构造 DdbObj Datasource,将其送入 ddb.call, ddb将仍然认为送入的是一个 STRING \n assert(\n (await ddb.call<DdbStringObj>('typestr', [ds])).value === 'STRING', \n '从 js 构建的 Datasource DdbObj 会被识别为 STRING'\n )\n \n console.log('测试 pair<duration>')\n const dp = await ddb.eval<DdbVectorObj<DdbDurationVectorValue>>(\n 'pair(duration(\"20d\"), duration(\"2H\"))'\n ) \n \n console.log(dp)\n assert(dp.type === DdbType.duration, 'dp 的返回值应该为 Duration')\n assert(dp.value[0].data === 20 && dp.value[0].unit === DdbDurationUnit.d, 'pair<duration> 的 value 应该已解析')\n \n console.log('测试 void vector')\n const table = await ddb.eval<DdbTableObj>('select *, NULL as val from table(1..100 as id)')\n const { value: [ints, voids] } = table\n \n console.log(voids)\n assert(voids.rows === ints.rows, 'void vector 应该具有正常的 vector length')\n assert(voids.length === 10, 'void vector 应该具有正确的数据长度')\n assert(voids.value === null, 'void vector 的值应该为 null')\n \n await ddb.upload(['voidtable'], [table])\n}\n\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"theme.light.js","sourceRoot":"","sources":["theme.light.ts"],"names":[],"mappings":"AAAA,2BAA2B;AAC3B,mIAAmI;AAEnI,0EAA0E;AAC1E,MAAM,CAAC,MAAM,WAAW,GAAG;IACvB,IAAI,EAAE,iBAAiB;IACvB,QAAQ,EAAE;QACN;YACI,QAAQ,EAAE;gBACN,UAAU,EAAE,SAAS;gBACrB,UAAU,EAAE,SAAS;aACxB;SACJ;QACD;YACI,KAAK,EAAE,CAAC,eAAe,EAAE,wBAAwB,CAAC;YAClD,QAAQ,EAAE;gBACN,UAAU,EAAE,WAAW;aAC1B;SACJ;QACD;YACI,KAAK,EAAE,UAAU;YACjB,QAA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ent":["// Theme data derived from:\n// https://github.com/microsoft/vscode/raw/a716714a88891cad69c0753fb95923870df295f5/extensions/theme-defaults/themes/dark_plus.json\n\n// This satisfies the contract of IRawTheme as defined in vscode-textmate.\nexport const theme_light = {\n name: 'dolphindb.light',\n settings: [\n {\n settings: {\n foreground: '#000000',\n background: '#ffffff'\n }\n },\n {\n scope: ['meta.embedded', 'source.groovy.embedded'],\n settings: {\n foreground: '#000000ff'\n }\n },\n {\n scope: 'emphasis',\n settings: {\n fontStyle: 'italic'\n }\n },\n {\n scope: 'strong',\n settings: {\n fontStyle: 'bold'\n }\n },\n {\n scope: 'meta.diff.header',\n settings: {\n foreground: '#000080'\n }\n },\n {\n scope: 'comment',\n settings: {\n foreground: '#000000'\n }\n },\n {\n scope: 'constant.language',\n settings: {\n foreground: '#0000ff'\n }\n },\n {\n scope: ['constant.numeric', 'variable.other.enummember', 'keyword.operator.plus.exponent', 'keyword.operator.minus.exponent'],\n settings: {\n foreground: '#ff0000'\n }\n },\n {\n scope: 'constant.regexp',\n settings: {\n foreground: '#811f3f'\n }\n },\n {\n name: 'css tags in selectors, xml tags',\n scope: 'entity.name.tag',\n settings: {\n foreground: '#800000'\n }\n },\n {\n scope: 'entity.name.selector',\n settings: {\n foreground: '#800000'\n }\n },\n {\n scope: 'entity.other.attribute-name',\n settings: {\n foreground: '#ff0000'\n }\n },\n {\n scope: [\n 'entity.other.attribute-name.class.css',\n 'entity.other.attribute-name.class.mixin.css',\n 'entity.other.attribute-name.id.css',\n 'entity.other.attribute-name.parent-selector.css',\n 'entity.other.attribute-name.pseudo-class.css',\n 'entity.other.attribute-name.pseudo-element.css',\n 'source.css.less entity.other.attribute-name.id',\n 'entity.other.attribute-name.scss'\n ],\n settings: {\n foreground: '#800000'\n }\n },\n {\n scope: 'invalid',\n settings: {\n foreground: '#cd3131'\n }\n },\n {\n scope: 'markup.underline',\n settings: {\n fontStyle: 'underline'\n }\n },\n {\n scope: 'markup.bold',\n settings: {\n fontStyle: 'bold',\n foreground: '#000080'\n }\n },\n {\n scope: 'markup.heading',\n settings: {\n fontStyle: 'bold',\n foreground: '#800000'\n }\n },\n {\n scope: 'markup.italic',\n settings: {\n fontStyle: 'italic'\n }\n },\n {\n scope: 'markup.strikethrough',\n settings: {\n fontStyle: 'strikethrough'\n }\n },\n {\n scope: 'markup.inserted',\n settings: {\n foreground: '#098658'\n }\n },\n {\n scope: 'markup.deleted',\n settings: {\n foreground: '#a31515'\n }\n },\n {\n scope: 'markup.changed',\n settings: {\n foreground: '#0451a5'\n }\n },\n {\n scope: ['punctuation.definition.quote.begin.markdown', 'punctuation.definition.list.begin.markdown'],\n settings: {\n foreground: '#0451a5'\n }\n },\n {\n scope: 'markup.inline.raw',\n settings: {\n foreground: '#800000'\n }\n },\n {\n name: 'brackets of XML/HTML tags',\n scope: 'punctuation.definition.tag',\n settings: {\n foreground: '#800000'\n }\n },\n {\n scope: ['meta.preprocessor', 'entity.name.function.preprocessor'],\n settings: {\n foreground: '#0000ff'\n }\n },\n {\n scope: 'meta.preprocessor.string',\n settings: {\n foreground: '#a31515'\n }\n },\n {\n scope: 'meta.preprocessor.numeric',\n settings: {\n foreground: '#098658'\n }\n },\n {\n scope: 'meta.structure.dictionary.key.python',\n settings: {\n foreground: '#0451a5'\n }\n },\n {\n scope: 'storage',\n settings: {\n foreground: '#0000ff'\n }\n },\n {\n scope: 'storage.type',\n settings: {\n foreground: '#0000ff'\n }\n },\n {\n scope: ['storage.modifier', 'keyword.operator.noexcept'],\n settings: {\n foreground: '#0000ff'\n }\n },\n {\n scope: ['string', 'meta.embedded.assembly'],\n settings: {\n foreground: '#a31515'\n }\n },\n {\n scope: [\n 'string.comment.buffered.block.pug',\n 'string.quoted.pug',\n 'string.interpolated.pug',\n 'string.unquoted.plain.in.yaml',\n 'string.unquoted.plain.out.yaml',\n 'string.unquoted.block.yaml',\n 'string.quoted.single.yaml',\n 'string.quoted.double.xml',\n 'string.quoted.single.xml',\n 'string.unquoted.cdata.xml',\n 'string.quoted.double.html',\n 'string.quoted.single.html',\n 'string.unquoted.html',\n 'string.quoted.single.handlebars',\n 'string.quoted.double.handlebars'\n ],\n settings: {\n foreground: '#0000ff'\n }\n },\n {\n scope: 'string.regexp',\n settings: {\n foreground: '#811f3f'\n }\n },\n {\n name: 'String interpolation',\n scope: [\n 'punctuation.definition.template-expression.begin',\n 'punctuation.definition.template-expression.end',\n 'punctuation.section.embedded'\n ],\n settings: {\n foreground: '#0000ff'\n }\n },\n {\n name: 'Reset JavaScript string interpolation expression',\n scope: ['meta.template.expression'],\n settings: {\n foreground: '#000000'\n }\n },\n {\n scope: [\n 'support.constant.property-value',\n 'support.constant.font-name',\n 'support.constant.media-type',\n 'support.constant.media',\n 'constant.other.color.rgb-value',\n 'constant.other.rgb-value',\n 'support.constant.color'\n ],\n settings: {\n foreground: '#0451a5'\n }\n },\n {\n scope: [\n 'support.type.vendored.property-name',\n 'support.type.property-name',\n 'variable.css',\n 'variable.scss',\n 'variable.other.less',\n 'source.coffee.embedded'\n ],\n settings: {\n foreground: '#ff0000'\n }\n },\n {\n scope: ['support.type.property-name.json'],\n settings: {\n foreground: '#0451a5'\n }\n },\n {\n scope: 'keyword',\n settings: {\n foreground: '#0000ff'\n }\n },\n {\n scope: 'keyword.control',\n settings: {\n foreground: '#0000ff'\n }\n },\n {\n scope: 'keyword.operator',\n settings: {\n foreground: '#000000'\n }\n },\n {\n scope: [\n 'keyword.operator.new',\n 'keyword.operator.expression',\n 'keyword.operator.cast',\n 'keyword.operator.sizeof',\n 'keyword.operator.alignof',\n 'keyword.operator.typeid',\n 'keyword.operator.alignas',\n 'keyword.operator.instanceof',\n 'keyword.operator.logical.python',\n 'keyword.operator.wordlike'\n ],\n settings: {\n foreground: '#0000ff'\n }\n },\n {\n scope: 'keyword.other.unit',\n settings: {\n foreground: '#098658'\n }\n },\n {\n scope: ['punctuation.section.embedded.begin.php', 'punctuation.section.embedded.end.php'],\n settings: {\n foreground: '#800000'\n }\n },\n {\n scope: 'support.function.git-rebase',\n settings: {\n foreground: '#0451a5'\n }\n },\n {\n scope: 'constant.sha.git-rebase',\n settings: {\n foreground: '#098658'\n }\n },\n {\n name: 'coloring of the Java import and package identifiers',\n scope: ['storage.modifier.import.java', 'variable.language.wildcard.java', 'storage.modifier.package.java'],\n settings: {\n foreground: '#000000'\n }\n },\n {\n name: 'this.self',\n scope: 'variable.language',\n settings: {\n foreground: '#0000ff'\n }\n },\n \n // adds rules to the light vs rules\n {\n name: 'Function declarations',\n scope: [\n 'entity.name.function',\n 'support.function',\n 'support.constant.handlebars',\n 'source.powershell variable.other.member',\n 'entity.name.operator.custom-literal' // See https://en.cppreference.com/w/cpp/language/user_literal\n ],\n settings: {\n foreground: '#795E26'\n }\n },\n {\n name: 'Types declaration and references',\n scope: [\n 'support.class',\n 'support.type',\n 'entity.name.type',\n 'entity.name.namespace',\n 'entity.other.attribute',\n 'entity.name.scope-resolution',\n 'entity.name.class',\n 'storage.type.numeric.go',\n 'storage.type.byte.go',\n 'storage.type.boolean.go',\n 'storage.type.string.go',\n 'storage.type.uintptr.go',\n 'storage.type.error.go',\n 'storage.type.rune.go',\n 'storage.type.cs',\n 'storage.type.generic.cs',\n 'storage.type.modifier.cs',\n 'storage.type.variable.cs',\n 'storage.type.annotation.java',\n 'storage.type.generic.java',\n 'storage.type.java',\n 'storage.type.object.array.java',\n 'storage.type.primitive.array.java',\n 'storage.type.primitive.java',\n 'storage.type.token.java',\n 'storage.type.groovy',\n 'storage.type.annotation.groovy',\n 'storage.type.parameters.groovy',\n 'storage.type.generic.groovy',\n 'storage.type.object.array.groovy',\n 'storage.type.primitive.array.groovy',\n 'storage.type.primitive.groovy'\n ],\n settings: {\n foreground: '#0f96be'\n }\n },\n {\n name: 'Types declaration and references, TS grammar specific',\n scope: [\n 'meta.type.cast.expr',\n 'meta.type.new.expr',\n 'support.constant.math',\n 'support.constant.dom',\n 'support.constant.json',\n 'entity.other.inherited-class'\n ],\n settings: {\n foreground: '#267f99'\n }\n },\n {\n name: 'Control flow / Special keywords',\n scope: [\n 'keyword.control',\n 'source.cpp keyword.operator.new',\n 'source.cpp keyword.operator.delete',\n 'keyword.other.using',\n 'keyword.other.operator',\n 'entity.name.operator'\n ],\n settings: {\n foreground: '#AF00DB'\n }\n },\n {\n name: 'Variable and parameter name',\n scope: [\n 'variable',\n 'meta.definition.variable.name',\n 'support.variable',\n 'entity.name.variable',\n 'constant.other.placeholder' // placeholders in strings\n ],\n settings: {\n foreground: '#000000'\n }\n },\n {\n name: 'Constants and enums',\n scope: ['variable.other.constant', 'variable.other.enummember'],\n settings: {\n foreground: '#0070C1'\n }\n },\n {\n name: 'Object keys, TS grammar specific',\n scope: ['meta.object-literal.key'],\n settings: {\n foreground: '#001080'\n }\n },\n {\n name: 'CSS property value',\n scope: [\n 'support.constant.property-value',\n 'support.constant.font-name',\n 'support.constant.media-type',\n 'support.constant.media',\n 'constant.other.color.rgb-value',\n 'constant.other.rgb-value',\n 'support.constant.color'\n ],\n settings: {\n foreground: '#0451a5'\n }\n },\n {\n name: 'Regular expression groups',\n scope: [\n 'punctuation.definition.group.regexp',\n 'punctuation.definition.group.assertion.regexp',\n 'punctuation.definition.character-class.regexp',\n 'punctuation.character.set.begin.regexp',\n 'punctuation.character.set.end.regexp',\n 'keyword.operator.negation.regexp',\n 'support.other.parenthesis.regexp'\n ],\n settings: {\n foreground: '#d16969'\n }\n },\n {\n scope: [\n 'constant.character.character-class.regexp',\n 'constant.other.character-class.set.regexp',\n 'constant.other.character-class.regexp',\n 'constant.character.set.regexp'\n ],\n settings: {\n foreground: '#811f3f'\n }\n },\n {\n scope: 'keyword.operator.quantifier.regexp',\n settings: {\n foreground: '#000000'\n }\n },\n {\n scope: ['keyword.operator.or.regexp', 'keyword.control.anchor.regexp'],\n settings: {\n foreground: '#EE0000'\n }\n },\n {\n scope: 'constant.character',\n settings: {\n foreground: '#0000ff'\n }\n },\n {\n scope: 'constant.character.escape',\n settings: {\n foreground: '#EE0000'\n }\n },\n {\n scope: 'entity.name.label',\n settings: {\n foreground: '#000000'\n }\n },\n { scope: 'keyword.operator', settings: { foreground: '#f00' } },\n { scope: 'keyword.operator.instanceof', settings: { foreground: '#f00' } },\n { scope: 'keyword.operator.logical', settings: { foreground: '#f00' } },\n { scope: 'keyword.operator.logical.python', settings: { foreground: '#f00' } },\n \n // { \"scope\": \"keyword.control\", \"settings\": { \"foreground\": \"#bc00eb\" } }\n \n // { \"scope\": \"support.type.property-name\", \"settings\": { \"foreground\": \"#0451a5\" } },\n { scope: 'support.type.property-name', settings: { foreground: '#000000' } },\n \n // { \"scope\": \"variable.other\", \"settings\": { \"foreground\": \"#000000\", \"fontStyle\": \"\" } },\n // { \"scope\": \"variable.parameter\", \"settings\": { \"foreground\": \"#000000\", \"fontStyle\": \"\" } },\n { scope: 'variable', settings: { foreground: '#000000', fontStyle: '' } },\n // { \"scope\": \"variable.other.property\", \"settings\": { \"foreground\": \"#0115AF\" } },\n { scope: 'variable.other.constant', settings: { foreground: '#000000' } },\n \n { scope: 'keyword.operator.expression.typeof.js', settings: { foreground: '#f00' } },\n { scope: 'storage.type', settings: { foreground: '#0000ee' } }, // const\n { scope: 'storage.modifier', settings: { foreground: '#0000ee' } },\n { scope: 'constant.language', settings: { foreground: '#0000ee' } },\n { scope: 'constant.numeric', settings: { foreground: '#00a000' } }, // number\n { scope: 'variable.language.this', settings: { foreground: '#267f99' } },\n { scope: 'string.quoted.docstring.multi.python', settings: { foreground: '#000000' } },\n { scope: 'punctuation.separator.delimiter.c', settings: { foreground: '#f00' } },\n { scope: 'punctuation.separator.pointer-access.c', settings: { foreground: '#f00' } },\n { scope: 'entity.name.tag.pug', settings: { foreground: '#f00' } },\n { scope: 'entity.other.attribute-name.id.pug', settings: { foreground: '#722dd2' } },\n { scope: 'entity.other.attribute-name.class.pug', settings: { foreground: '#267f99' } },\n { scope: 'entity.other.attribute-name.tag.pug', settings: { foreground: '#8e5e1a' } },\n { scope: 'entity.name.tag', settings: { foreground: '#000000', fontStyle: 'bold' } },\n \n { scope: 'punctuation.definition.tag', settings: { foreground: '#000000', fontStyle: 'bold' } },\n \n \n // function: bold\n { scope: 'entity.name.function', settings: { foreground: '#000000' , fontStyle: 'bold' } },\n { scope: 'support.function', settings: { foreground: '#000000' , fontStyle: 'bold' } },\n \n { scope: 'constant.language.module.http', settings: { foreground: '#00f' } },\n { scope: 'constant.language.directive.module', settings: { foreground: '#00f' } },\n { scope: 'constant.language.directive.module.main', settings: { foreground: '#f00', fontStyle: 'bold' } },\n \n { scope: 'meta.decorator.dolphindb', settings: { foreground: '#aa6f00' } },\n \n { scope: 'punctuation.definition.string.begin.json.comments', settings: { foreground: '#111' } },\n { scope: 'punctuation.definition.string.end.json.comments', settings: { foreground: '#111' } },\n { scope: 'punctuation.support.type.property-name.begin.json.comments', settings: { foreground: '#111' } },\n { scope: 'punctuation.support.type.property-name.end.json.comments', settings: { foreground: '#111' } }\n ]\n}\n"]}
1
+ {"version":3,"file":"theme.light.js","sourceRoot":"","sources":["theme.light.ts"],"names":[],"mappings":"AAAA,2BAA2B;AAC3B,mIAAmI;AAEnI,0EAA0E;AAC1E,MAAM,CAAC,MAAM,WAAW,GAAG;IACvB,IAAI,EAAE,iBAAiB;IACvB,QAAQ,EAAE;QACN;YACI,QAAQ,EAAE;gBACN,UAAU,EAAE,SAAS;gBACrB,UAAU,EAAE,SAAS;aACxB;SACJ;QACD;YACI,KAAK,EAAE,CAAC,eAAe,EAAE,wBAAwB,CAAC;YAClD,QAAQ,EAAE;gBACN,UAAU,EAAE,WAAW;aAC1B;SACJ;QACD;YACI,KAAK,EAAE,UAAU;YACjB,QAAQ,EAAE;gBACN,SAAS,EAAE,QAAQ;aACtB;SACJ;QACD;YACI,KAAK,EAAE,QAAQ;YACf,QAAQ,EAAE;gBACN,SAAS,EAAE,MAAM;aACpB;SACJ;QACD;YACI,KAAK,EAAE,kBAAkB;YACzB,QAAQ,EAAE;gBACN,UAAU,EAAE,SAAS;aACxB;SACJ;QACD;YACI,KAAK,E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;QAG/F,iBAAiB;QACjB,EAAE,KAAK,EAAE,sBAAsB,EAAE,QAAQ,EAAE,EAAE,UAAU,EAAE,SAAS,EAAE,SAAS,EAAE,MAAM,EAAG,EAAE;QAC1F,EAAE,KAAK,EAAE,kBAAkB,EAAE,QAAQ,EAAE,EAAE,UAAU,EAAE,SAAS,EAAE,SAAS,EAAE,MAAM,EAAE,EAAE;QAErF,EAAE,KAAK,EAAE,+BAA+B,EAAE,QAAQ,EAAE,EAAE,UAAU,EAAE,MAAM,EAAE,EAAE;QAC5E,EAAE,KAAK,EAAE,oCAAoC,EAAE,QAAQ,EAAE,EAAE,UAAU,EAAE,MAAM,EAAE,EAAE;QACjF,EAAE,KAAK,EAAE,yCAAyC,EAAE,QAAQ,EAAE,EAAE,UAAU,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,EAAE,EAAE;QAEzG,EAAE,KAAK,EAAE,0BAA0B,EAAE,QAAQ,EAAE,EAAE,UAAU,EAAE,SAAS,EAAE,EAAE;QAE1E,EAAE,KAAK,EAAE,mDAAmD,EAAE,QAAQ,EAAE,EAAE,UAAU,EAAE,MAAM,EAAE,EAAE;QAChG,EAAE,KAAK,EAAE,iDAAiD,EAAE,QAAQ,EAAE,EAAE,UAAU,EAAE,MAAM,EAAE,EAAE;QAC9F,EAAE,KAAK,EAAE,4DAA4D,EAAE,QAAQ,EAAE,EAAE,UAAU,EAAE,MAAM,EAAE,EAAE;QACzG,EAAE,KAAK,EAAE,0DAA0D,EAAE,QAAQ,EAAE,EAAE,UAAU,EAAE,MAAM,EAAE,EAAE;KAC1G;CACJ,CAAA","sourcesContent":["// Theme data derived from:\n// https://github.com/microsoft/vscode/raw/a716714a88891cad69c0753fb95923870df295f5/extensions/theme-defaults/themes/dark_plus.json\n\n// This satisfies the contract of IRawTheme as defined in vscode-textmate.\nexport const theme_light = {\n name: 'dolphindb.light',\n settings: [\n {\n settings: {\n foreground: '#000000',\n background: '#ffffff'\n }\n },\n {\n scope: ['meta.embedded', 'source.groovy.embedded'],\n settings: {\n foreground: '#000000ff'\n }\n },\n {\n scope: 'emphasis',\n settings: {\n fontStyle: 'italic'\n }\n },\n {\n scope: 'strong',\n settings: {\n fontStyle: 'bold'\n }\n },\n {\n scope: 'meta.diff.header',\n settings: {\n foreground: '#000080'\n }\n },\n {\n scope: 'comment',\n settings: {\n foreground: '#000000'\n }\n },\n {\n scope: 'constant.language',\n settings: {\n foreground: '#0000ff'\n }\n },\n {\n scope: ['constant.numeric', 'variable.other.enummember', 'keyword.operator.plus.exponent', 'keyword.operator.minus.exponent'],\n settings: {\n foreground: '#ff0000'\n }\n },\n {\n scope: 'constant.regexp',\n settings: {\n foreground: '#811f3f'\n }\n },\n {\n name: 'css tags in selectors, xml tags',\n scope: 'entity.name.tag',\n settings: {\n foreground: '#800000'\n }\n },\n {\n scope: 'entity.name.selector',\n settings: {\n foreground: '#800000'\n }\n },\n {\n scope: 'entity.other.attribute-name',\n settings: {\n foreground: '#ff0000'\n }\n },\n {\n scope: [\n 'entity.other.attribute-name.class.css',\n 'entity.other.attribute-name.class.mixin.css',\n 'entity.other.attribute-name.id.css',\n 'entity.other.attribute-name.parent-selector.css',\n 'entity.other.attribute-name.pseudo-class.css',\n 'entity.other.attribute-name.pseudo-element.css',\n 'source.css.less entity.other.attribute-name.id',\n 'entity.other.attribute-name.scss'\n ],\n settings: {\n foreground: '#800000'\n }\n },\n {\n scope: 'invalid',\n settings: {\n foreground: '#cd3131'\n }\n },\n {\n scope: 'markup.underline',\n settings: {\n fontStyle: 'underline'\n }\n },\n {\n scope: 'markup.bold',\n settings: {\n fontStyle: 'bold',\n foreground: '#000080'\n }\n },\n {\n scope: 'markup.heading',\n settings: {\n fontStyle: 'bold',\n foreground: '#800000'\n }\n },\n {\n scope: 'markup.italic',\n settings: {\n fontStyle: 'italic'\n }\n },\n {\n scope: 'markup.strikethrough',\n settings: {\n fontStyle: 'strikethrough'\n }\n },\n {\n scope: 'markup.inserted',\n settings: {\n foreground: '#098658'\n }\n },\n {\n scope: 'markup.deleted',\n settings: {\n foreground: '#a31515'\n }\n },\n {\n scope: 'markup.changed',\n settings: {\n foreground: '#0451a5'\n }\n },\n {\n scope: ['punctuation.definition.quote.begin.markdown', 'punctuation.definition.list.begin.markdown'],\n settings: {\n foreground: '#0451a5'\n }\n },\n {\n scope: 'markup.inline.raw',\n settings: {\n foreground: '#800000'\n }\n },\n {\n name: 'brackets of XML/HTML tags',\n scope: 'punctuation.definition.tag',\n settings: {\n foreground: '#800000'\n }\n },\n {\n scope: ['meta.preprocessor', 'entity.name.function.preprocessor'],\n settings: {\n foreground: '#0000ff'\n }\n },\n {\n scope: 'meta.preprocessor.string',\n settings: {\n foreground: '#a31515'\n }\n },\n {\n scope: 'meta.preprocessor.numeric',\n settings: {\n foreground: '#098658'\n }\n },\n {\n scope: 'meta.structure.dictionary.key.python',\n settings: {\n foreground: '#0451a5'\n }\n },\n {\n scope: 'storage',\n settings: {\n foreground: '#0000ff'\n }\n },\n {\n scope: 'storage.type',\n settings: {\n foreground: '#0000ff'\n }\n },\n {\n scope: ['storage.modifier', 'keyword.operator.noexcept'],\n settings: {\n foreground: '#0000ff'\n }\n },\n {\n scope: ['string', 'meta.embedded.assembly'],\n settings: {\n foreground: '#a31515'\n }\n },\n {\n scope: [\n 'string.comment.buffered.block.pug',\n 'string.quoted.pug',\n 'string.interpolated.pug',\n 'string.unquoted.plain.in.yaml',\n 'string.unquoted.plain.out.yaml',\n 'string.unquoted.block.yaml',\n 'string.quoted.single.yaml',\n 'string.quoted.double.xml',\n 'string.quoted.single.xml',\n 'string.unquoted.cdata.xml',\n 'string.quoted.double.html',\n 'string.quoted.single.html',\n 'string.unquoted.html',\n 'string.quoted.single.handlebars',\n 'string.quoted.double.handlebars'\n ],\n settings: {\n foreground: '#0000ff'\n }\n },\n {\n scope: 'string.regexp',\n settings: {\n foreground: '#811f3f'\n }\n },\n {\n name: 'String interpolation',\n scope: [\n 'punctuation.definition.template-expression.begin',\n 'punctuation.definition.template-expression.end',\n 'punctuation.section.embedded'\n ],\n settings: {\n foreground: '#0000ff'\n }\n },\n {\n name: 'Reset JavaScript string interpolation expression',\n scope: ['meta.template.expression'],\n settings: {\n foreground: '#000000'\n }\n },\n {\n scope: [\n 'support.constant.property-value',\n 'support.constant.font-name',\n 'support.constant.media-type',\n 'support.constant.media',\n 'constant.other.color.rgb-value',\n 'constant.other.rgb-value',\n 'support.constant.color'\n ],\n settings: {\n foreground: '#0451a5'\n }\n },\n {\n scope: [\n 'support.type.vendored.property-name',\n 'support.type.property-name',\n 'variable.css',\n 'variable.scss',\n 'variable.other.less',\n 'source.coffee.embedded'\n ],\n settings: {\n foreground: '#ff0000'\n }\n },\n {\n scope: ['support.type.property-name.json'],\n settings: {\n foreground: '#0451a5'\n }\n },\n {\n scope: 'keyword',\n settings: {\n foreground: '#0000ff'\n }\n },\n {\n scope: 'keyword.control',\n settings: {\n foreground: '#0000ff'\n }\n },\n {\n scope: 'keyword.operator',\n settings: {\n foreground: '#000000'\n }\n },\n {\n scope: [\n 'keyword.operator.new',\n 'keyword.operator.expression',\n 'keyword.operator.cast',\n 'keyword.operator.sizeof',\n 'keyword.operator.alignof',\n 'keyword.operator.typeid',\n 'keyword.operator.alignas',\n 'keyword.operator.instanceof',\n 'keyword.operator.logical.python',\n 'keyword.operator.wordlike'\n ],\n settings: {\n foreground: '#0000ff'\n }\n },\n {\n scope: 'keyword.other.unit',\n settings: {\n foreground: '#098658'\n }\n },\n {\n scope: ['punctuation.section.embedded.begin.php', 'punctuation.section.embedded.end.php'],\n settings: {\n foreground: '#800000'\n }\n },\n {\n scope: 'support.function.git-rebase',\n settings: {\n foreground: '#0451a5'\n }\n },\n {\n scope: 'constant.sha.git-rebase',\n settings: {\n foreground: '#098658'\n }\n },\n {\n name: 'coloring of the Java import and package identifiers',\n scope: ['storage.modifier.import.java', 'variable.language.wildcard.java', 'storage.modifier.package.java'],\n settings: {\n foreground: '#000000'\n }\n },\n {\n name: 'this.self',\n scope: 'variable.language',\n settings: {\n foreground: '#0000ff'\n }\n },\n \n // adds rules to the light vs rules\n {\n name: 'Function declarations',\n scope: [\n 'entity.name.function',\n 'support.function',\n 'support.constant.handlebars',\n 'source.powershell variable.other.member',\n 'entity.name.operator.custom-literal' // See https://en.cppreference.com/w/cpp/language/user_literal\n ],\n settings: {\n foreground: '#795E26'\n }\n },\n {\n name: 'Types declaration and references',\n scope: [\n 'support.class',\n 'support.type',\n 'entity.name.type',\n 'entity.name.namespace',\n 'entity.other.attribute',\n 'entity.name.scope-resolution',\n 'entity.name.class',\n 'storage.type.numeric.go',\n 'storage.type.byte.go',\n 'storage.type.boolean.go',\n 'storage.type.string.go',\n 'storage.type.uintptr.go',\n 'storage.type.error.go',\n 'storage.type.rune.go',\n 'storage.type.cs',\n 'storage.type.generic.cs',\n 'storage.type.modifier.cs',\n 'storage.type.variable.cs',\n 'storage.type.annotation.java',\n 'storage.type.generic.java',\n 'storage.type.java',\n 'storage.type.object.array.java',\n 'storage.type.primitive.array.java',\n 'storage.type.primitive.java',\n 'storage.type.token.java',\n 'storage.type.groovy',\n 'storage.type.annotation.groovy',\n 'storage.type.parameters.groovy',\n 'storage.type.generic.groovy',\n 'storage.type.object.array.groovy',\n 'storage.type.primitive.array.groovy',\n 'storage.type.primitive.groovy'\n ],\n settings: {\n foreground: '#0f96be'\n }\n },\n {\n name: 'Types declaration and references, TS grammar specific',\n scope: [\n 'meta.type.cast.expr',\n 'meta.type.new.expr',\n 'support.constant.math',\n 'support.constant.dom',\n 'support.constant.json',\n 'entity.other.inherited-class'\n ],\n settings: {\n foreground: '#267f99'\n }\n },\n {\n name: 'Control flow / Special keywords',\n scope: [\n 'keyword.control',\n 'source.cpp keyword.operator.new',\n 'source.cpp keyword.operator.delete',\n 'keyword.other.using',\n 'keyword.other.operator',\n 'entity.name.operator'\n ],\n settings: {\n foreground: '#AF00DB'\n }\n },\n {\n name: 'Variable and parameter name',\n scope: [\n 'variable',\n 'meta.definition.variable.name',\n 'support.variable',\n 'entity.name.variable',\n 'constant.other.placeholder' // placeholders in strings\n ],\n settings: {\n foreground: '#000000'\n }\n },\n {\n name: 'Constants and enums',\n scope: ['variable.other.constant', 'variable.other.enummember'],\n settings: {\n foreground: '#0070C1'\n }\n },\n {\n name: 'Object keys, TS grammar specific',\n scope: ['meta.object-literal.key'],\n settings: {\n foreground: '#001080'\n }\n },\n {\n name: 'CSS property value',\n scope: [\n 'support.constant.property-value',\n 'support.constant.font-name',\n 'support.constant.media-type',\n 'support.constant.media',\n 'constant.other.color.rgb-value',\n 'constant.other.rgb-value',\n 'support.constant.color'\n ],\n settings: {\n foreground: '#0451a5'\n }\n },\n {\n name: 'Regular expression groups',\n scope: [\n 'punctuation.definition.group.regexp',\n 'punctuation.definition.group.assertion.regexp',\n 'punctuation.definition.character-class.regexp',\n 'punctuation.character.set.begin.regexp',\n 'punctuation.character.set.end.regexp',\n 'keyword.operator.negation.regexp',\n 'support.other.parenthesis.regexp'\n ],\n settings: {\n foreground: '#d16969'\n }\n },\n {\n scope: [\n 'constant.character.character-class.regexp',\n 'constant.other.character-class.set.regexp',\n 'constant.other.character-class.regexp',\n 'constant.character.set.regexp'\n ],\n settings: {\n foreground: '#811f3f'\n }\n },\n {\n scope: 'keyword.operator.quantifier.regexp',\n settings: {\n foreground: '#000000'\n }\n },\n {\n scope: ['keyword.operator.or.regexp', 'keyword.control.anchor.regexp'],\n settings: {\n foreground: '#EE0000'\n }\n },\n {\n scope: 'constant.character',\n settings: {\n foreground: '#0000ff'\n }\n },\n {\n scope: 'constant.character.escape',\n settings: {\n foreground: '#EE0000'\n }\n },\n {\n scope: 'entity.name.label',\n settings: {\n foreground: '#000000'\n }\n },\n { scope: 'keyword.operator', settings: { foreground: '#f00' } },\n { scope: 'keyword.operator.instanceof', settings: { foreground: '#f00' } },\n { scope: 'keyword.operator.logical', settings: { foreground: '#f00' } },\n { scope: 'keyword.operator.logical.python', settings: { foreground: '#f00' } },\n \n // { \"scope\": \"keyword.control\", \"settings\": { \"foreground\": \"#bc00eb\" } }\n \n // { \"scope\": \"support.type.property-name\", \"settings\": { \"foreground\": \"#0451a5\" } },\n { scope: 'support.type.property-name', settings: { foreground: '#000000' } },\n \n // { \"scope\": \"variable.other\", \"settings\": { \"foreground\": \"#000000\", \"fontStyle\": \"\" } },\n // { \"scope\": \"variable.parameter\", \"settings\": { \"foreground\": \"#000000\", \"fontStyle\": \"\" } },\n { scope: 'variable', settings: { foreground: '#000000', fontStyle: '' } },\n // { \"scope\": \"variable.other.property\", \"settings\": { \"foreground\": \"#0115AF\" } },\n { scope: 'variable.other.constant', settings: { foreground: '#000000' } },\n \n { scope: 'keyword.operator.expression.typeof.js', settings: { foreground: '#f00' } },\n { scope: 'storage.type', settings: { foreground: '#0000ee' } }, // const\n { scope: 'storage.modifier', settings: { foreground: '#0000ee' } },\n { scope: 'constant.language', settings: { foreground: '#0000ee' } },\n { scope: 'constant.numeric', settings: { foreground: '#00a000' } }, // number\n { scope: 'variable.language.this', settings: { foreground: '#267f99' } },\n { scope: 'string.quoted.docstring.multi.python', settings: { foreground: '#000000' } },\n { scope: 'punctuation.separator.delimiter.c', settings: { foreground: '#f00' } },\n { scope: 'punctuation.separator.pointer-access.c', settings: { foreground: '#f00' } },\n { scope: 'entity.name.tag.pug', settings: { foreground: '#f00' } },\n { scope: 'entity.other.attribute-name.id.pug', settings: { foreground: '#722dd2' } },\n { scope: 'entity.other.attribute-name.class.pug', settings: { foreground: '#267f99' } },\n { scope: 'entity.other.attribute-name.tag.pug', settings: { foreground: '#8e5e1a' } },\n { scope: 'entity.name.tag', settings: { foreground: '#000000', fontStyle: 'bold' } },\n \n { scope: 'punctuation.definition.tag', settings: { foreground: '#000000', fontStyle: 'bold' } },\n \n \n // function: bold\n { scope: 'entity.name.function', settings: { foreground: '#000000', fontStyle: 'bold' } },\n { scope: 'support.function', settings: { foreground: '#000000', fontStyle: 'bold' } },\n \n { scope: 'constant.language.module.http', settings: { foreground: '#00f' } },\n { scope: 'constant.language.directive.module', settings: { foreground: '#00f' } },\n { scope: 'constant.language.directive.module.main', settings: { foreground: '#f00', fontStyle: 'bold' } },\n \n { scope: 'meta.decorator.dolphindb', settings: { foreground: '#aa6f00' } },\n \n { scope: 'punctuation.definition.string.begin.json.comments', settings: { foreground: '#111' } },\n { scope: 'punctuation.definition.string.end.json.comments', settings: { foreground: '#111' } },\n { scope: 'punctuation.support.type.property-name.begin.json.comments', settings: { foreground: '#111' } },\n { scope: 'punctuation.support.type.property-name.end.json.comments', settings: { foreground: '#111' } }\n ]\n}\n"]}
File without changes