@minnowdb/core 0.7.0 → 0.7.1

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.
Files changed (95) hide show
  1. package/dist/block-format/block.js +254 -325
  2. package/dist/block-format/checksum.js +30 -52
  3. package/dist/block-format/codecs.js +112 -125
  4. package/dist/block-format/column.js +187 -205
  5. package/dist/block-format/index.js +5 -1
  6. package/dist/block-format/physical.js +371 -387
  7. package/dist/block-format/types.js +4 -1
  8. package/dist/block-format/unicode.js +30 -39
  9. package/dist/date-value.js +67 -78
  10. package/dist/engine/artifact-cache.js +106 -116
  11. package/dist/engine/batch.js +36 -44
  12. package/dist/engine/buffered-writer.js +156 -158
  13. package/dist/engine/byte-estimates.js +20 -22
  14. package/dist/engine/cache-limits.js +24 -25
  15. package/dist/engine/cancellation.js +5 -3
  16. package/dist/engine/catalog.js +64 -73
  17. package/dist/engine/client.js +715 -780
  18. package/dist/engine/database.js +15941 -19313
  19. package/dist/engine/defaults.js +104 -111
  20. package/dist/engine/errors.js +113 -128
  21. package/dist/engine/fts.js +233 -280
  22. package/dist/engine/group-index.js +287 -321
  23. package/dist/engine/index.js +23 -12
  24. package/dist/engine/join-index.js +177 -186
  25. package/dist/engine/keyed-live.js +168 -173
  26. package/dist/engine/live-api.js +0 -1
  27. package/dist/engine/live-equal.js +32 -37
  28. package/dist/engine/live.js +603 -647
  29. package/dist/engine/memory.js +109 -111
  30. package/dist/engine/optimizer.d.ts +19 -1
  31. package/dist/engine/optimizer.js +2633 -2934
  32. package/dist/engine/point-read.js +122 -182
  33. package/dist/engine/query-api.js +12 -3
  34. package/dist/engine/query-cache.js +61 -69
  35. package/dist/engine/query.d.ts +6 -0
  36. package/dist/engine/query.js +8503 -9980
  37. package/dist/engine/result-wire.js +221 -252
  38. package/dist/engine/schema-wire.js +97 -112
  39. package/dist/engine/schema.js +1099 -1254
  40. package/dist/engine/sort-keys.js +315 -389
  41. package/dist/engine/sql-domains.js +646 -769
  42. package/dist/engine/sql-driver.js +0 -1
  43. package/dist/engine/sql-functions.js +1031 -1125
  44. package/dist/engine/sql-json.js +199 -218
  45. package/dist/engine/sql-semantics.js +572 -639
  46. package/dist/engine/typed-live.js +271 -293
  47. package/dist/engine/vector.js +4484 -5145
  48. package/dist/engine/worker-host.d.ts +8 -63
  49. package/dist/engine/worker-host.js +28 -1130
  50. package/dist/engine/worker-indexeddb.d.ts +1 -0
  51. package/dist/engine/worker-indexeddb.js +3 -0
  52. package/dist/engine/worker-memory.d.ts +1 -0
  53. package/dist/engine/worker-memory.js +3 -0
  54. package/dist/engine/worker-opfs.d.ts +1 -0
  55. package/dist/engine/worker-opfs.js +3 -0
  56. package/dist/engine/worker-server.d.ts +93 -0
  57. package/dist/engine/worker-server.js +999 -0
  58. package/dist/engine/worker-store-indexeddb.d.ts +2 -0
  59. package/dist/engine/worker-store-indexeddb.js +11 -0
  60. package/dist/engine/worker-store-memory.d.ts +2 -0
  61. package/dist/engine/worker-store-memory.js +6 -0
  62. package/dist/engine/worker-store-opfs.d.ts +2 -0
  63. package/dist/engine/worker-store-opfs.js +9 -0
  64. package/dist/engine/worker.js +0 -12
  65. package/dist/engine/write-block-planner.js +93 -100
  66. package/dist/plan/index.js +15 -16
  67. package/dist/plan/model.d.ts +6 -0
  68. package/dist/plan/model.js +20 -27
  69. package/dist/storage/index.js +0 -12
  70. package/dist/storage/indexeddb.js +11776 -13171
  71. package/dist/storage/memory.js +1198 -1241
  72. package/dist/storage/opfs/files.js +238 -295
  73. package/dist/storage/opfs/index.js +9 -3
  74. package/dist/storage/opfs/leader.js +4386 -4856
  75. package/dist/storage/opfs/rpc.js +223 -259
  76. package/dist/storage/opfs/snapshot-ledger.js +219 -260
  77. package/dist/storage/opfs/store.js +884 -1003
  78. package/dist/storage/persistence.js +59 -74
  79. package/dist/storage/snapshot-stream.js +788 -826
  80. package/dist/storage/snapshot.js +36 -37
  81. package/dist/storage/toolkit/extents.js +444 -520
  82. package/dist/storage/toolkit/index.js +28 -29
  83. package/dist/storage/toolkit/record-core.js +5792 -6377
  84. package/dist/storage/toolkit/sync-file.js +34 -42
  85. package/dist/storage/toolkit/wal.js +92 -127
  86. package/dist/storage/toolkit/wire.js +232 -256
  87. package/dist/storage/types.js +2948 -3250
  88. package/dist/testing/block-store-conformance.js +1556 -1629
  89. package/dist/testing/index.js +310 -291
  90. package/dist/testing/opfs-shim.js +280 -312
  91. package/dist/testing/simulator.js +496 -534
  92. package/dist/testing/sqllogictest.js +425 -365
  93. package/dist/transactions/index.js +1464 -1712
  94. package/dist/worker-protocol/index.js +70 -69
  95. package/package.json +20 -2
