@json-eval-rs/node 0.0.56 → 0.0.57
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
package/pkg/json_eval_rs.d.ts
CHANGED
|
@@ -1,5 +1,9 @@
|
|
|
1
1
|
/* tslint:disable */
|
|
2
2
|
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Initialize the library (sets up panic hook)
|
|
5
|
+
*/
|
|
6
|
+
export function init(): void;
|
|
3
7
|
/**
|
|
4
8
|
* Get the library version
|
|
5
9
|
*/
|
|
@@ -8,10 +12,6 @@ export function getVersion(): string;
|
|
|
8
12
|
* Get library version (alias)
|
|
9
13
|
*/
|
|
10
14
|
export function version(): string;
|
|
11
|
-
/**
|
|
12
|
-
* Initialize the library (sets up panic hook)
|
|
13
|
-
*/
|
|
14
|
-
export function init(): void;
|
|
15
15
|
/**
|
|
16
16
|
* WebAssembly wrapper for JSONEval
|
|
17
17
|
*/
|
|
@@ -547,6 +547,6 @@ export class ValidationResult {
|
|
|
547
547
|
free(): void;
|
|
548
548
|
[Symbol.dispose](): void;
|
|
549
549
|
toJSON(): any;
|
|
550
|
-
readonly
|
|
550
|
+
readonly error: any;
|
|
551
551
|
readonly has_error: boolean;
|
|
552
552
|
}
|
package/pkg/json_eval_rs.js
CHANGED
|
@@ -142,6 +142,13 @@ function passArrayJsValueToWasm0(array, malloc) {
|
|
|
142
142
|
WASM_VECTOR_LEN = array.length;
|
|
143
143
|
return ptr;
|
|
144
144
|
}
|
|
145
|
+
/**
|
|
146
|
+
* Initialize the library (sets up panic hook)
|
|
147
|
+
*/
|
|
148
|
+
exports.init = function() {
|
|
149
|
+
wasm.init();
|
|
150
|
+
};
|
|
151
|
+
|
|
145
152
|
/**
|
|
146
153
|
* Get the library version
|
|
147
154
|
* @returns {string}
|
|
@@ -184,13 +191,6 @@ exports.version = function() {
|
|
|
184
191
|
}
|
|
185
192
|
};
|
|
186
193
|
|
|
187
|
-
/**
|
|
188
|
-
* Initialize the library (sets up panic hook)
|
|
189
|
-
*/
|
|
190
|
-
exports.init = function() {
|
|
191
|
-
wasm.init();
|
|
192
|
-
};
|
|
193
|
-
|
|
194
194
|
function passArray8ToWasm0(arg, malloc) {
|
|
195
195
|
const ptr = malloc(arg.length * 1, 1) >>> 0;
|
|
196
196
|
getUint8ArrayMemory0().set(arg, ptr / 1);
|
|
@@ -1997,14 +1997,6 @@ const ValidationErrorFinalization = (typeof FinalizationRegistry === 'undefined'
|
|
|
1997
1997
|
*/
|
|
1998
1998
|
class ValidationError {
|
|
1999
1999
|
|
|
2000
|
-
static __wrap(ptr) {
|
|
2001
|
-
ptr = ptr >>> 0;
|
|
2002
|
-
const obj = Object.create(ValidationError.prototype);
|
|
2003
|
-
obj.__wbg_ptr = ptr;
|
|
2004
|
-
ValidationErrorFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
2005
|
-
return obj;
|
|
2006
|
-
}
|
|
2007
|
-
|
|
2008
2000
|
__destroy_into_raw() {
|
|
2009
2001
|
const ptr = this.__wbg_ptr;
|
|
2010
2002
|
this.__wbg_ptr = 0;
|
|
@@ -2170,20 +2162,11 @@ class ValidationResult {
|
|
|
2170
2162
|
wasm.__wbg_validationresult_free(ptr, 0);
|
|
2171
2163
|
}
|
|
2172
2164
|
/**
|
|
2173
|
-
* @returns {
|
|
2165
|
+
* @returns {any}
|
|
2174
2166
|
*/
|
|
2175
|
-
get
|
|
2176
|
-
|
|
2177
|
-
|
|
2178
|
-
wasm.validationresult_errors(retptr, this.__wbg_ptr);
|
|
2179
|
-
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
2180
|
-
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
2181
|
-
var v1 = getArrayJsValueFromWasm0(r0, r1).slice();
|
|
2182
|
-
wasm.__wbindgen_export_2(r0, r1 * 4, 4);
|
|
2183
|
-
return v1;
|
|
2184
|
-
} finally {
|
|
2185
|
-
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
2186
|
-
}
|
|
2167
|
+
get error() {
|
|
2168
|
+
const ret = wasm.validationresult_error(this.__wbg_ptr);
|
|
2169
|
+
return takeObject(ret);
|
|
2187
2170
|
}
|
|
2188
2171
|
/**
|
|
2189
2172
|
* @returns {any}
|
|
@@ -2249,7 +2232,7 @@ exports.__wbg_getTime_6bb3f64e0f18f817 = function(arg0) {
|
|
|
2249
2232
|
return ret;
|
|
2250
2233
|
};
|
|
2251
2234
|
|
|
2252
|
-
exports.
|
|
2235
|
+
exports.__wbg_log_c5bf37a3dcf4677e = function(arg0, arg1) {
|
|
2253
2236
|
console.log(getStringFromWasm0(arg0, arg1));
|
|
2254
2237
|
};
|
|
2255
2238
|
|
|
@@ -2299,11 +2282,6 @@ exports.__wbg_stack_0ed75d68575b0f3c = function(arg0, arg1) {
|
|
|
2299
2282
|
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
2300
2283
|
};
|
|
2301
2284
|
|
|
2302
|
-
exports.__wbg_validationerror_new = function(arg0) {
|
|
2303
|
-
const ret = ValidationError.__wrap(arg0);
|
|
2304
|
-
return addHeapObject(ret);
|
|
2305
|
-
};
|
|
2306
|
-
|
|
2307
2285
|
exports.__wbg_wbindgenisstring_d4fa939789f003b0 = function(arg0) {
|
|
2308
2286
|
const ret = typeof(getObject(arg0)) === 'string';
|
|
2309
2287
|
return ret;
|
package/pkg/json_eval_rs_bg.wasm
CHANGED
|
Binary file
|
|
@@ -77,7 +77,7 @@ export const validationerror_message: (a: number, b: number) => void;
|
|
|
77
77
|
export const validationerror_path: (a: number, b: number) => void;
|
|
78
78
|
export const validationerror_pattern: (a: number, b: number) => void;
|
|
79
79
|
export const validationerror_rule_type: (a: number, b: number) => void;
|
|
80
|
-
export const
|
|
80
|
+
export const validationresult_error: (a: number) => number;
|
|
81
81
|
export const validationresult_has_error: (a: number) => number;
|
|
82
82
|
export const validationresult_toJSON: (a: number, b: number) => void;
|
|
83
83
|
export const init: () => void;
|