@json-eval-rs/node 0.0.45 → 0.0.47
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 +1 -1
- package/pkg/json_eval_rs.d.ts +56 -56
- package/pkg/json_eval_rs.js +179 -72
- package/pkg/json_eval_rs_bg.wasm +0 -0
- package/pkg/json_eval_rs_bg.wasm.d.ts +6 -6
package/package.json
CHANGED
package/pkg/json_eval_rs.d.ts
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
/* tslint:disable */
|
|
2
2
|
/* eslint-disable */
|
|
3
|
-
/**
|
|
4
|
-
* Get library version (alias)
|
|
5
|
-
*/
|
|
6
|
-
export function version(): string;
|
|
7
3
|
/**
|
|
8
4
|
* Initialize the library (sets up panic hook)
|
|
9
5
|
*/
|
|
10
6
|
export function init(): void;
|
|
7
|
+
/**
|
|
8
|
+
* Get library version (alias)
|
|
9
|
+
*/
|
|
10
|
+
export function version(): string;
|
|
11
11
|
/**
|
|
12
12
|
* Get the library version
|
|
13
13
|
*/
|
|
@@ -20,7 +20,7 @@ export class JSONEvalWasm {
|
|
|
20
20
|
[Symbol.dispose](): void;
|
|
21
21
|
/**
|
|
22
22
|
* Evaluate and return as JsValue for direct JavaScript object access
|
|
23
|
-
*
|
|
23
|
+
*
|
|
24
24
|
* @param data - JSON data string
|
|
25
25
|
* @param context - Optional context data JSON string
|
|
26
26
|
* @returns Evaluated schema as JavaScript object
|
|
@@ -34,7 +34,7 @@ export class JSONEvalWasm {
|
|
|
34
34
|
compileLogic(logic_str: string): number;
|
|
35
35
|
/**
|
|
36
36
|
* Evaluate dependents when a field changes (returns array of changes as JSON string)
|
|
37
|
-
*
|
|
37
|
+
*
|
|
38
38
|
* @param changedPath - Path of the field that changed
|
|
39
39
|
* @param data - Optional updated JSON data string
|
|
40
40
|
* @param context - Optional context data JSON string
|
|
@@ -51,17 +51,17 @@ export class JSONEvalWasm {
|
|
|
51
51
|
compileAndRunLogic(logic_str: string, data?: string | null, context?: string | null): any;
|
|
52
52
|
/**
|
|
53
53
|
* Evaluate dependents and return as JavaScript object
|
|
54
|
-
*
|
|
54
|
+
*
|
|
55
55
|
* @param changedPathsJson - JSON array of field paths that changed
|
|
56
56
|
* @param data - Optional updated JSON data string
|
|
57
57
|
* @param context - Optional context data JSON string
|
|
58
58
|
* @param reEvaluate - If true, performs full evaluation after processing dependents
|
|
59
59
|
* @returns Array of dependent change objects as JavaScript object
|
|
60
60
|
*/
|
|
61
|
-
evaluateDependentsJS(
|
|
61
|
+
evaluateDependentsJS(changed_paths: any, data: string | null | undefined, context: string | null | undefined, re_evaluate: boolean): any;
|
|
62
62
|
/**
|
|
63
63
|
* Evaluate schema with provided data (does not return schema - use getEvaluatedSchema() for that)
|
|
64
|
-
*
|
|
64
|
+
*
|
|
65
65
|
* @param data - JSON data string
|
|
66
66
|
* @param context - Optional context data JSON string
|
|
67
67
|
* @throws Error if evaluation fails
|
|
@@ -77,7 +77,7 @@ export class JSONEvalWasm {
|
|
|
77
77
|
runLogic(logic_id: number, data?: string | null, context?: string | null): any;
|
|
78
78
|
/**
|
|
79
79
|
* Validate data and return as plain JavaScript object (Worker-safe)
|
|
80
|
-
*
|
|
80
|
+
*
|
|
81
81
|
* @param data - JSON data string
|
|
82
82
|
* @param context - Optional context data JSON string
|
|
83
83
|
* @returns Plain JavaScript object with validation result
|
|
@@ -85,7 +85,7 @@ export class JSONEvalWasm {
|
|
|
85
85
|
validateJS(data: string, context?: string | null): any;
|
|
86
86
|
/**
|
|
87
87
|
* Validate data against schema rules with optional path filtering
|
|
88
|
-
*
|
|
88
|
+
*
|
|
89
89
|
* @param data - JSON data string
|
|
90
90
|
* @param context - Optional context data JSON string
|
|
91
91
|
* @param paths - Optional array of paths to validate (null for all)
|
|
@@ -94,7 +94,7 @@ export class JSONEvalWasm {
|
|
|
94
94
|
validatePaths(data: string, context?: string | null, paths?: string[] | null): ValidationResult;
|
|
95
95
|
/**
|
|
96
96
|
* Validate with path filtering and return as plain JavaScript object (Worker-safe)
|
|
97
|
-
*
|
|
97
|
+
*
|
|
98
98
|
* @param data - JSON data string
|
|
99
99
|
* @param context - Optional context data JSON string
|
|
100
100
|
* @param paths - Optional array of paths to validate (null for all)
|
|
@@ -103,7 +103,7 @@ export class JSONEvalWasm {
|
|
|
103
103
|
validatePathsJS(data: string, context?: string | null, paths?: string[] | null): any;
|
|
104
104
|
/**
|
|
105
105
|
* Validate data against schema rules
|
|
106
|
-
*
|
|
106
|
+
*
|
|
107
107
|
* @param data - JSON data string
|
|
108
108
|
* @param context - Optional context data JSON string
|
|
109
109
|
* @returns ValidationResult
|
|
@@ -111,7 +111,7 @@ export class JSONEvalWasm {
|
|
|
111
111
|
validate(data: string, context?: string | null): ValidationResult;
|
|
112
112
|
/**
|
|
113
113
|
* Create a new JSONEval instance from a cached ParsedSchema
|
|
114
|
-
*
|
|
114
|
+
*
|
|
115
115
|
* @param cacheKey - Cache key to lookup in the global ParsedSchemaCache
|
|
116
116
|
* @param context - Optional context data JSON string
|
|
117
117
|
* @param data - Optional initial data JSON string
|
|
@@ -119,7 +119,7 @@ export class JSONEvalWasm {
|
|
|
119
119
|
static newFromCache(cache_key: string, context?: string | null, data?: string | null): JSONEvalWasm;
|
|
120
120
|
/**
|
|
121
121
|
* Create a new JSONEval instance from MessagePack-encoded schema
|
|
122
|
-
*
|
|
122
|
+
*
|
|
123
123
|
* @param schemaMsgpack - MessagePack-encoded schema bytes (Uint8Array)
|
|
124
124
|
* @param context - Optional context data JSON string
|
|
125
125
|
* @param data - Optional initial data JSON string
|
|
@@ -127,14 +127,14 @@ export class JSONEvalWasm {
|
|
|
127
127
|
static newFromMsgpack(schema_msgpack: Uint8Array, context?: string | null, data?: string | null): JSONEvalWasm;
|
|
128
128
|
/**
|
|
129
129
|
* Set timezone offset for datetime operations (TODAY, NOW)
|
|
130
|
-
*
|
|
130
|
+
*
|
|
131
131
|
* @param offsetMinutes - Timezone offset in minutes from UTC (e.g., 420 for UTC+7, -300 for UTC-5)
|
|
132
132
|
* Pass null or undefined to reset to UTC
|
|
133
133
|
*/
|
|
134
134
|
setTimezoneOffset(offset_minutes?: number | null): void;
|
|
135
135
|
/**
|
|
136
136
|
* Create a new JSONEval instance
|
|
137
|
-
*
|
|
137
|
+
*
|
|
138
138
|
* @param schema - JSON schema string
|
|
139
139
|
* @param context - Optional context data JSON string
|
|
140
140
|
* @param data - Optional initial data JSON string
|
|
@@ -142,7 +142,7 @@ export class JSONEvalWasm {
|
|
|
142
142
|
constructor(schema: string, context?: string | null, data?: string | null);
|
|
143
143
|
/**
|
|
144
144
|
* Get cache statistics
|
|
145
|
-
*
|
|
145
|
+
*
|
|
146
146
|
* @returns Cache statistics as JavaScript object with hits, misses, and entries
|
|
147
147
|
*/
|
|
148
148
|
cacheStats(): any;
|
|
@@ -163,26 +163,26 @@ export class JSONEvalWasm {
|
|
|
163
163
|
disableCache(): void;
|
|
164
164
|
/**
|
|
165
165
|
* Check if evaluation caching is enabled
|
|
166
|
-
*
|
|
166
|
+
*
|
|
167
167
|
* @returns true if caching is enabled, false otherwise
|
|
168
168
|
*/
|
|
169
169
|
isCacheEnabled(): boolean;
|
|
170
170
|
/**
|
|
171
171
|
* Get the number of cached entries
|
|
172
|
-
*
|
|
172
|
+
*
|
|
173
173
|
* @returns Number of cached entries
|
|
174
174
|
*/
|
|
175
175
|
cacheLen(): number;
|
|
176
176
|
/**
|
|
177
177
|
* Resolve layout with optional evaluation
|
|
178
|
-
*
|
|
178
|
+
*
|
|
179
179
|
* @param evaluate - If true, runs evaluation before resolving layout
|
|
180
180
|
* @throws Error if resolve fails
|
|
181
181
|
*/
|
|
182
182
|
resolveLayout(evaluate: boolean): void;
|
|
183
183
|
/**
|
|
184
184
|
* Reload schema with new data
|
|
185
|
-
*
|
|
185
|
+
*
|
|
186
186
|
* @param schema - New JSON schema string
|
|
187
187
|
* @param context - Optional context data JSON string
|
|
188
188
|
* @param data - Optional initial data JSON string
|
|
@@ -191,13 +191,13 @@ export class JSONEvalWasm {
|
|
|
191
191
|
/**
|
|
192
192
|
* Get all schema values (evaluations ending with .value)
|
|
193
193
|
* Mutates internal data by overriding with values from value evaluations
|
|
194
|
-
*
|
|
194
|
+
*
|
|
195
195
|
* @returns Modified data as JavaScript object
|
|
196
196
|
*/
|
|
197
197
|
getSchemaValue(): any;
|
|
198
198
|
/**
|
|
199
199
|
* Get a value from the schema using dotted path notation
|
|
200
|
-
*
|
|
200
|
+
*
|
|
201
201
|
* @param path - Dotted path to the value (e.g., "properties.field.value")
|
|
202
202
|
* @returns Value as JSON string or null if not found
|
|
203
203
|
*/
|
|
@@ -211,21 +211,21 @@ export class JSONEvalWasm {
|
|
|
211
211
|
getSchemaByPaths(paths_json: string, format: number): string;
|
|
212
212
|
/**
|
|
213
213
|
* Get the evaluated schema with optional layout resolution
|
|
214
|
-
*
|
|
214
|
+
*
|
|
215
215
|
* @param skipLayout - Whether to skip layout resolution
|
|
216
216
|
* @returns Evaluated schema as JSON string
|
|
217
217
|
*/
|
|
218
218
|
getEvaluatedSchema(skip_layout: boolean): string;
|
|
219
219
|
/**
|
|
220
220
|
* Get a value from the schema using dotted path notation as JavaScript object
|
|
221
|
-
*
|
|
221
|
+
*
|
|
222
222
|
* @param path - Dotted path to the value (e.g., "properties.field.value")
|
|
223
223
|
* @returns Value as JavaScript object or null if not found
|
|
224
224
|
*/
|
|
225
225
|
getSchemaByPathJS(path: string): any;
|
|
226
226
|
/**
|
|
227
227
|
* Reload schema from MessagePack-encoded bytes
|
|
228
|
-
*
|
|
228
|
+
*
|
|
229
229
|
* @param schemaMsgpack - MessagePack-encoded schema bytes (Uint8Array)
|
|
230
230
|
* @param context - Optional context data JSON string
|
|
231
231
|
* @param data - Optional initial data JSON string
|
|
@@ -240,14 +240,14 @@ export class JSONEvalWasm {
|
|
|
240
240
|
getSchemaByPathsJS(paths_json: string, format: number): any;
|
|
241
241
|
/**
|
|
242
242
|
* Get the evaluated schema as JavaScript object
|
|
243
|
-
*
|
|
243
|
+
*
|
|
244
244
|
* @param skipLayout - Whether to skip layout resolution
|
|
245
245
|
* @returns Evaluated schema as JavaScript object
|
|
246
246
|
*/
|
|
247
247
|
getEvaluatedSchemaJS(skip_layout: boolean): any;
|
|
248
248
|
/**
|
|
249
249
|
* Reload schema from ParsedSchemaCache using a cache key
|
|
250
|
-
*
|
|
250
|
+
*
|
|
251
251
|
* @param cacheKey - Cache key to lookup in the global ParsedSchemaCache
|
|
252
252
|
* @param context - Optional context data JSON string
|
|
253
253
|
* @param data - Optional initial data JSON string
|
|
@@ -255,7 +255,7 @@ export class JSONEvalWasm {
|
|
|
255
255
|
reloadSchemaFromCache(cache_key: string, context?: string | null, data?: string | null): void;
|
|
256
256
|
/**
|
|
257
257
|
* Get a value from the evaluated schema using dotted path notation
|
|
258
|
-
*
|
|
258
|
+
*
|
|
259
259
|
* @param path - Dotted path to the value (e.g., "properties.field.value")
|
|
260
260
|
* @param skipLayout - Whether to skip layout resolution
|
|
261
261
|
* @returns Value as JSON string or null if not found
|
|
@@ -263,17 +263,17 @@ export class JSONEvalWasm {
|
|
|
263
263
|
getEvaluatedSchemaByPath(path: string, skip_layout: boolean): string | undefined;
|
|
264
264
|
/**
|
|
265
265
|
* Get the evaluated schema in MessagePack format
|
|
266
|
-
*
|
|
266
|
+
*
|
|
267
267
|
* @param skipLayout - Whether to skip layout resolution
|
|
268
268
|
* @returns Evaluated schema as MessagePack bytes (Uint8Array)
|
|
269
|
-
*
|
|
269
|
+
*
|
|
270
270
|
* # Zero-Copy Optimization
|
|
271
|
-
*
|
|
271
|
+
*
|
|
272
272
|
* This method returns MessagePack binary data with minimal copying:
|
|
273
273
|
* 1. Serializes schema to Vec<u8> in Rust (unavoidable)
|
|
274
274
|
* 2. wasm-bindgen transfers Vec<u8> to JS as Uint8Array (optimized)
|
|
275
275
|
* 3. Result is a Uint8Array view (minimal overhead)
|
|
276
|
-
*
|
|
276
|
+
*
|
|
277
277
|
* MessagePack format is 20-50% smaller than JSON, ideal for web/WASM.
|
|
278
278
|
*/
|
|
279
279
|
getEvaluatedSchemaMsgpack(skip_layout: boolean): Uint8Array;
|
|
@@ -287,7 +287,7 @@ export class JSONEvalWasm {
|
|
|
287
287
|
getEvaluatedSchemaByPaths(paths_json: string, skip_layout: boolean, format: number): string;
|
|
288
288
|
/**
|
|
289
289
|
* Get a value from the evaluated schema using dotted path notation as JavaScript object
|
|
290
|
-
*
|
|
290
|
+
*
|
|
291
291
|
* @param path - Dotted path to the value (e.g., "properties.field.value")
|
|
292
292
|
* @param skipLayout - Whether to skip layout resolution
|
|
293
293
|
* @returns Value as JavaScript object or null if not found
|
|
@@ -303,28 +303,28 @@ export class JSONEvalWasm {
|
|
|
303
303
|
getEvaluatedSchemaByPathsJS(paths_json: string, skip_layout: boolean, format: number): any;
|
|
304
304
|
/**
|
|
305
305
|
* Get the evaluated schema without $params field
|
|
306
|
-
*
|
|
306
|
+
*
|
|
307
307
|
* @param skipLayout - Whether to skip layout resolution
|
|
308
308
|
* @returns Evaluated schema as JSON string
|
|
309
309
|
*/
|
|
310
310
|
getEvaluatedSchemaWithoutParams(skip_layout: boolean): string;
|
|
311
311
|
/**
|
|
312
312
|
* Get the evaluated schema without $params as JavaScript object
|
|
313
|
-
*
|
|
313
|
+
*
|
|
314
314
|
* @param skipLayout - Whether to skip layout resolution
|
|
315
315
|
* @returns Evaluated schema as JavaScript object
|
|
316
316
|
*/
|
|
317
317
|
getEvaluatedSchemaWithoutParamsJS(skip_layout: boolean): any;
|
|
318
318
|
/**
|
|
319
319
|
* Check if a subform exists at the given path
|
|
320
|
-
*
|
|
320
|
+
*
|
|
321
321
|
* @param subformPath - Path to check
|
|
322
322
|
* @returns True if subform exists, false otherwise
|
|
323
323
|
*/
|
|
324
324
|
hasSubform(subform_path: string): boolean;
|
|
325
325
|
/**
|
|
326
326
|
* Evaluate a subform with data
|
|
327
|
-
*
|
|
327
|
+
*
|
|
328
328
|
* @param subformPath - Path to the subform (e.g., "#/riders")
|
|
329
329
|
* @param data - JSON data string for the subform
|
|
330
330
|
* @param context - Optional context data JSON string
|
|
@@ -334,7 +334,7 @@ export class JSONEvalWasm {
|
|
|
334
334
|
evaluateSubform(subform_path: string, data: string, context?: string | null, paths?: string[] | null): void;
|
|
335
335
|
/**
|
|
336
336
|
* Validate subform data against its schema rules
|
|
337
|
-
*
|
|
337
|
+
*
|
|
338
338
|
* @param subformPath - Path to the subform
|
|
339
339
|
* @param data - JSON data string for the subform
|
|
340
340
|
* @param context - Optional context data JSON string
|
|
@@ -343,13 +343,13 @@ export class JSONEvalWasm {
|
|
|
343
343
|
validateSubform(subform_path: string, data: string, context?: string | null): ValidationResult;
|
|
344
344
|
/**
|
|
345
345
|
* Get list of available subform paths
|
|
346
|
-
*
|
|
346
|
+
*
|
|
347
347
|
* @returns Array of subform paths
|
|
348
348
|
*/
|
|
349
349
|
getSubformPaths(): string[];
|
|
350
350
|
/**
|
|
351
351
|
* Resolve layout for subform
|
|
352
|
-
*
|
|
352
|
+
*
|
|
353
353
|
* @param subformPath - Path to the subform
|
|
354
354
|
* @param evaluate - If true, runs evaluation before resolving layout
|
|
355
355
|
* @throws Error if resolve fails
|
|
@@ -357,7 +357,7 @@ export class JSONEvalWasm {
|
|
|
357
357
|
resolveLayoutSubform(subform_path: string, evaluate: boolean): void;
|
|
358
358
|
/**
|
|
359
359
|
* Get schema value from subform (all .value fields)
|
|
360
|
-
*
|
|
360
|
+
*
|
|
361
361
|
* @param subformPath - Path to the subform
|
|
362
362
|
* @returns Modified data as JavaScript object
|
|
363
363
|
*/
|
|
@@ -371,7 +371,7 @@ export class JSONEvalWasm {
|
|
|
371
371
|
getSchemaByPathSubform(subform_path: string, schema_path: string): string | undefined;
|
|
372
372
|
/**
|
|
373
373
|
* Evaluate dependents in subform when a field changes
|
|
374
|
-
*
|
|
374
|
+
*
|
|
375
375
|
* @param subformPath - Path to the subform
|
|
376
376
|
* @param changedPath - Path of the field that changed
|
|
377
377
|
* @param data - Optional updated JSON data string
|
|
@@ -389,7 +389,7 @@ export class JSONEvalWasm {
|
|
|
389
389
|
getSchemaByPathsSubform(subform_path: string, paths_json: string, format: number): string;
|
|
390
390
|
/**
|
|
391
391
|
* Get evaluated schema from subform
|
|
392
|
-
*
|
|
392
|
+
*
|
|
393
393
|
* @param subformPath - Path to the subform
|
|
394
394
|
* @param resolveLayout - Whether to resolve layout
|
|
395
395
|
* @returns Evaluated schema as JSON string
|
|
@@ -404,25 +404,25 @@ export class JSONEvalWasm {
|
|
|
404
404
|
getSchemaByPathSubformJS(subform_path: string, schema_path: string): any;
|
|
405
405
|
/**
|
|
406
406
|
* Evaluate dependents in subform and return as JavaScript object
|
|
407
|
-
*
|
|
407
|
+
*
|
|
408
408
|
* @param subformPath - Path to the subform
|
|
409
409
|
* @param changedPath - Path of the field that changed
|
|
410
410
|
* @param data - Optional updated JSON data string
|
|
411
411
|
* @param context - Optional context data JSON string
|
|
412
412
|
* @returns Array of dependent change objects as JavaScript object
|
|
413
413
|
*/
|
|
414
|
-
evaluateDependentsSubformJS(subform_path: string,
|
|
414
|
+
evaluateDependentsSubformJS(subform_path: string, changed_paths: any, data?: string | null, context?: string | null): any;
|
|
415
415
|
/**
|
|
416
416
|
* Get schema by multiple paths from subform (JS object)
|
|
417
417
|
* @param subformPath - Path to the subform
|
|
418
|
-
* @param
|
|
418
|
+
* @param paths - Array of dotted paths
|
|
419
419
|
* @param format - Return format (0=Nested, 1=Flat, 2=Array)
|
|
420
420
|
* @returns Data in specified format as JavaScript object
|
|
421
421
|
*/
|
|
422
|
-
getSchemaByPathsSubformJS(subform_path: string,
|
|
422
|
+
getSchemaByPathsSubformJS(subform_path: string, paths_val: any, format: number): any;
|
|
423
423
|
/**
|
|
424
424
|
* Get evaluated schema from subform as JavaScript object
|
|
425
|
-
*
|
|
425
|
+
*
|
|
426
426
|
* @param subformPath - Path to the subform
|
|
427
427
|
* @param resolveLayout - Whether to resolve layout
|
|
428
428
|
* @returns Evaluated schema as JavaScript object
|
|
@@ -430,7 +430,7 @@ export class JSONEvalWasm {
|
|
|
430
430
|
getEvaluatedSchemaSubformJS(subform_path: string, resolve_layout: boolean): any;
|
|
431
431
|
/**
|
|
432
432
|
* Get evaluated schema by specific path from subform
|
|
433
|
-
*
|
|
433
|
+
*
|
|
434
434
|
* @param subformPath - Path to the subform
|
|
435
435
|
* @param schemaPath - Dotted path to the value within the subform
|
|
436
436
|
* @param skipLayout - Whether to skip layout resolution
|
|
@@ -448,7 +448,7 @@ export class JSONEvalWasm {
|
|
|
448
448
|
getEvaluatedSchemaByPathsSubform(subform_path: string, paths_json: string, skip_layout: boolean, format: number): string;
|
|
449
449
|
/**
|
|
450
450
|
* Get evaluated schema by specific path from subform as JavaScript object
|
|
451
|
-
*
|
|
451
|
+
*
|
|
452
452
|
* @param subformPath - Path to the subform
|
|
453
453
|
* @param schemaPath - Dotted path to the value within the subform
|
|
454
454
|
* @param skipLayout - Whether to skip layout resolution
|
|
@@ -458,15 +458,15 @@ export class JSONEvalWasm {
|
|
|
458
458
|
/**
|
|
459
459
|
* Get values from the evaluated schema of a subform using multiple dotted path notations (returns JS object)
|
|
460
460
|
* @param subformPath - Path to the subform
|
|
461
|
-
* @param
|
|
461
|
+
* @param paths - Array of dotted paths
|
|
462
462
|
* @param skipLayout - Whether to skip layout resolution
|
|
463
463
|
* @param format - Return format (0=Nested, 1=Flat, 2=Array)
|
|
464
464
|
* @returns Data in specified format as JavaScript object
|
|
465
465
|
*/
|
|
466
|
-
getEvaluatedSchemaByPathsSubformJS(subform_path: string,
|
|
466
|
+
getEvaluatedSchemaByPathsSubformJS(subform_path: string, paths_val: any, skip_layout: boolean, format: number): any;
|
|
467
467
|
/**
|
|
468
468
|
* Get evaluated schema without $params from subform
|
|
469
|
-
*
|
|
469
|
+
*
|
|
470
470
|
* @param subformPath - Path to the subform
|
|
471
471
|
* @param resolveLayout - Whether to resolve layout
|
|
472
472
|
* @returns Evaluated schema as JSON string
|
|
@@ -474,7 +474,7 @@ export class JSONEvalWasm {
|
|
|
474
474
|
getEvaluatedSchemaWithoutParamsSubform(subform_path: string, resolve_layout: boolean): string;
|
|
475
475
|
/**
|
|
476
476
|
* Get evaluated schema without $params from subform as JavaScript object
|
|
477
|
-
*
|
|
477
|
+
*
|
|
478
478
|
* @param subformPath - Path to the subform
|
|
479
479
|
* @param resolveLayout - Whether to resolve layout
|
|
480
480
|
* @returns Evaluated schema as JavaScript object
|
package/pkg/json_eval_rs.js
CHANGED
|
@@ -104,19 +104,19 @@ function getDataViewMemory0() {
|
|
|
104
104
|
return cachedDataViewMemory0;
|
|
105
105
|
}
|
|
106
106
|
|
|
107
|
-
function getArrayU8FromWasm0(ptr, len) {
|
|
108
|
-
ptr = ptr >>> 0;
|
|
109
|
-
return getUint8ArrayMemory0().subarray(ptr / 1, ptr / 1 + len);
|
|
110
|
-
}
|
|
111
|
-
|
|
112
107
|
function handleError(f, args) {
|
|
113
108
|
try {
|
|
114
109
|
return f.apply(this, args);
|
|
115
110
|
} catch (e) {
|
|
116
|
-
wasm.
|
|
111
|
+
wasm.__wbindgen_export_2(addHeapObject(e));
|
|
117
112
|
}
|
|
118
113
|
}
|
|
119
114
|
|
|
115
|
+
function getArrayU8FromWasm0(ptr, len) {
|
|
116
|
+
ptr = ptr >>> 0;
|
|
117
|
+
return getUint8ArrayMemory0().subarray(ptr / 1, ptr / 1 + len);
|
|
118
|
+
}
|
|
119
|
+
|
|
120
120
|
function dropObject(idx) {
|
|
121
121
|
if (idx < 132) return;
|
|
122
122
|
heap[idx] = heap_next;
|
|
@@ -129,6 +129,10 @@ function takeObject(idx) {
|
|
|
129
129
|
return ret;
|
|
130
130
|
}
|
|
131
131
|
|
|
132
|
+
function isLikeNone(x) {
|
|
133
|
+
return x === undefined || x === null;
|
|
134
|
+
}
|
|
135
|
+
|
|
132
136
|
function debugString(val) {
|
|
133
137
|
// primitive types
|
|
134
138
|
const type = typeof val;
|
|
@@ -194,10 +198,6 @@ function debugString(val) {
|
|
|
194
198
|
return className;
|
|
195
199
|
}
|
|
196
200
|
|
|
197
|
-
function isLikeNone(x) {
|
|
198
|
-
return x === undefined || x === null;
|
|
199
|
-
}
|
|
200
|
-
|
|
201
201
|
function passArrayJsValueToWasm0(array, malloc) {
|
|
202
202
|
const ptr = malloc(array.length * 4, 4) >>> 0;
|
|
203
203
|
const mem = getDataViewMemory0();
|
|
@@ -207,6 +207,13 @@ function passArrayJsValueToWasm0(array, malloc) {
|
|
|
207
207
|
WASM_VECTOR_LEN = array.length;
|
|
208
208
|
return ptr;
|
|
209
209
|
}
|
|
210
|
+
/**
|
|
211
|
+
* Initialize the library (sets up panic hook)
|
|
212
|
+
*/
|
|
213
|
+
exports.init = function() {
|
|
214
|
+
wasm.init();
|
|
215
|
+
};
|
|
216
|
+
|
|
210
217
|
/**
|
|
211
218
|
* Get library version (alias)
|
|
212
219
|
* @returns {string}
|
|
@@ -224,17 +231,10 @@ exports.version = function() {
|
|
|
224
231
|
return getStringFromWasm0(r0, r1);
|
|
225
232
|
} finally {
|
|
226
233
|
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
227
|
-
wasm.
|
|
234
|
+
wasm.__wbindgen_export_3(deferred1_0, deferred1_1, 1);
|
|
228
235
|
}
|
|
229
236
|
};
|
|
230
237
|
|
|
231
|
-
/**
|
|
232
|
-
* Initialize the library (sets up panic hook)
|
|
233
|
-
*/
|
|
234
|
-
exports.init = function() {
|
|
235
|
-
wasm.init();
|
|
236
|
-
};
|
|
237
|
-
|
|
238
238
|
/**
|
|
239
239
|
* Get the library version
|
|
240
240
|
* @returns {string}
|
|
@@ -252,7 +252,7 @@ exports.getVersion = function() {
|
|
|
252
252
|
return getStringFromWasm0(r0, r1);
|
|
253
253
|
} finally {
|
|
254
254
|
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
255
|
-
wasm.
|
|
255
|
+
wasm.__wbindgen_export_3(deferred1_0, deferred1_1, 1);
|
|
256
256
|
}
|
|
257
257
|
};
|
|
258
258
|
|
|
@@ -395,7 +395,7 @@ class JSONEvalWasm {
|
|
|
395
395
|
return getStringFromWasm0(ptr4, len4);
|
|
396
396
|
} finally {
|
|
397
397
|
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
398
|
-
wasm.
|
|
398
|
+
wasm.__wbindgen_export_3(deferred5_0, deferred5_1, 1);
|
|
399
399
|
}
|
|
400
400
|
}
|
|
401
401
|
/**
|
|
@@ -438,22 +438,20 @@ class JSONEvalWasm {
|
|
|
438
438
|
* @param context - Optional context data JSON string
|
|
439
439
|
* @param reEvaluate - If true, performs full evaluation after processing dependents
|
|
440
440
|
* @returns Array of dependent change objects as JavaScript object
|
|
441
|
-
* @param {
|
|
441
|
+
* @param {any} changed_paths
|
|
442
442
|
* @param {string | null | undefined} data
|
|
443
443
|
* @param {string | null | undefined} context
|
|
444
444
|
* @param {boolean} re_evaluate
|
|
445
445
|
* @returns {any}
|
|
446
446
|
*/
|
|
447
|
-
evaluateDependentsJS(
|
|
447
|
+
evaluateDependentsJS(changed_paths, data, context, re_evaluate) {
|
|
448
448
|
try {
|
|
449
449
|
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
var ptr1 = isLikeNone(
|
|
450
|
+
var ptr0 = isLikeNone(data) ? 0 : passStringToWasm0(data, wasm.__wbindgen_export_0, wasm.__wbindgen_export_1);
|
|
451
|
+
var len0 = WASM_VECTOR_LEN;
|
|
452
|
+
var ptr1 = isLikeNone(context) ? 0 : passStringToWasm0(context, wasm.__wbindgen_export_0, wasm.__wbindgen_export_1);
|
|
453
453
|
var len1 = WASM_VECTOR_LEN;
|
|
454
|
-
|
|
455
|
-
var len2 = WASM_VECTOR_LEN;
|
|
456
|
-
wasm.jsonevalwasm_evaluateDependentsJS(retptr, this.__wbg_ptr, ptr0, len0, ptr1, len1, ptr2, len2, re_evaluate);
|
|
454
|
+
wasm.jsonevalwasm_evaluateDependentsJS(retptr, this.__wbg_ptr, addHeapObject(changed_paths), ptr0, len0, ptr1, len1, re_evaluate);
|
|
457
455
|
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
458
456
|
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
459
457
|
var r2 = getDataViewMemory0().getInt32(retptr + 4 * 2, true);
|
|
@@ -907,7 +905,7 @@ class JSONEvalWasm {
|
|
|
907
905
|
let v2;
|
|
908
906
|
if (r0 !== 0) {
|
|
909
907
|
v2 = getStringFromWasm0(r0, r1).slice();
|
|
910
|
-
wasm.
|
|
908
|
+
wasm.__wbindgen_export_3(r0, r1 * 1, 1);
|
|
911
909
|
}
|
|
912
910
|
return v2;
|
|
913
911
|
} finally {
|
|
@@ -946,7 +944,7 @@ class JSONEvalWasm {
|
|
|
946
944
|
return getStringFromWasm0(ptr2, len2);
|
|
947
945
|
} finally {
|
|
948
946
|
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
949
|
-
wasm.
|
|
947
|
+
wasm.__wbindgen_export_3(deferred3_0, deferred3_1, 1);
|
|
950
948
|
}
|
|
951
949
|
}
|
|
952
950
|
/**
|
|
@@ -970,7 +968,7 @@ class JSONEvalWasm {
|
|
|
970
968
|
return getStringFromWasm0(r0, r1);
|
|
971
969
|
} finally {
|
|
972
970
|
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
973
|
-
wasm.
|
|
971
|
+
wasm.__wbindgen_export_3(deferred1_0, deferred1_1, 1);
|
|
974
972
|
}
|
|
975
973
|
}
|
|
976
974
|
/**
|
|
@@ -1126,7 +1124,7 @@ class JSONEvalWasm {
|
|
|
1126
1124
|
let v2;
|
|
1127
1125
|
if (r0 !== 0) {
|
|
1128
1126
|
v2 = getStringFromWasm0(r0, r1).slice();
|
|
1129
|
-
wasm.
|
|
1127
|
+
wasm.__wbindgen_export_3(r0, r1 * 1, 1);
|
|
1130
1128
|
}
|
|
1131
1129
|
return v2;
|
|
1132
1130
|
} finally {
|
|
@@ -1162,7 +1160,7 @@ class JSONEvalWasm {
|
|
|
1162
1160
|
throw takeObject(r2);
|
|
1163
1161
|
}
|
|
1164
1162
|
var v1 = getArrayU8FromWasm0(r0, r1).slice();
|
|
1165
|
-
wasm.
|
|
1163
|
+
wasm.__wbindgen_export_3(r0, r1 * 1, 1);
|
|
1166
1164
|
return v1;
|
|
1167
1165
|
} finally {
|
|
1168
1166
|
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
@@ -1202,7 +1200,7 @@ class JSONEvalWasm {
|
|
|
1202
1200
|
return getStringFromWasm0(ptr2, len2);
|
|
1203
1201
|
} finally {
|
|
1204
1202
|
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
1205
|
-
wasm.
|
|
1203
|
+
wasm.__wbindgen_export_3(deferred3_0, deferred3_1, 1);
|
|
1206
1204
|
}
|
|
1207
1205
|
}
|
|
1208
1206
|
/**
|
|
@@ -1281,7 +1279,7 @@ class JSONEvalWasm {
|
|
|
1281
1279
|
return getStringFromWasm0(r0, r1);
|
|
1282
1280
|
} finally {
|
|
1283
1281
|
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
1284
|
-
wasm.
|
|
1282
|
+
wasm.__wbindgen_export_3(deferred1_0, deferred1_1, 1);
|
|
1285
1283
|
}
|
|
1286
1284
|
}
|
|
1287
1285
|
/**
|
|
@@ -1401,7 +1399,7 @@ class JSONEvalWasm {
|
|
|
1401
1399
|
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
1402
1400
|
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
1403
1401
|
var v1 = getArrayJsValueFromWasm0(r0, r1).slice();
|
|
1404
|
-
wasm.
|
|
1402
|
+
wasm.__wbindgen_export_3(r0, r1 * 4, 4);
|
|
1405
1403
|
return v1;
|
|
1406
1404
|
} finally {
|
|
1407
1405
|
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
@@ -1478,7 +1476,7 @@ class JSONEvalWasm {
|
|
|
1478
1476
|
let v3;
|
|
1479
1477
|
if (r0 !== 0) {
|
|
1480
1478
|
v3 = getStringFromWasm0(r0, r1).slice();
|
|
1481
|
-
wasm.
|
|
1479
|
+
wasm.__wbindgen_export_3(r0, r1 * 1, 1);
|
|
1482
1480
|
}
|
|
1483
1481
|
return v3;
|
|
1484
1482
|
} finally {
|
|
@@ -1528,7 +1526,7 @@ class JSONEvalWasm {
|
|
|
1528
1526
|
return getStringFromWasm0(ptr5, len5);
|
|
1529
1527
|
} finally {
|
|
1530
1528
|
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
1531
|
-
wasm.
|
|
1529
|
+
wasm.__wbindgen_export_3(deferred6_0, deferred6_1, 1);
|
|
1532
1530
|
}
|
|
1533
1531
|
}
|
|
1534
1532
|
/**
|
|
@@ -1567,7 +1565,7 @@ class JSONEvalWasm {
|
|
|
1567
1565
|
return getStringFromWasm0(ptr3, len3);
|
|
1568
1566
|
} finally {
|
|
1569
1567
|
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
1570
|
-
wasm.
|
|
1568
|
+
wasm.__wbindgen_export_3(deferred4_0, deferred4_1, 1);
|
|
1571
1569
|
}
|
|
1572
1570
|
}
|
|
1573
1571
|
/**
|
|
@@ -1595,7 +1593,7 @@ class JSONEvalWasm {
|
|
|
1595
1593
|
return getStringFromWasm0(r0, r1);
|
|
1596
1594
|
} finally {
|
|
1597
1595
|
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
1598
|
-
wasm.
|
|
1596
|
+
wasm.__wbindgen_export_3(deferred2_0, deferred2_1, 1);
|
|
1599
1597
|
}
|
|
1600
1598
|
}
|
|
1601
1599
|
/**
|
|
@@ -1635,23 +1633,21 @@ class JSONEvalWasm {
|
|
|
1635
1633
|
* @param context - Optional context data JSON string
|
|
1636
1634
|
* @returns Array of dependent change objects as JavaScript object
|
|
1637
1635
|
* @param {string} subform_path
|
|
1638
|
-
* @param {
|
|
1636
|
+
* @param {any} changed_paths
|
|
1639
1637
|
* @param {string | null} [data]
|
|
1640
1638
|
* @param {string | null} [context]
|
|
1641
1639
|
* @returns {any}
|
|
1642
1640
|
*/
|
|
1643
|
-
evaluateDependentsSubformJS(subform_path,
|
|
1641
|
+
evaluateDependentsSubformJS(subform_path, changed_paths, data, context) {
|
|
1644
1642
|
try {
|
|
1645
1643
|
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
1646
1644
|
const ptr0 = passStringToWasm0(subform_path, wasm.__wbindgen_export_0, wasm.__wbindgen_export_1);
|
|
1647
1645
|
const len0 = WASM_VECTOR_LEN;
|
|
1648
|
-
|
|
1649
|
-
|
|
1650
|
-
var ptr2 = isLikeNone(
|
|
1646
|
+
var ptr1 = isLikeNone(data) ? 0 : passStringToWasm0(data, wasm.__wbindgen_export_0, wasm.__wbindgen_export_1);
|
|
1647
|
+
var len1 = WASM_VECTOR_LEN;
|
|
1648
|
+
var ptr2 = isLikeNone(context) ? 0 : passStringToWasm0(context, wasm.__wbindgen_export_0, wasm.__wbindgen_export_1);
|
|
1651
1649
|
var len2 = WASM_VECTOR_LEN;
|
|
1652
|
-
|
|
1653
|
-
var len3 = WASM_VECTOR_LEN;
|
|
1654
|
-
wasm.jsonevalwasm_evaluateDependentsSubformJS(retptr, this.__wbg_ptr, ptr0, len0, ptr1, len1, ptr2, len2, ptr3, len3);
|
|
1650
|
+
wasm.jsonevalwasm_evaluateDependentsSubformJS(retptr, this.__wbg_ptr, ptr0, len0, addHeapObject(changed_paths), ptr1, len1, ptr2, len2);
|
|
1655
1651
|
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
1656
1652
|
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
1657
1653
|
var r2 = getDataViewMemory0().getInt32(retptr + 4 * 2, true);
|
|
@@ -1666,22 +1662,20 @@ class JSONEvalWasm {
|
|
|
1666
1662
|
/**
|
|
1667
1663
|
* Get schema by multiple paths from subform (JS object)
|
|
1668
1664
|
* @param subformPath - Path to the subform
|
|
1669
|
-
* @param
|
|
1665
|
+
* @param paths - Array of dotted paths
|
|
1670
1666
|
* @param format - Return format (0=Nested, 1=Flat, 2=Array)
|
|
1671
1667
|
* @returns Data in specified format as JavaScript object
|
|
1672
1668
|
* @param {string} subform_path
|
|
1673
|
-
* @param {
|
|
1669
|
+
* @param {any} paths_val
|
|
1674
1670
|
* @param {number} format
|
|
1675
1671
|
* @returns {any}
|
|
1676
1672
|
*/
|
|
1677
|
-
getSchemaByPathsSubformJS(subform_path,
|
|
1673
|
+
getSchemaByPathsSubformJS(subform_path, paths_val, format) {
|
|
1678
1674
|
try {
|
|
1679
1675
|
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
1680
1676
|
const ptr0 = passStringToWasm0(subform_path, wasm.__wbindgen_export_0, wasm.__wbindgen_export_1);
|
|
1681
1677
|
const len0 = WASM_VECTOR_LEN;
|
|
1682
|
-
|
|
1683
|
-
const len1 = WASM_VECTOR_LEN;
|
|
1684
|
-
wasm.jsonevalwasm_getSchemaByPathsSubformJS(retptr, this.__wbg_ptr, ptr0, len0, ptr1, len1, format);
|
|
1678
|
+
wasm.jsonevalwasm_getSchemaByPathsSubformJS(retptr, this.__wbg_ptr, ptr0, len0, addHeapObject(paths_val), format);
|
|
1685
1679
|
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
1686
1680
|
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
1687
1681
|
var r2 = getDataViewMemory0().getInt32(retptr + 4 * 2, true);
|
|
@@ -1745,7 +1739,7 @@ class JSONEvalWasm {
|
|
|
1745
1739
|
let v3;
|
|
1746
1740
|
if (r0 !== 0) {
|
|
1747
1741
|
v3 = getStringFromWasm0(r0, r1).slice();
|
|
1748
|
-
wasm.
|
|
1742
|
+
wasm.__wbindgen_export_3(r0, r1 * 1, 1);
|
|
1749
1743
|
}
|
|
1750
1744
|
return v3;
|
|
1751
1745
|
} finally {
|
|
@@ -1790,7 +1784,7 @@ class JSONEvalWasm {
|
|
|
1790
1784
|
return getStringFromWasm0(ptr3, len3);
|
|
1791
1785
|
} finally {
|
|
1792
1786
|
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
1793
|
-
wasm.
|
|
1787
|
+
wasm.__wbindgen_export_3(deferred4_0, deferred4_1, 1);
|
|
1794
1788
|
}
|
|
1795
1789
|
}
|
|
1796
1790
|
/**
|
|
@@ -1827,24 +1821,22 @@ class JSONEvalWasm {
|
|
|
1827
1821
|
/**
|
|
1828
1822
|
* Get values from the evaluated schema of a subform using multiple dotted path notations (returns JS object)
|
|
1829
1823
|
* @param subformPath - Path to the subform
|
|
1830
|
-
* @param
|
|
1824
|
+
* @param paths - Array of dotted paths
|
|
1831
1825
|
* @param skipLayout - Whether to skip layout resolution
|
|
1832
1826
|
* @param format - Return format (0=Nested, 1=Flat, 2=Array)
|
|
1833
1827
|
* @returns Data in specified format as JavaScript object
|
|
1834
1828
|
* @param {string} subform_path
|
|
1835
|
-
* @param {
|
|
1829
|
+
* @param {any} paths_val
|
|
1836
1830
|
* @param {boolean} skip_layout
|
|
1837
1831
|
* @param {number} format
|
|
1838
1832
|
* @returns {any}
|
|
1839
1833
|
*/
|
|
1840
|
-
getEvaluatedSchemaByPathsSubformJS(subform_path,
|
|
1834
|
+
getEvaluatedSchemaByPathsSubformJS(subform_path, paths_val, skip_layout, format) {
|
|
1841
1835
|
try {
|
|
1842
1836
|
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
1843
1837
|
const ptr0 = passStringToWasm0(subform_path, wasm.__wbindgen_export_0, wasm.__wbindgen_export_1);
|
|
1844
1838
|
const len0 = WASM_VECTOR_LEN;
|
|
1845
|
-
|
|
1846
|
-
const len1 = WASM_VECTOR_LEN;
|
|
1847
|
-
wasm.jsonevalwasm_getEvaluatedSchemaByPathsSubformJS(retptr, this.__wbg_ptr, ptr0, len0, ptr1, len1, skip_layout, format);
|
|
1839
|
+
wasm.jsonevalwasm_getEvaluatedSchemaByPathsSubformJS(retptr, this.__wbg_ptr, ptr0, len0, addHeapObject(paths_val), skip_layout, format);
|
|
1848
1840
|
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
1849
1841
|
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
1850
1842
|
var r2 = getDataViewMemory0().getInt32(retptr + 4 * 2, true);
|
|
@@ -1881,7 +1873,7 @@ class JSONEvalWasm {
|
|
|
1881
1873
|
return getStringFromWasm0(r0, r1);
|
|
1882
1874
|
} finally {
|
|
1883
1875
|
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
1884
|
-
wasm.
|
|
1876
|
+
wasm.__wbindgen_export_3(deferred2_0, deferred2_1, 1);
|
|
1885
1877
|
}
|
|
1886
1878
|
}
|
|
1887
1879
|
/**
|
|
@@ -1955,7 +1947,7 @@ class ValidationError {
|
|
|
1955
1947
|
let v1;
|
|
1956
1948
|
if (r0 !== 0) {
|
|
1957
1949
|
v1 = getStringFromWasm0(r0, r1).slice();
|
|
1958
|
-
wasm.
|
|
1950
|
+
wasm.__wbindgen_export_3(r0, r1 * 1, 1);
|
|
1959
1951
|
}
|
|
1960
1952
|
return v1;
|
|
1961
1953
|
} finally {
|
|
@@ -1974,7 +1966,7 @@ class ValidationError {
|
|
|
1974
1966
|
let v1;
|
|
1975
1967
|
if (r0 !== 0) {
|
|
1976
1968
|
v1 = getStringFromWasm0(r0, r1).slice();
|
|
1977
|
-
wasm.
|
|
1969
|
+
wasm.__wbindgen_export_3(r0, r1 * 1, 1);
|
|
1978
1970
|
}
|
|
1979
1971
|
return v1;
|
|
1980
1972
|
} finally {
|
|
@@ -2004,7 +1996,7 @@ class ValidationError {
|
|
|
2004
1996
|
return getStringFromWasm0(r0, r1);
|
|
2005
1997
|
} finally {
|
|
2006
1998
|
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
2007
|
-
wasm.
|
|
1999
|
+
wasm.__wbindgen_export_3(deferred1_0, deferred1_1, 1);
|
|
2008
2000
|
}
|
|
2009
2001
|
}
|
|
2010
2002
|
/**
|
|
@@ -2023,7 +2015,7 @@ class ValidationError {
|
|
|
2023
2015
|
return getStringFromWasm0(r0, r1);
|
|
2024
2016
|
} finally {
|
|
2025
2017
|
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
2026
|
-
wasm.
|
|
2018
|
+
wasm.__wbindgen_export_3(deferred1_0, deferred1_1, 1);
|
|
2027
2019
|
}
|
|
2028
2020
|
}
|
|
2029
2021
|
/**
|
|
@@ -2038,7 +2030,7 @@ class ValidationError {
|
|
|
2038
2030
|
let v1;
|
|
2039
2031
|
if (r0 !== 0) {
|
|
2040
2032
|
v1 = getStringFromWasm0(r0, r1).slice();
|
|
2041
|
-
wasm.
|
|
2033
|
+
wasm.__wbindgen_export_3(r0, r1 * 1, 1);
|
|
2042
2034
|
}
|
|
2043
2035
|
return v1;
|
|
2044
2036
|
} finally {
|
|
@@ -2061,7 +2053,7 @@ class ValidationError {
|
|
|
2061
2053
|
return getStringFromWasm0(r0, r1);
|
|
2062
2054
|
} finally {
|
|
2063
2055
|
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
2064
|
-
wasm.
|
|
2056
|
+
wasm.__wbindgen_export_3(deferred1_0, deferred1_1, 1);
|
|
2065
2057
|
}
|
|
2066
2058
|
}
|
|
2067
2059
|
}
|
|
@@ -2106,7 +2098,7 @@ class ValidationResult {
|
|
|
2106
2098
|
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
2107
2099
|
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
2108
2100
|
var v1 = getArrayJsValueFromWasm0(r0, r1).slice();
|
|
2109
|
-
wasm.
|
|
2101
|
+
wasm.__wbindgen_export_3(r0, r1 * 4, 4);
|
|
2110
2102
|
return v1;
|
|
2111
2103
|
} finally {
|
|
2112
2104
|
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
@@ -2155,6 +2147,16 @@ exports.__wbg_String_8f0eb39a4a4c2f66 = function(arg0, arg1) {
|
|
|
2155
2147
|
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
2156
2148
|
};
|
|
2157
2149
|
|
|
2150
|
+
exports.__wbg_call_13410aac570ffff7 = function() { return handleError(function (arg0, arg1) {
|
|
2151
|
+
const ret = getObject(arg0).call(getObject(arg1));
|
|
2152
|
+
return addHeapObject(ret);
|
|
2153
|
+
}, arguments) };
|
|
2154
|
+
|
|
2155
|
+
exports.__wbg_done_75ed0ee6dd243d9d = function(arg0) {
|
|
2156
|
+
const ret = getObject(arg0).done;
|
|
2157
|
+
return ret;
|
|
2158
|
+
};
|
|
2159
|
+
|
|
2158
2160
|
exports.__wbg_error_7534b8e9a36f1ab4 = function(arg0, arg1) {
|
|
2159
2161
|
let deferred0_0;
|
|
2160
2162
|
let deferred0_1;
|
|
@@ -2163,7 +2165,7 @@ exports.__wbg_error_7534b8e9a36f1ab4 = function(arg0, arg1) {
|
|
|
2163
2165
|
deferred0_1 = arg1;
|
|
2164
2166
|
console.error(getStringFromWasm0(arg0, arg1));
|
|
2165
2167
|
} finally {
|
|
2166
|
-
wasm.
|
|
2168
|
+
wasm.__wbindgen_export_3(deferred0_0, deferred0_1, 1);
|
|
2167
2169
|
}
|
|
2168
2170
|
};
|
|
2169
2171
|
|
|
@@ -2176,7 +2178,59 @@ exports.__wbg_getTime_6bb3f64e0f18f817 = function(arg0) {
|
|
|
2176
2178
|
return ret;
|
|
2177
2179
|
};
|
|
2178
2180
|
|
|
2179
|
-
exports.
|
|
2181
|
+
exports.__wbg_get_0da715ceaecea5c8 = function(arg0, arg1) {
|
|
2182
|
+
const ret = getObject(arg0)[arg1 >>> 0];
|
|
2183
|
+
return addHeapObject(ret);
|
|
2184
|
+
};
|
|
2185
|
+
|
|
2186
|
+
exports.__wbg_get_458e874b43b18b25 = function() { return handleError(function (arg0, arg1) {
|
|
2187
|
+
const ret = Reflect.get(getObject(arg0), getObject(arg1));
|
|
2188
|
+
return addHeapObject(ret);
|
|
2189
|
+
}, arguments) };
|
|
2190
|
+
|
|
2191
|
+
exports.__wbg_instanceof_ArrayBuffer_67f3012529f6a2dd = function(arg0) {
|
|
2192
|
+
let result;
|
|
2193
|
+
try {
|
|
2194
|
+
result = getObject(arg0) instanceof ArrayBuffer;
|
|
2195
|
+
} catch (_) {
|
|
2196
|
+
result = false;
|
|
2197
|
+
}
|
|
2198
|
+
const ret = result;
|
|
2199
|
+
return ret;
|
|
2200
|
+
};
|
|
2201
|
+
|
|
2202
|
+
exports.__wbg_instanceof_Uint8Array_9a8378d955933db7 = function(arg0) {
|
|
2203
|
+
let result;
|
|
2204
|
+
try {
|
|
2205
|
+
result = getObject(arg0) instanceof Uint8Array;
|
|
2206
|
+
} catch (_) {
|
|
2207
|
+
result = false;
|
|
2208
|
+
}
|
|
2209
|
+
const ret = result;
|
|
2210
|
+
return ret;
|
|
2211
|
+
};
|
|
2212
|
+
|
|
2213
|
+
exports.__wbg_isArray_030cce220591fb41 = function(arg0) {
|
|
2214
|
+
const ret = Array.isArray(getObject(arg0));
|
|
2215
|
+
return ret;
|
|
2216
|
+
};
|
|
2217
|
+
|
|
2218
|
+
exports.__wbg_iterator_f370b34483c71a1c = function() {
|
|
2219
|
+
const ret = Symbol.iterator;
|
|
2220
|
+
return addHeapObject(ret);
|
|
2221
|
+
};
|
|
2222
|
+
|
|
2223
|
+
exports.__wbg_length_186546c51cd61acd = function(arg0) {
|
|
2224
|
+
const ret = getObject(arg0).length;
|
|
2225
|
+
return ret;
|
|
2226
|
+
};
|
|
2227
|
+
|
|
2228
|
+
exports.__wbg_length_6bb7e81f9d7713e4 = function(arg0) {
|
|
2229
|
+
const ret = getObject(arg0).length;
|
|
2230
|
+
return ret;
|
|
2231
|
+
};
|
|
2232
|
+
|
|
2233
|
+
exports.__wbg_log_4b6ed0b139485439 = function(arg0, arg1) {
|
|
2180
2234
|
console.log(getStringFromWasm0(arg0, arg1));
|
|
2181
2235
|
};
|
|
2182
2236
|
|
|
@@ -2200,16 +2254,35 @@ exports.__wbg_new_2ff1f68f3676ea53 = function() {
|
|
|
2200
2254
|
return addHeapObject(ret);
|
|
2201
2255
|
};
|
|
2202
2256
|
|
|
2257
|
+
exports.__wbg_new_638ebfaedbf32a5e = function(arg0) {
|
|
2258
|
+
const ret = new Uint8Array(getObject(arg0));
|
|
2259
|
+
return addHeapObject(ret);
|
|
2260
|
+
};
|
|
2261
|
+
|
|
2203
2262
|
exports.__wbg_new_8a6f238a6ece86ea = function() {
|
|
2204
2263
|
const ret = new Error();
|
|
2205
2264
|
return addHeapObject(ret);
|
|
2206
2265
|
};
|
|
2207
2266
|
|
|
2267
|
+
exports.__wbg_next_5b3530e612fde77d = function(arg0) {
|
|
2268
|
+
const ret = getObject(arg0).next;
|
|
2269
|
+
return addHeapObject(ret);
|
|
2270
|
+
};
|
|
2271
|
+
|
|
2272
|
+
exports.__wbg_next_692e82279131b03c = function() { return handleError(function (arg0) {
|
|
2273
|
+
const ret = getObject(arg0).next();
|
|
2274
|
+
return addHeapObject(ret);
|
|
2275
|
+
}, arguments) };
|
|
2276
|
+
|
|
2208
2277
|
exports.__wbg_parse_442f5ba02e5eaf8b = function() { return handleError(function (arg0, arg1) {
|
|
2209
2278
|
const ret = JSON.parse(getStringFromWasm0(arg0, arg1));
|
|
2210
2279
|
return addHeapObject(ret);
|
|
2211
2280
|
}, arguments) };
|
|
2212
2281
|
|
|
2282
|
+
exports.__wbg_prototypesetcall_3d4a26c1ed734349 = function(arg0, arg1, arg2) {
|
|
2283
|
+
Uint8Array.prototype.set.call(getArrayU8FromWasm0(arg0, arg1), getObject(arg2));
|
|
2284
|
+
};
|
|
2285
|
+
|
|
2213
2286
|
exports.__wbg_set_3f1d0b984ed272ed = function(arg0, arg1, arg2) {
|
|
2214
2287
|
getObject(arg0)[takeObject(arg1)] = takeObject(arg2);
|
|
2215
2288
|
};
|
|
@@ -2236,6 +2309,17 @@ exports.__wbg_validationerror_new = function(arg0) {
|
|
|
2236
2309
|
return addHeapObject(ret);
|
|
2237
2310
|
};
|
|
2238
2311
|
|
|
2312
|
+
exports.__wbg_value_dd9372230531eade = function(arg0) {
|
|
2313
|
+
const ret = getObject(arg0).value;
|
|
2314
|
+
return addHeapObject(ret);
|
|
2315
|
+
};
|
|
2316
|
+
|
|
2317
|
+
exports.__wbg_wbindgenbooleanget_3fe6f642c7d97746 = function(arg0) {
|
|
2318
|
+
const v = getObject(arg0);
|
|
2319
|
+
const ret = typeof(v) === 'boolean' ? v : undefined;
|
|
2320
|
+
return isLikeNone(ret) ? 0xFFFFFF : ret ? 1 : 0;
|
|
2321
|
+
};
|
|
2322
|
+
|
|
2239
2323
|
exports.__wbg_wbindgendebugstring_99ef257a3ddda34d = function(arg0, arg1) {
|
|
2240
2324
|
const ret = debugString(getObject(arg1));
|
|
2241
2325
|
const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_export_0, wasm.__wbindgen_export_1);
|
|
@@ -2244,11 +2328,34 @@ exports.__wbg_wbindgendebugstring_99ef257a3ddda34d = function(arg0, arg1) {
|
|
|
2244
2328
|
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
2245
2329
|
};
|
|
2246
2330
|
|
|
2331
|
+
exports.__wbg_wbindgenisfunction_8cee7dce3725ae74 = function(arg0) {
|
|
2332
|
+
const ret = typeof(getObject(arg0)) === 'function';
|
|
2333
|
+
return ret;
|
|
2334
|
+
};
|
|
2335
|
+
|
|
2336
|
+
exports.__wbg_wbindgenisobject_307a53c6bd97fbf8 = function(arg0) {
|
|
2337
|
+
const val = getObject(arg0);
|
|
2338
|
+
const ret = typeof(val) === 'object' && val !== null;
|
|
2339
|
+
return ret;
|
|
2340
|
+
};
|
|
2341
|
+
|
|
2247
2342
|
exports.__wbg_wbindgenisstring_d4fa939789f003b0 = function(arg0) {
|
|
2248
2343
|
const ret = typeof(getObject(arg0)) === 'string';
|
|
2249
2344
|
return ret;
|
|
2250
2345
|
};
|
|
2251
2346
|
|
|
2347
|
+
exports.__wbg_wbindgenjsvallooseeq_9bec8c9be826bed1 = function(arg0, arg1) {
|
|
2348
|
+
const ret = getObject(arg0) == getObject(arg1);
|
|
2349
|
+
return ret;
|
|
2350
|
+
};
|
|
2351
|
+
|
|
2352
|
+
exports.__wbg_wbindgennumberget_f74b4c7525ac05cb = function(arg0, arg1) {
|
|
2353
|
+
const obj = getObject(arg1);
|
|
2354
|
+
const ret = typeof(obj) === 'number' ? obj : undefined;
|
|
2355
|
+
getDataViewMemory0().setFloat64(arg0 + 8 * 1, isLikeNone(ret) ? 0 : ret, true);
|
|
2356
|
+
getDataViewMemory0().setInt32(arg0 + 4 * 0, !isLikeNone(ret), true);
|
|
2357
|
+
};
|
|
2358
|
+
|
|
2252
2359
|
exports.__wbg_wbindgenstringget_0f16a6ddddef376f = function(arg0, arg1) {
|
|
2253
2360
|
const obj = getObject(arg1);
|
|
2254
2361
|
const ret = typeof(obj) === 'string' ? obj : undefined;
|
package/pkg/json_eval_rs_bg.wasm
CHANGED
|
Binary file
|
|
@@ -14,9 +14,9 @@ export const jsonevalwasm_disableCache: (a: number) => void;
|
|
|
14
14
|
export const jsonevalwasm_enableCache: (a: number) => void;
|
|
15
15
|
export const jsonevalwasm_evaluate: (a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: number) => void;
|
|
16
16
|
export const jsonevalwasm_evaluateDependents: (a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: number) => void;
|
|
17
|
-
export const jsonevalwasm_evaluateDependentsJS: (a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: number
|
|
17
|
+
export const jsonevalwasm_evaluateDependentsJS: (a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: number) => void;
|
|
18
18
|
export const jsonevalwasm_evaluateDependentsSubform: (a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: number, i: number, j: number) => void;
|
|
19
|
-
export const jsonevalwasm_evaluateDependentsSubformJS: (a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: number, i: number
|
|
19
|
+
export const jsonevalwasm_evaluateDependentsSubformJS: (a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: number, i: number) => void;
|
|
20
20
|
export const jsonevalwasm_evaluateJS: (a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: number) => void;
|
|
21
21
|
export const jsonevalwasm_evaluateSubform: (a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: number, i: number, j: number) => void;
|
|
22
22
|
export const jsonevalwasm_getEvaluatedSchema: (a: number, b: number, c: number) => void;
|
|
@@ -27,7 +27,7 @@ export const jsonevalwasm_getEvaluatedSchemaByPathSubformJS: (a: number, b: numb
|
|
|
27
27
|
export const jsonevalwasm_getEvaluatedSchemaByPaths: (a: number, b: number, c: number, d: number, e: number, f: number) => void;
|
|
28
28
|
export const jsonevalwasm_getEvaluatedSchemaByPathsJS: (a: number, b: number, c: number, d: number, e: number, f: number) => void;
|
|
29
29
|
export const jsonevalwasm_getEvaluatedSchemaByPathsSubform: (a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: number) => void;
|
|
30
|
-
export const jsonevalwasm_getEvaluatedSchemaByPathsSubformJS: (a: number, b: number, c: number, d: number, e: number, f: number, g: number
|
|
30
|
+
export const jsonevalwasm_getEvaluatedSchemaByPathsSubformJS: (a: number, b: number, c: number, d: number, e: number, f: number, g: number) => void;
|
|
31
31
|
export const jsonevalwasm_getEvaluatedSchemaJS: (a: number, b: number, c: number) => void;
|
|
32
32
|
export const jsonevalwasm_getEvaluatedSchemaMsgpack: (a: number, b: number, c: number) => void;
|
|
33
33
|
export const jsonevalwasm_getEvaluatedSchemaSubform: (a: number, b: number, c: number, d: number, e: number) => void;
|
|
@@ -43,7 +43,7 @@ export const jsonevalwasm_getSchemaByPathSubformJS: (a: number, b: number, c: nu
|
|
|
43
43
|
export const jsonevalwasm_getSchemaByPaths: (a: number, b: number, c: number, d: number, e: number) => void;
|
|
44
44
|
export const jsonevalwasm_getSchemaByPathsJS: (a: number, b: number, c: number, d: number, e: number) => void;
|
|
45
45
|
export const jsonevalwasm_getSchemaByPathsSubform: (a: number, b: number, c: number, d: number, e: number, f: number, g: number) => void;
|
|
46
|
-
export const jsonevalwasm_getSchemaByPathsSubformJS: (a: number, b: number, c: number, d: number, e: number, f: number
|
|
46
|
+
export const jsonevalwasm_getSchemaByPathsSubformJS: (a: number, b: number, c: number, d: number, e: number, f: number) => void;
|
|
47
47
|
export const jsonevalwasm_getSchemaValue: (a: number, b: number) => void;
|
|
48
48
|
export const jsonevalwasm_getSchemaValueSubform: (a: number, b: number, c: number, d: number) => void;
|
|
49
49
|
export const jsonevalwasm_getSubformPaths: (a: number, b: number) => void;
|
|
@@ -78,7 +78,7 @@ export const init: () => void;
|
|
|
78
78
|
export const version: (a: number) => void;
|
|
79
79
|
export const __wbindgen_export_0: (a: number, b: number) => number;
|
|
80
80
|
export const __wbindgen_export_1: (a: number, b: number, c: number, d: number) => number;
|
|
81
|
-
export const __wbindgen_export_2: (a: number
|
|
82
|
-
export const __wbindgen_export_3: (a: number) => void;
|
|
81
|
+
export const __wbindgen_export_2: (a: number) => void;
|
|
82
|
+
export const __wbindgen_export_3: (a: number, b: number, c: number) => void;
|
|
83
83
|
export const __wbindgen_add_to_stack_pointer: (a: number) => number;
|
|
84
84
|
export const __wbindgen_start: () => void;
|