@@ -1,280 +1,249 @@
1
1
  import { dateMilliseconds } from "../date-value.js";
2
2
  import { unknownColumnDomains } from "./query.js";
3
- export function encodeQueryResult(result) {
4
- return encodeRows(result.columns, result.rows, result.columnDomains);
3
+ function encodeQueryResult(result) {
4
+ return encodeRows(result.columns, result.rows, result.columnDomains);
5
5
  }
6
- /**
7
- * Encodes a bare row array (`run()` returns rows without a column list). Every row of one result
8
- * carries the same keys in the same order, so the first row names the columns.
9
- */
10
- export function encodeQueryRows(rows) {
11
- const first = rows[0];
12
- const columns = first === undefined ? [] : Object.keys(first);
13
- return encodeRows(columns, rows, unknownColumnDomains(columns));
6
+ function encodeQueryRows(rows) {
7
+ const first = rows[0];
8
+ const columns = first === void 0 ? [] : Object.keys(first);
9
+ return encodeRows(columns, rows, unknownColumnDomains(columns));
14
10
  }
15
- export function decodeQueryResult(payload) {
16
- if (!isWireQueryResult(payload)) {
17
- throw new TypeError("Expected a columnar query result frame");
18
- }
19
- const columns = [...payload.columns];
20
- if (payload.values.length !== columns.length || payload.columnDomains.length !== columns.length) {
21
- throw new TypeError("Columnar result frame metadata is not aligned");
22
- }
23
- const columnDomains = structuredClone(payload.columnDomains);
24
- const rows = [];
25
- for (let index = 0; index < payload.rowCount; index += 1)
26
- rows.push({});
27
- // Column by column: each fill loop stores one property name into every row, which the engine
28
- // runs noticeably faster than visiting every column of each row in turn.
29
- for (const [position, name] of columns.entries()) {
30
- const column = payload.values[position];
31
- if (column === undefined)
32
- throw new TypeError("Columnar result frame is missing a column");
33
- fillColumn(rows, name, column);
34
- }
35
- return { columns, columnDomains, rows };
11
+ function decodeQueryResult(payload) {
12
+ if (!isWireQueryResult(payload)) {
13
+ throw new TypeError("Expected a columnar query result frame");
14
+ }
15
+ const columns = [...payload.columns];
16
+ if (payload.values.length !== columns.length || payload.columnDomains.length !== columns.length) {
17
+ throw new TypeError("Columnar result frame metadata is not aligned");
18
+ }
19
+ const columnDomains = structuredClone(payload.columnDomains);
20
+ const rows = [];
21
+ for (let index = 0; index < payload.rowCount; index += 1)
22
+ rows.push({});
23
+ for (const [position, name] of columns.entries()) {
24
+ const column = payload.values[position];
25
+ if (column === void 0)
26
+ throw new TypeError("Columnar result frame is missing a column");
27
+ fillColumn(rows, name, column);
28
+ }
29
+ return { columns, columnDomains, rows };
36
30
  }
37
- export function isWireQueryResult(value) {
38
- return (typeof value === "object" &&
39
- value !== null &&
40
- value.kind === "columnar-result" &&
41
- Array.isArray(value.columns) &&
42
- Array.isArray(value.columnDomains) &&
43
- Array.isArray(value.values) &&
44
- typeof value.rowCount === "number");
31
+ function isWireQueryResult(value) {
32
+ return typeof value === "object" && value !== null && value.kind === "columnar-result" && Array.isArray(value.columns) && Array.isArray(value.columnDomains) && Array.isArray(value.values) && typeof value.rowCount === "number";
45
33
  }
46
34
  function encodeRows(columns, rows, columnDomains) {
47
- if (columnDomains.length !== columns.length) {
48
- throw new TypeError("Query result column domains must align with the result columns");
35
+ if (columnDomains.length !== columns.length) {
36
+ throw new TypeError("Query result column domains must align with the result columns");
37
+ }
38
+ const transfer = [];
39
+ const values = columns.map((name) => {
40
+ const column = encodeColumn(name, rows);
41
+ if (column.kind === "number" || column.kind === "boolean" || column.kind === "datetime") {
42
+ transfer.push(column.values.buffer);
43
+ if (column.nulls !== void 0)
44
+ transfer.push(column.nulls.buffer);
45
+ } else if (column.kind === "string") {
46
+ transfer.push(column.offsets.buffer);
47
+ if (column.nulls !== void 0)
48
+ transfer.push(column.nulls.buffer);
49
49
  }
50
- const transfer = [];
51
- const values = columns.map((name) => {
52
- const column = encodeColumn(name, rows);
53
- if (column.kind === "number" || column.kind === "boolean" || column.kind === "datetime") {
54
- transfer.push(column.values.buffer);
55
- if (column.nulls !== undefined)
56
- transfer.push(column.nulls.buffer);
57
- }
58
- else if (column.kind === "string") {
59
- transfer.push(column.offsets.buffer);
60
- if (column.nulls !== undefined)
61
- transfer.push(column.nulls.buffer);
62
- }
63
- return column;
64
- });
65
- return {
66
- payload: {
67
- kind: "columnar-result",
68
- columns: [...columns],
69
- columnDomains: structuredClone([...columnDomains]),
70
- rowCount: rows.length,
71
- values,
72
- },
73
- transfer,
74
- };
50
+ return column;
51
+ });
52
+ return {
53
+ payload: {
54
+ kind: "columnar-result",
55
+ columns: [...columns],
56
+ columnDomains: structuredClone([...columnDomains]),
57
+ rowCount: rows.length,
58
+ values
59
+ },
60
+ transfer
61
+ };
75
62
  }
76
- /**
77
- * The first non-null value picks the column's typed form; a later value of another type demotes
78
- * the whole column to the mixed form, which is rare enough to restart from scratch rather than
79
- * to plan for.
80
- */
81
63
  function encodeColumn(name, rows) {
82
- const rowCount = rows.length;
83
- let start = 0;
84
- while (start < rowCount && (rows[start]?.[name] ?? null) === null)
85
- start += 1;
86
- const first = rows[start]?.[name] ?? null;
87
- if (first === null)
88
- return { kind: "null" };
89
- if (typeof first === "number") {
90
- const values = new Float64Array(rowCount);
91
- let nulls = start === 0 ? undefined : nullMask(rowCount, start);
92
- for (let index = start; index < rowCount; index += 1) {
93
- const value = rows[index]?.[name] ?? null;
94
- if (value === null) {
95
- nulls ??= new Uint8Array(rowCount);
96
- nulls[index] = 1;
97
- }
98
- else if (typeof value === "number") {
99
- values[index] = value;
100
- }
101
- else {
102
- return encodeMixed(name, rows);
103
- }
104
- }
105
- return nulls === undefined ? { kind: "number", values } : { kind: "number", values, nulls };
64
+ const rowCount = rows.length;
65
+ let start = 0;
66
+ while (start < rowCount && (rows[start]?.[name] ?? null) === null)
67
+ start += 1;
68
+ const first = rows[start]?.[name] ?? null;
69
+ if (first === null)
70
+ return { kind: "null" };
71
+ if (typeof first === "number") {
72
+ const values = new Float64Array(rowCount);
73
+ let nulls = start === 0 ? void 0 : nullMask(rowCount, start);
74
+ for (let index = start; index < rowCount; index += 1) {
75
+ const value = rows[index]?.[name] ?? null;
76
+ if (value === null) {
77
+ nulls ??= new Uint8Array(rowCount);
78
+ nulls[index] = 1;
79
+ } else if (typeof value === "number") {
80
+ values[index] = value;
81
+ } else {
82
+ return encodeMixed(name, rows);
83
+ }
106
84
  }
107
- if (typeof first === "boolean") {
108
- const values = new Uint8Array(rowCount);
109
- let nulls = start === 0 ? undefined : nullMask(rowCount, start);
110
- for (let index = start; index < rowCount; index += 1) {
111
- const value = rows[index]?.[name] ?? null;
112
- if (value === null) {
113
- nulls ??= new Uint8Array(rowCount);
114
- nulls[index] = 1;
115
- }
116
- else if (typeof value === "boolean") {
117
- values[index] = value ? 1 : 0;
118
- }
119
- else {
120
- return encodeMixed(name, rows);
121
- }
122
- }
123
- return nulls === undefined ? { kind: "boolean", values } : { kind: "boolean", values, nulls };
85
+ return nulls === void 0 ? { kind: "number", values } : { kind: "number", values, nulls };
86
+ }
87
+ if (typeof first === "boolean") {
88
+ const values = new Uint8Array(rowCount);
89
+ let nulls = start === 0 ? void 0 : nullMask(rowCount, start);
90
+ for (let index = start; index < rowCount; index += 1) {
91
+ const value = rows[index]?.[name] ?? null;
92
+ if (value === null) {
93
+ nulls ??= new Uint8Array(rowCount);
94
+ nulls[index] = 1;
95
+ } else if (typeof value === "boolean") {
96
+ values[index] = value ? 1 : 0;
97
+ } else {
98
+ return encodeMixed(name, rows);
99
+ }
124
100
  }
125
- if (first instanceof Date) {
126
- const values = new Float64Array(rowCount);
127
- let nulls = start === 0 ? undefined : nullMask(rowCount, start);
128
- for (let index = start; index < rowCount; index += 1) {
129
- const value = rows[index]?.[name] ?? null;
130
- if (value === null) {
131
- nulls ??= new Uint8Array(rowCount);
132
- nulls[index] = 1;
133
- }
134
- else if (value instanceof Date) {
135
- values[index] = dateMilliseconds(value);
136
- }
137
- else {
138
- return encodeMixed(name, rows);
139
- }
140
- }
141
- return nulls === undefined ? { kind: "datetime", values } : { kind: "datetime", values, nulls };
101
+ return nulls === void 0 ? { kind: "boolean", values } : { kind: "boolean", values, nulls };
102
+ }
103
+ if (first instanceof Date) {
104
+ const values = new Float64Array(rowCount);
105
+ let nulls = start === 0 ? void 0 : nullMask(rowCount, start);
106
+ for (let index = start; index < rowCount; index += 1) {
107
+ const value = rows[index]?.[name] ?? null;
108
+ if (value === null) {
109
+ nulls ??= new Uint8Array(rowCount);
110
+ nulls[index] = 1;
111
+ } else if (value instanceof Date) {
112
+ values[index] = dateMilliseconds(value);
113
+ } else {
114
+ return encodeMixed(name, rows);
115
+ }
142
116
  }
143
- if (typeof first === "string") {
144
- const offsets = new Uint32Array(rowCount + 1);
145
- let nulls = start === 0 ? undefined : nullMask(rowCount, start);
146
- const parts = [];
147
- let length = 0;
148
- for (let index = start; index < rowCount; index += 1) {
149
- const value = rows[index]?.[name] ?? null;
150
- if (value === null) {
151
- nulls ??= new Uint8Array(rowCount);
152
- nulls[index] = 1;
153
- }
154
- else if (typeof value === "string") {
155
- parts.push(value);
156
- length += value.length;
157
- }
158
- else {
159
- return encodeMixed(name, rows);
160
- }
161
- offsets[index + 1] = length;
162
- }
163
- const text = parts.join("");
164
- return nulls === undefined
165
- ? { kind: "string", text, offsets }
166
- : { kind: "string", text, offsets, nulls };
117
+ return nulls === void 0 ? { kind: "datetime", values } : { kind: "datetime", values, nulls };
118
+ }
119
+ if (typeof first === "string") {
120
+ const offsets = new Uint32Array(rowCount + 1);
121
+ let nulls = start === 0 ? void 0 : nullMask(rowCount, start);
122
+ const parts = [];
123
+ let length = 0;
124
+ for (let index = start; index < rowCount; index += 1) {
125
+ const value = rows[index]?.[name] ?? null;
126
+ if (value === null) {
127
+ nulls ??= new Uint8Array(rowCount);
128
+ nulls[index] = 1;
129
+ } else if (typeof value === "string") {
130
+ parts.push(value);
131
+ length += value.length;
132
+ } else {
133
+ return encodeMixed(name, rows);
134
+ }
135
+ offsets[index + 1] = length;
167
136
  }
168
- return encodeMixed(name, rows);
137
+ const text = parts.join("");
138
+ return nulls === void 0 ? { kind: "string", text, offsets } : { kind: "string", text, offsets, nulls };
139
+ }
140
+ return encodeMixed(name, rows);
169
141
  }
170
142
  function encodeMixed(name, rows) {
171
- return { kind: "mixed", values: rows.map((row) => row[name] ?? null) };
143
+ return { kind: "mixed", values: rows.map((row) => row[name] ?? null) };
172
144
  }
173
- /** A null mask whose first `nullCount` rows are already null. */
174
145
  function nullMask(rowCount, nullCount) {
175
- const nulls = new Uint8Array(rowCount);
176
- nulls.fill(1, 0, nullCount);
177
- return nulls;
146
+ const nulls = new Uint8Array(rowCount);
147
+ nulls.fill(1, 0, nullCount);
148
+ return nulls;
178
149
  }
179
- /** Stores one decoded column into every row under `name`. */
180
150
  function fillColumn(rows, name, column) {
181
- if (name === "__proto__") {
182
- // Assignment through `row["__proto__"]` would set the prototype; this column goes through
183
- // Object.defineProperty, which is what the engine itself does for the name.
184
- const values = decodeColumnValues(column, rows.length);
185
- let index = 0;
186
- for (const row of rows) {
187
- Object.defineProperty(row, name, {
188
- value: values[index] ?? null,
189
- enumerable: true,
190
- configurable: true,
191
- writable: true,
192
- });
193
- index += 1;
194
- }
195
- return;
151
+ if (name === "__proto__") {
152
+ const values = decodeColumnValues(column, rows.length);
153
+ let index2 = 0;
154
+ for (const row of rows) {
155
+ Object.defineProperty(row, name, {
156
+ value: values[index2] ?? null,
157
+ enumerable: true,
158
+ configurable: true,
159
+ writable: true
160
+ });
161
+ index2 += 1;
196
162
  }
197
- let index = 0;
198
- switch (column.kind) {
199
- case "number": {
200
- const { values, nulls } = column;
201
- if (nulls === undefined) {
202
- for (const row of rows) {
203
- row[name] = values[index] ?? 0;
204
- index += 1;
205
- }
206
- }
207
- else {
208
- for (const row of rows) {
209
- row[name] = nulls[index] === 1 ? null : (values[index] ?? 0);
210
- index += 1;
211
- }
212
- }
213
- return;
214
- }
215
- case "boolean": {
216
- const { values, nulls } = column;
217
- for (const row of rows) {
218
- row[name] = nulls?.[index] === 1 ? null : values[index] === 1;
219
- index += 1;
220
- }
221
- return;
222
- }
223
- case "datetime": {
224
- const { values, nulls } = column;
225
- for (const row of rows) {
226
- row[name] = nulls?.[index] === 1 ? null : new Date(values[index] ?? 0);
227
- index += 1;
228
- }
229
- return;
230
- }
231
- case "string": {
232
- const { text, offsets, nulls } = column;
233
- for (const row of rows) {
234
- row[name] =
235
- nulls?.[index] === 1 ? null : text.slice(offsets[index] ?? 0, offsets[index + 1] ?? 0);
236
- index += 1;
237
- }
238
- return;
163
+ return;
164
+ }
165
+ let index = 0;
166
+ switch (column.kind) {
167
+ case "number": {
168
+ const { values, nulls } = column;
169
+ if (nulls === void 0) {
170
+ for (const row of rows) {
171
+ row[name] = values[index] ?? 0;
172
+ index += 1;
239
173
  }
240
- case "mixed": {
241
- const { values } = column;
242
- for (const row of rows) {
243
- row[name] = values[index] ?? null;
244
- index += 1;
245
- }
246
- return;
174
+ } else {
175
+ for (const row of rows) {
176
+ row[name] = nulls[index] === 1 ? null : values[index] ?? 0;
177
+ index += 1;
247
178
  }
248
- case "null":
249
- for (const row of rows)
250
- row[name] = null;
179
+ }
180
+ return;
181
+ }
182
+ case "boolean": {
183
+ const { values, nulls } = column;
184
+ for (const row of rows) {
185
+ row[name] = nulls?.[index] === 1 ? null : values[index] === 1;
186
+ index += 1;
187
+ }
188
+ return;
251
189
  }
190
+ case "datetime": {
191
+ const { values, nulls } = column;
192
+ for (const row of rows) {
193
+ row[name] = nulls?.[index] === 1 ? null : new Date(values[index] ?? 0);
194
+ index += 1;
195
+ }
196
+ return;
197
+ }
198
+ case "string": {
199
+ const { text, offsets, nulls } = column;
200
+ for (const row of rows) {
201
+ row[name] = nulls?.[index] === 1 ? null : text.slice(offsets[index] ?? 0, offsets[index + 1] ?? 0);
202
+ index += 1;
203
+ }
204
+ return;
205
+ }
206
+ case "mixed": {
207
+ const { values } = column;
208
+ for (const row of rows) {
209
+ row[name] = values[index] ?? null;
210
+ index += 1;
211
+ }
212
+ return;
213
+ }
214
+ case "null":
215
+ for (const row of rows)
216
+ row[name] = null;
217
+ }
252
218
  }
253
- /** One column back into plain values, for the one name that cannot be assigned through. */
254
219
  function decodeColumnValues(column, rowCount) {
255
- const values = [];
256
- for (let index = 0; index < rowCount; index += 1) {
257
- switch (column.kind) {
258
- case "number":
259
- values.push(column.nulls?.[index] === 1 ? null : (column.values[index] ?? 0));
260
- break;
261
- case "boolean":
262
- values.push(column.nulls?.[index] === 1 ? null : column.values[index] === 1);
263
- break;
264
- case "datetime":
265
- values.push(column.nulls?.[index] === 1 ? null : new Date(column.values[index] ?? 0));
266
- break;
267
- case "string":
268
- values.push(column.nulls?.[index] === 1
269
- ? null
270
- : column.text.slice(column.offsets[index] ?? 0, column.offsets[index + 1] ?? 0));
271
- break;
272
- case "mixed":
273
- values.push(column.values[index] ?? null);
274
- break;
275
- case "null":
276
- values.push(null);
277
- }
220
+ const values = [];
221
+ for (let index = 0; index < rowCount; index += 1) {
222
+ switch (column.kind) {
223
+ case "number":
224
+ values.push(column.nulls?.[index] === 1 ? null : column.values[index] ?? 0);
225
+ break;
226
+ case "boolean":
227
+ values.push(column.nulls?.[index] === 1 ? null : column.values[index] === 1);
228
+ break;
229
+ case "datetime":
230
+ values.push(column.nulls?.[index] === 1 ? null : new Date(column.values[index] ?? 0));
231
+ break;
232
+ case "string":
233
+ values.push(column.nulls?.[index] === 1 ? null : column.text.slice(column.offsets[index] ?? 0, column.offsets[index + 1] ?? 0));
234
+ break;
235
+ case "mixed":
236
+ values.push(column.values[index] ?? null);
237
+ break;
238
+ case "null":
239
+ values.push(null);
278
240
  }
279
- return values;
241
+ }
242
+ return values;
280
243
  }
244
+ export {
245
+ decodeQueryResult,
246
+ encodeQueryResult,
247
+ encodeQueryRows,
248
+ isWireQueryResult
249
+ };