@xberg-io/crawlberg-wasm 1.8.0 → 1.10.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.
- package/package.json +1 -1
- package/pkg/bundler/crawlberg_wasm.d.ts +634 -26
- package/pkg/bundler/crawlberg_wasm_bg.js +936 -154
- package/pkg/bundler/crawlberg_wasm_bg.wasm +0 -0
- package/pkg/bundler/crawlberg_wasm_bg.wasm.d.ts +69 -7
- package/pkg/bundler/package.json +1 -1
- package/pkg/deno/crawlberg_wasm.d.ts +634 -26
- package/pkg/deno/crawlberg_wasm.js +936 -154
- package/pkg/deno/crawlberg_wasm_bg.wasm +0 -0
- package/pkg/deno/crawlberg_wasm_bg.wasm.d.ts +69 -7
- package/pkg/nodejs/crawlberg_wasm.d.ts +634 -26
- package/pkg/nodejs/crawlberg_wasm.js +936 -154
- package/pkg/nodejs/crawlberg_wasm_bg.wasm +0 -0
- package/pkg/nodejs/crawlberg_wasm_bg.wasm.d.ts +69 -7
- package/pkg/nodejs/package.json +1 -1
- package/pkg/web/crawlberg_wasm.d.ts +703 -33
- package/pkg/web/crawlberg_wasm.js +936 -154
- package/pkg/web/crawlberg_wasm_bg.wasm +0 -0
- package/pkg/web/crawlberg_wasm_bg.wasm.d.ts +69 -7
- package/pkg/web/package.json +1 -1
|
@@ -48,6 +48,17 @@ export class WasmActionResult {
|
|
|
48
48
|
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
49
49
|
}
|
|
50
50
|
}
|
|
51
|
+
/**
|
|
52
|
+
* Return an independent handle for an ownership-taking API.
|
|
53
|
+
*
|
|
54
|
+
* Use `copyForTransfer()` for each class value placed in an array when the original
|
|
55
|
+
* handle must remain usable.
|
|
56
|
+
* @returns {WasmActionResult}
|
|
57
|
+
*/
|
|
58
|
+
copyForTransfer() {
|
|
59
|
+
const ret = wasm.wasmactionresult_copyForTransfer(this.__wbg_ptr);
|
|
60
|
+
return WasmActionResult.__wrap(ret);
|
|
61
|
+
}
|
|
51
62
|
/**
|
|
52
63
|
* @returns {any | undefined}
|
|
53
64
|
*/
|
|
@@ -167,6 +178,17 @@ export class WasmArticleMetadata {
|
|
|
167
178
|
}
|
|
168
179
|
return v1;
|
|
169
180
|
}
|
|
181
|
+
/**
|
|
182
|
+
* Return an independent handle for an ownership-taking API.
|
|
183
|
+
*
|
|
184
|
+
* Use `copyForTransfer()` for each class value placed in an array when the original
|
|
185
|
+
* handle must remain usable.
|
|
186
|
+
* @returns {WasmArticleMetadata}
|
|
187
|
+
*/
|
|
188
|
+
copyForTransfer() {
|
|
189
|
+
const ret = wasm.wasmarticlemetadata_copyForTransfer(this.__wbg_ptr);
|
|
190
|
+
return WasmArticleMetadata.__wrap(ret);
|
|
191
|
+
}
|
|
170
192
|
/**
|
|
171
193
|
* @returns {WasmArticleMetadata}
|
|
172
194
|
*/
|
|
@@ -487,6 +509,20 @@ export class WasmBatchCrawlResult {
|
|
|
487
509
|
const ptr = this.__destroy_into_raw();
|
|
488
510
|
wasm.__wbg_wasmbatchcrawlresult_free(ptr, 0);
|
|
489
511
|
}
|
|
512
|
+
clearResult() {
|
|
513
|
+
wasm.wasmbatchcrawlresult_clearResult(this.__wbg_ptr);
|
|
514
|
+
}
|
|
515
|
+
/**
|
|
516
|
+
* Return an independent handle for an ownership-taking API.
|
|
517
|
+
*
|
|
518
|
+
* Use `copyForTransfer()` for each class value placed in an array when the original
|
|
519
|
+
* handle must remain usable.
|
|
520
|
+
* @returns {WasmBatchCrawlResult}
|
|
521
|
+
*/
|
|
522
|
+
copyForTransfer() {
|
|
523
|
+
const ret = wasm.wasmbatchcrawlresult_copyForTransfer(this.__wbg_ptr);
|
|
524
|
+
return WasmBatchCrawlResult.__wrap(ret);
|
|
525
|
+
}
|
|
490
526
|
/**
|
|
491
527
|
* @returns {WasmBatchCrawlResult}
|
|
492
528
|
*/
|
|
@@ -507,6 +543,11 @@ export class WasmBatchCrawlResult {
|
|
|
507
543
|
return v1;
|
|
508
544
|
}
|
|
509
545
|
/**
|
|
546
|
+
* Takes ownership of `result`.
|
|
547
|
+
* wasm-bindgen lowers a by-value class argument through `__destroy_into_raw()`, so each
|
|
548
|
+
* of those handles is dead once this returns. Passing a freshly built value is fine. To
|
|
549
|
+
* keep a handle you already hold, build with `default()` and assign the property instead:
|
|
550
|
+
* the generated setter borrows and leaves your handle alive.
|
|
510
551
|
* @param {string | null} [url]
|
|
511
552
|
* @param {WasmCrawlResult | null} [result]
|
|
512
553
|
* @param {string | null} [error]
|
|
@@ -527,6 +568,10 @@ export class WasmBatchCrawlResult {
|
|
|
527
568
|
return this;
|
|
528
569
|
}
|
|
529
570
|
/**
|
|
571
|
+
* Returns a detached copy of `result`.
|
|
572
|
+
*
|
|
573
|
+
* Changes to the returned value do not update this object. To update `result`,
|
|
574
|
+
* read it, modify the copy, then assign the copy back to `result`.
|
|
530
575
|
* @returns {WasmCrawlResult | undefined}
|
|
531
576
|
*/
|
|
532
577
|
get result() {
|
|
@@ -542,15 +587,11 @@ export class WasmBatchCrawlResult {
|
|
|
542
587
|
wasm.wasmbatchcrawlresult_set_error(this.__wbg_ptr, ptr0, len0);
|
|
543
588
|
}
|
|
544
589
|
/**
|
|
545
|
-
* @param {WasmCrawlResult
|
|
590
|
+
* @param {WasmCrawlResult} value
|
|
546
591
|
*/
|
|
547
592
|
set result(value) {
|
|
548
|
-
|
|
549
|
-
|
|
550
|
-
_assertClass(value, WasmCrawlResult);
|
|
551
|
-
ptr0 = value.__destroy_into_raw();
|
|
552
|
-
}
|
|
553
|
-
wasm.wasmbatchcrawlresult_set_result(this.__wbg_ptr, ptr0);
|
|
593
|
+
_assertClass(value, WasmCrawlResult);
|
|
594
|
+
wasm.wasmbatchcrawlresult_set_result(this.__wbg_ptr, value.__wbg_ptr);
|
|
554
595
|
}
|
|
555
596
|
/**
|
|
556
597
|
* @param {string} value
|
|
@@ -608,6 +649,17 @@ export class WasmBatchCrawlResults {
|
|
|
608
649
|
const ret = wasm.wasmbatchcrawlresults_completedCount(this.__wbg_ptr);
|
|
609
650
|
return ret >>> 0;
|
|
610
651
|
}
|
|
652
|
+
/**
|
|
653
|
+
* Return an independent handle for an ownership-taking API.
|
|
654
|
+
*
|
|
655
|
+
* Use `copyForTransfer()` for each class value placed in an array when the original
|
|
656
|
+
* handle must remain usable.
|
|
657
|
+
* @returns {WasmBatchCrawlResults}
|
|
658
|
+
*/
|
|
659
|
+
copyForTransfer() {
|
|
660
|
+
const ret = wasm.wasmbatchcrawlresults_copyForTransfer(this.__wbg_ptr);
|
|
661
|
+
return WasmBatchCrawlResults.__wrap(ret);
|
|
662
|
+
}
|
|
611
663
|
/**
|
|
612
664
|
* @returns {WasmBatchCrawlResults}
|
|
613
665
|
*/
|
|
@@ -623,6 +675,9 @@ export class WasmBatchCrawlResults {
|
|
|
623
675
|
return ret >>> 0;
|
|
624
676
|
}
|
|
625
677
|
/**
|
|
678
|
+
* Takes ownership of every element in `results`.
|
|
679
|
+
* wasm-bindgen cannot borrow class values nested in an array. To keep those handles,
|
|
680
|
+
* copy each retained element with `copyForTransfer()` before passing the array.
|
|
626
681
|
* @param {WasmBatchCrawlResult[] | null} [results]
|
|
627
682
|
* @param {number | null} [totalCount]
|
|
628
683
|
* @param {number | null} [completedCount]
|
|
@@ -637,6 +692,10 @@ export class WasmBatchCrawlResults {
|
|
|
637
692
|
return this;
|
|
638
693
|
}
|
|
639
694
|
/**
|
|
695
|
+
* Returns detached copies of the elements in `results`.
|
|
696
|
+
*
|
|
697
|
+
* Changes to the returned values do not update this object. Modify the copies,
|
|
698
|
+
* then assign the array back to `results`.
|
|
640
699
|
* @returns {WasmBatchCrawlResult[]}
|
|
641
700
|
*/
|
|
642
701
|
get results() {
|
|
@@ -658,6 +717,9 @@ export class WasmBatchCrawlResults {
|
|
|
658
717
|
wasm.wasmbatchcrawlresults_set_failedCount(this.__wbg_ptr, value);
|
|
659
718
|
}
|
|
660
719
|
/**
|
|
720
|
+
* Takes ownership of every element in `results`.
|
|
721
|
+
* wasm-bindgen cannot borrow class values nested in an array; copy each retained
|
|
722
|
+
* element with `copyForTransfer()` before passing the array.
|
|
661
723
|
* @param {WasmBatchCrawlResult[]} value
|
|
662
724
|
*/
|
|
663
725
|
set results(value) {
|
|
@@ -707,6 +769,20 @@ export class WasmBatchScrapeResult {
|
|
|
707
769
|
const ptr = this.__destroy_into_raw();
|
|
708
770
|
wasm.__wbg_wasmbatchscraperesult_free(ptr, 0);
|
|
709
771
|
}
|
|
772
|
+
clearResult() {
|
|
773
|
+
wasm.wasmbatchscraperesult_clearResult(this.__wbg_ptr);
|
|
774
|
+
}
|
|
775
|
+
/**
|
|
776
|
+
* Return an independent handle for an ownership-taking API.
|
|
777
|
+
*
|
|
778
|
+
* Use `copyForTransfer()` for each class value placed in an array when the original
|
|
779
|
+
* handle must remain usable.
|
|
780
|
+
* @returns {WasmBatchScrapeResult}
|
|
781
|
+
*/
|
|
782
|
+
copyForTransfer() {
|
|
783
|
+
const ret = wasm.wasmbatchscraperesult_copyForTransfer(this.__wbg_ptr);
|
|
784
|
+
return WasmBatchScrapeResult.__wrap(ret);
|
|
785
|
+
}
|
|
710
786
|
/**
|
|
711
787
|
* @returns {WasmBatchScrapeResult}
|
|
712
788
|
*/
|
|
@@ -727,6 +803,11 @@ export class WasmBatchScrapeResult {
|
|
|
727
803
|
return v1;
|
|
728
804
|
}
|
|
729
805
|
/**
|
|
806
|
+
* Takes ownership of `result`.
|
|
807
|
+
* wasm-bindgen lowers a by-value class argument through `__destroy_into_raw()`, so each
|
|
808
|
+
* of those handles is dead once this returns. Passing a freshly built value is fine. To
|
|
809
|
+
* keep a handle you already hold, build with `default()` and assign the property instead:
|
|
810
|
+
* the generated setter borrows and leaves your handle alive.
|
|
730
811
|
* @param {string | null} [url]
|
|
731
812
|
* @param {WasmScrapeResult | null} [result]
|
|
732
813
|
* @param {string | null} [error]
|
|
@@ -747,6 +828,10 @@ export class WasmBatchScrapeResult {
|
|
|
747
828
|
return this;
|
|
748
829
|
}
|
|
749
830
|
/**
|
|
831
|
+
* Returns a detached copy of `result`.
|
|
832
|
+
*
|
|
833
|
+
* Changes to the returned value do not update this object. To update `result`,
|
|
834
|
+
* read it, modify the copy, then assign the copy back to `result`.
|
|
750
835
|
* @returns {WasmScrapeResult | undefined}
|
|
751
836
|
*/
|
|
752
837
|
get result() {
|
|
@@ -762,15 +847,11 @@ export class WasmBatchScrapeResult {
|
|
|
762
847
|
wasm.wasmbatchscraperesult_set_error(this.__wbg_ptr, ptr0, len0);
|
|
763
848
|
}
|
|
764
849
|
/**
|
|
765
|
-
* @param {WasmScrapeResult
|
|
850
|
+
* @param {WasmScrapeResult} value
|
|
766
851
|
*/
|
|
767
852
|
set result(value) {
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
_assertClass(value, WasmScrapeResult);
|
|
771
|
-
ptr0 = value.__destroy_into_raw();
|
|
772
|
-
}
|
|
773
|
-
wasm.wasmbatchscraperesult_set_result(this.__wbg_ptr, ptr0);
|
|
853
|
+
_assertClass(value, WasmScrapeResult);
|
|
854
|
+
wasm.wasmbatchscraperesult_set_result(this.__wbg_ptr, value.__wbg_ptr);
|
|
774
855
|
}
|
|
775
856
|
/**
|
|
776
857
|
* @param {string} value
|
|
@@ -828,6 +909,17 @@ export class WasmBatchScrapeResults {
|
|
|
828
909
|
const ret = wasm.wasmbatchscraperesults_completedCount(this.__wbg_ptr);
|
|
829
910
|
return ret >>> 0;
|
|
830
911
|
}
|
|
912
|
+
/**
|
|
913
|
+
* Return an independent handle for an ownership-taking API.
|
|
914
|
+
*
|
|
915
|
+
* Use `copyForTransfer()` for each class value placed in an array when the original
|
|
916
|
+
* handle must remain usable.
|
|
917
|
+
* @returns {WasmBatchScrapeResults}
|
|
918
|
+
*/
|
|
919
|
+
copyForTransfer() {
|
|
920
|
+
const ret = wasm.wasmbatchscraperesults_copyForTransfer(this.__wbg_ptr);
|
|
921
|
+
return WasmBatchScrapeResults.__wrap(ret);
|
|
922
|
+
}
|
|
831
923
|
/**
|
|
832
924
|
* @returns {WasmBatchScrapeResults}
|
|
833
925
|
*/
|
|
@@ -843,6 +935,9 @@ export class WasmBatchScrapeResults {
|
|
|
843
935
|
return ret >>> 0;
|
|
844
936
|
}
|
|
845
937
|
/**
|
|
938
|
+
* Takes ownership of every element in `results`.
|
|
939
|
+
* wasm-bindgen cannot borrow class values nested in an array. To keep those handles,
|
|
940
|
+
* copy each retained element with `copyForTransfer()` before passing the array.
|
|
846
941
|
* @param {WasmBatchScrapeResult[] | null} [results]
|
|
847
942
|
* @param {number | null} [totalCount]
|
|
848
943
|
* @param {number | null} [completedCount]
|
|
@@ -857,6 +952,10 @@ export class WasmBatchScrapeResults {
|
|
|
857
952
|
return this;
|
|
858
953
|
}
|
|
859
954
|
/**
|
|
955
|
+
* Returns detached copies of the elements in `results`.
|
|
956
|
+
*
|
|
957
|
+
* Changes to the returned values do not update this object. Modify the copies,
|
|
958
|
+
* then assign the array back to `results`.
|
|
860
959
|
* @returns {WasmBatchScrapeResult[]}
|
|
861
960
|
*/
|
|
862
961
|
get results() {
|
|
@@ -878,6 +977,9 @@ export class WasmBatchScrapeResults {
|
|
|
878
977
|
wasm.wasmbatchscraperesults_set_failedCount(this.__wbg_ptr, value);
|
|
879
978
|
}
|
|
880
979
|
/**
|
|
980
|
+
* Takes ownership of every element in `results`.
|
|
981
|
+
* wasm-bindgen cannot borrow class values nested in an array; copy each retained
|
|
982
|
+
* element with `copyForTransfer()` before passing the array.
|
|
881
983
|
* @param {WasmBatchScrapeResult[]} value
|
|
882
984
|
*/
|
|
883
985
|
set results(value) {
|
|
@@ -961,6 +1063,41 @@ export class WasmBrowserConfig {
|
|
|
961
1063
|
const ret = wasm.wasmbrowserconfig_captureNetworkEvents(this.__wbg_ptr);
|
|
962
1064
|
return ret !== 0;
|
|
963
1065
|
}
|
|
1066
|
+
/**
|
|
1067
|
+
* @returns {string[]}
|
|
1068
|
+
*/
|
|
1069
|
+
get chromeArgs() {
|
|
1070
|
+
const ret = wasm.wasmbrowserconfig_chromeArgs(this.__wbg_ptr);
|
|
1071
|
+
var v1 = getArrayJsValueFromWasm0(ret[0], ret[1]);
|
|
1072
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
|
|
1073
|
+
return v1;
|
|
1074
|
+
}
|
|
1075
|
+
/**
|
|
1076
|
+
* @returns {string | undefined}
|
|
1077
|
+
*/
|
|
1078
|
+
get chromePath() {
|
|
1079
|
+
const ret = wasm.wasmbrowserconfig_chromePath(this.__wbg_ptr);
|
|
1080
|
+
let v1;
|
|
1081
|
+
if (ret[0] !== 0) {
|
|
1082
|
+
v1 = getStringFromWasm0(ret[0], ret[1]);
|
|
1083
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
1084
|
+
}
|
|
1085
|
+
return v1;
|
|
1086
|
+
}
|
|
1087
|
+
clearProxy() {
|
|
1088
|
+
wasm.wasmbrowserconfig_clearProxy(this.__wbg_ptr);
|
|
1089
|
+
}
|
|
1090
|
+
/**
|
|
1091
|
+
* Return an independent handle for an ownership-taking API.
|
|
1092
|
+
*
|
|
1093
|
+
* Use `copyForTransfer()` for each class value placed in an array when the original
|
|
1094
|
+
* handle must remain usable.
|
|
1095
|
+
* @returns {WasmBrowserConfig}
|
|
1096
|
+
*/
|
|
1097
|
+
copyForTransfer() {
|
|
1098
|
+
const ret = wasm.wasmbrowserconfig_copyForTransfer(this.__wbg_ptr);
|
|
1099
|
+
return WasmBrowserConfig.__wrap(ret);
|
|
1100
|
+
}
|
|
964
1101
|
/**
|
|
965
1102
|
* @returns {WasmBrowserConfig}
|
|
966
1103
|
*/
|
|
@@ -1015,6 +1152,11 @@ export class WasmBrowserConfig {
|
|
|
1015
1152
|
}
|
|
1016
1153
|
}
|
|
1017
1154
|
/**
|
|
1155
|
+
* Takes ownership of `proxy`.
|
|
1156
|
+
* wasm-bindgen lowers a by-value class argument through `__destroy_into_raw()`, so each
|
|
1157
|
+
* of those handles is dead once this returns. Passing a freshly built value is fine. To
|
|
1158
|
+
* keep a handle you already hold, build with `default()` and assign the property instead:
|
|
1159
|
+
* the generated setter borrows and leaves your handle alive.
|
|
1018
1160
|
* @param {WasmBrowserMode | null} [mode]
|
|
1019
1161
|
* @param {WasmBrowserBackend | null} [backend]
|
|
1020
1162
|
* @param {bigint | null} [timeout]
|
|
@@ -1024,30 +1166,36 @@ export class WasmBrowserConfig {
|
|
|
1024
1166
|
* @param {string[] | null} [blockUrlPatterns]
|
|
1025
1167
|
* @param {boolean | null} [captureNetworkEvents]
|
|
1026
1168
|
* @param {boolean | null} [sessionAffinity]
|
|
1169
|
+
* @param {string[] | null} [chromeArgs]
|
|
1027
1170
|
* @param {string | null} [endpoint]
|
|
1028
1171
|
* @param {string | null} [waitSelector]
|
|
1029
1172
|
* @param {bigint | null} [extraWait]
|
|
1030
1173
|
* @param {WasmProxyConfig | null} [proxy]
|
|
1031
1174
|
* @param {string | null} [evalScript]
|
|
1032
1175
|
* @param {string | null} [robotsUserAgent]
|
|
1176
|
+
* @param {string | null} [chromePath]
|
|
1033
1177
|
*/
|
|
1034
|
-
constructor(mode, backend, timeout, overallTimeout, shutdownTimeout, wait, blockUrlPatterns, captureNetworkEvents, sessionAffinity, endpoint, waitSelector, extraWait, proxy, evalScript, robotsUserAgent) {
|
|
1178
|
+
constructor(mode, backend, timeout, overallTimeout, shutdownTimeout, wait, blockUrlPatterns, captureNetworkEvents, sessionAffinity, chromeArgs, endpoint, waitSelector, extraWait, proxy, evalScript, robotsUserAgent, chromePath) {
|
|
1035
1179
|
var ptr0 = isLikeNone(blockUrlPatterns) ? 0 : passArrayJsValueToWasm0(blockUrlPatterns, wasm.__wbindgen_malloc);
|
|
1036
1180
|
var len0 = WASM_VECTOR_LEN;
|
|
1037
|
-
var ptr1 = isLikeNone(
|
|
1181
|
+
var ptr1 = isLikeNone(chromeArgs) ? 0 : passArrayJsValueToWasm0(chromeArgs, wasm.__wbindgen_malloc);
|
|
1038
1182
|
var len1 = WASM_VECTOR_LEN;
|
|
1039
|
-
var ptr2 = isLikeNone(
|
|
1183
|
+
var ptr2 = isLikeNone(endpoint) ? 0 : passStringToWasm0(endpoint, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1040
1184
|
var len2 = WASM_VECTOR_LEN;
|
|
1041
|
-
|
|
1185
|
+
var ptr3 = isLikeNone(waitSelector) ? 0 : passStringToWasm0(waitSelector, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1186
|
+
var len3 = WASM_VECTOR_LEN;
|
|
1187
|
+
let ptr4 = 0;
|
|
1042
1188
|
if (!isLikeNone(proxy)) {
|
|
1043
1189
|
_assertClass(proxy, WasmProxyConfig);
|
|
1044
|
-
|
|
1190
|
+
ptr4 = proxy.__destroy_into_raw();
|
|
1045
1191
|
}
|
|
1046
|
-
var
|
|
1047
|
-
var len4 = WASM_VECTOR_LEN;
|
|
1048
|
-
var ptr5 = isLikeNone(robotsUserAgent) ? 0 : passStringToWasm0(robotsUserAgent, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1192
|
+
var ptr5 = isLikeNone(evalScript) ? 0 : passStringToWasm0(evalScript, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1049
1193
|
var len5 = WASM_VECTOR_LEN;
|
|
1050
|
-
|
|
1194
|
+
var ptr6 = isLikeNone(robotsUserAgent) ? 0 : passStringToWasm0(robotsUserAgent, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1195
|
+
var len6 = WASM_VECTOR_LEN;
|
|
1196
|
+
var ptr7 = isLikeNone(chromePath) ? 0 : passStringToWasm0(chromePath, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1197
|
+
var len7 = WASM_VECTOR_LEN;
|
|
1198
|
+
const ret = wasm.wasmbrowserconfig_new(isLikeNone(mode) ? 4 : mode, isLikeNone(backend) ? 2 : backend, !isLikeNone(timeout), isLikeNone(timeout) ? BigInt(0) : timeout, !isLikeNone(overallTimeout), isLikeNone(overallTimeout) ? BigInt(0) : overallTimeout, !isLikeNone(shutdownTimeout), isLikeNone(shutdownTimeout) ? BigInt(0) : shutdownTimeout, isLikeNone(wait) ? 3 : wait, ptr0, len0, isLikeNone(captureNetworkEvents) ? 0xFFFFFF : captureNetworkEvents ? 1 : 0, isLikeNone(sessionAffinity) ? 0xFFFFFF : sessionAffinity ? 1 : 0, ptr1, len1, ptr2, len2, ptr3, len3, !isLikeNone(extraWait), isLikeNone(extraWait) ? BigInt(0) : extraWait, ptr4, ptr5, len5, ptr6, len6, ptr7, len7);
|
|
1051
1199
|
this.__wbg_ptr = ret;
|
|
1052
1200
|
WasmBrowserConfigFinalization.register(this, this.__wbg_ptr, this);
|
|
1053
1201
|
return this;
|
|
@@ -1060,6 +1208,10 @@ export class WasmBrowserConfig {
|
|
|
1060
1208
|
return ret[0] === 0 ? undefined : BigInt.asUintN(64, ret[1]);
|
|
1061
1209
|
}
|
|
1062
1210
|
/**
|
|
1211
|
+
* Returns a detached copy of `proxy`.
|
|
1212
|
+
*
|
|
1213
|
+
* Changes to the returned value do not update this object. To update `proxy`,
|
|
1214
|
+
* read it, modify the copy, then assign the copy back to `proxy`.
|
|
1063
1215
|
* @returns {WasmProxyConfig | undefined}
|
|
1064
1216
|
*/
|
|
1065
1217
|
get proxy() {
|
|
@@ -1105,6 +1257,22 @@ export class WasmBrowserConfig {
|
|
|
1105
1257
|
set captureNetworkEvents(value) {
|
|
1106
1258
|
wasm.wasmbrowserconfig_set_captureNetworkEvents(this.__wbg_ptr, value);
|
|
1107
1259
|
}
|
|
1260
|
+
/**
|
|
1261
|
+
* @param {string[]} value
|
|
1262
|
+
*/
|
|
1263
|
+
set chromeArgs(value) {
|
|
1264
|
+
const ptr0 = passArrayJsValueToWasm0(value, wasm.__wbindgen_malloc);
|
|
1265
|
+
const len0 = WASM_VECTOR_LEN;
|
|
1266
|
+
wasm.wasmbrowserconfig_set_chromeArgs(this.__wbg_ptr, ptr0, len0);
|
|
1267
|
+
}
|
|
1268
|
+
/**
|
|
1269
|
+
* @param {string | null} [value]
|
|
1270
|
+
*/
|
|
1271
|
+
set chromePath(value) {
|
|
1272
|
+
var ptr0 = isLikeNone(value) ? 0 : passStringToWasm0(value, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1273
|
+
var len0 = WASM_VECTOR_LEN;
|
|
1274
|
+
wasm.wasmbrowserconfig_set_chromePath(this.__wbg_ptr, ptr0, len0);
|
|
1275
|
+
}
|
|
1108
1276
|
/**
|
|
1109
1277
|
* @param {string | null} [value]
|
|
1110
1278
|
*/
|
|
@@ -1140,15 +1308,11 @@ export class WasmBrowserConfig {
|
|
|
1140
1308
|
wasm.wasmbrowserconfig_set_overallTimeout(this.__wbg_ptr, !isLikeNone(value), isLikeNone(value) ? BigInt(0) : value);
|
|
1141
1309
|
}
|
|
1142
1310
|
/**
|
|
1143
|
-
* @param {WasmProxyConfig
|
|
1311
|
+
* @param {WasmProxyConfig} value
|
|
1144
1312
|
*/
|
|
1145
1313
|
set proxy(value) {
|
|
1146
|
-
|
|
1147
|
-
|
|
1148
|
-
_assertClass(value, WasmProxyConfig);
|
|
1149
|
-
ptr0 = value.__destroy_into_raw();
|
|
1150
|
-
}
|
|
1151
|
-
wasm.wasmbrowserconfig_set_proxy(this.__wbg_ptr, ptr0);
|
|
1314
|
+
_assertClass(value, WasmProxyConfig);
|
|
1315
|
+
wasm.wasmbrowserconfig_set_proxy(this.__wbg_ptr, value.__wbg_ptr);
|
|
1152
1316
|
}
|
|
1153
1317
|
/**
|
|
1154
1318
|
* @param {string | null} [value]
|
|
@@ -1257,6 +1421,10 @@ export class WasmBrowserExtras {
|
|
|
1257
1421
|
wasm.__wbg_wasmbrowserextras_free(ptr, 0);
|
|
1258
1422
|
}
|
|
1259
1423
|
/**
|
|
1424
|
+
* Returns detached copies of the elements in `cookies`.
|
|
1425
|
+
*
|
|
1426
|
+
* Changes to the returned values do not update this object. Modify the copies,
|
|
1427
|
+
* then assign the array back to `cookies`.
|
|
1260
1428
|
* @returns {WasmCookieInfo[]}
|
|
1261
1429
|
*/
|
|
1262
1430
|
get cookies() {
|
|
@@ -1265,6 +1433,17 @@ export class WasmBrowserExtras {
|
|
|
1265
1433
|
wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
|
|
1266
1434
|
return v1;
|
|
1267
1435
|
}
|
|
1436
|
+
/**
|
|
1437
|
+
* Return an independent handle for an ownership-taking API.
|
|
1438
|
+
*
|
|
1439
|
+
* Use `copyForTransfer()` for each class value placed in an array when the original
|
|
1440
|
+
* handle must remain usable.
|
|
1441
|
+
* @returns {WasmBrowserExtras}
|
|
1442
|
+
*/
|
|
1443
|
+
copyForTransfer() {
|
|
1444
|
+
const ret = wasm.wasmbrowserextras_copyForTransfer(this.__wbg_ptr);
|
|
1445
|
+
return WasmBrowserExtras.__wrap(ret);
|
|
1446
|
+
}
|
|
1268
1447
|
/**
|
|
1269
1448
|
* @returns {WasmBrowserExtras}
|
|
1270
1449
|
*/
|
|
@@ -1280,6 +1459,10 @@ export class WasmBrowserExtras {
|
|
|
1280
1459
|
return ret;
|
|
1281
1460
|
}
|
|
1282
1461
|
/**
|
|
1462
|
+
* Returns detached copies of the elements in `networkEvents`.
|
|
1463
|
+
*
|
|
1464
|
+
* Changes to the returned values do not update this object. Modify the copies,
|
|
1465
|
+
* then assign the array back to `networkEvents`.
|
|
1283
1466
|
* @returns {WasmResponseMeta[]}
|
|
1284
1467
|
*/
|
|
1285
1468
|
get networkEvents() {
|
|
@@ -1289,6 +1472,9 @@ export class WasmBrowserExtras {
|
|
|
1289
1472
|
return v1;
|
|
1290
1473
|
}
|
|
1291
1474
|
/**
|
|
1475
|
+
* Takes ownership of every element in `networkEvents`, `cookies`.
|
|
1476
|
+
* wasm-bindgen cannot borrow class values nested in an array. To keep those handles,
|
|
1477
|
+
* copy each retained element with `copyForTransfer()` before passing the array.
|
|
1292
1478
|
* @param {WasmResponseMeta[] | null} [networkEvents]
|
|
1293
1479
|
* @param {WasmCookieInfo[] | null} [cookies]
|
|
1294
1480
|
* @param {any | null} [evalResult]
|
|
@@ -1304,6 +1490,9 @@ export class WasmBrowserExtras {
|
|
|
1304
1490
|
return this;
|
|
1305
1491
|
}
|
|
1306
1492
|
/**
|
|
1493
|
+
* Takes ownership of every element in `cookies`.
|
|
1494
|
+
* wasm-bindgen cannot borrow class values nested in an array; copy each retained
|
|
1495
|
+
* element with `copyForTransfer()` before passing the array.
|
|
1307
1496
|
* @param {WasmCookieInfo[]} value
|
|
1308
1497
|
*/
|
|
1309
1498
|
set cookies(value) {
|
|
@@ -1318,6 +1507,9 @@ export class WasmBrowserExtras {
|
|
|
1318
1507
|
wasm.wasmbrowserextras_set_evalResult(this.__wbg_ptr, isLikeNone(value) ? 0 : addToExternrefTable0(value));
|
|
1319
1508
|
}
|
|
1320
1509
|
/**
|
|
1510
|
+
* Takes ownership of every element in `networkEvents`.
|
|
1511
|
+
* wasm-bindgen cannot borrow class values nested in an array; copy each retained
|
|
1512
|
+
* element with `copyForTransfer()` before passing the array.
|
|
1321
1513
|
* @param {WasmResponseMeta[]} value
|
|
1322
1514
|
*/
|
|
1323
1515
|
set networkEvents(value) {
|
|
@@ -1376,6 +1568,17 @@ export class WasmCitationReference {
|
|
|
1376
1568
|
const ptr = this.__destroy_into_raw();
|
|
1377
1569
|
wasm.__wbg_wasmcitationreference_free(ptr, 0);
|
|
1378
1570
|
}
|
|
1571
|
+
/**
|
|
1572
|
+
* Return an independent handle for an ownership-taking API.
|
|
1573
|
+
*
|
|
1574
|
+
* Use `copyForTransfer()` for each class value placed in an array when the original
|
|
1575
|
+
* handle must remain usable.
|
|
1576
|
+
* @returns {WasmCitationReference}
|
|
1577
|
+
*/
|
|
1578
|
+
copyForTransfer() {
|
|
1579
|
+
const ret = wasm.wasmcitationreference_copyForTransfer(this.__wbg_ptr);
|
|
1580
|
+
return WasmCitationReference.__wrap(ret);
|
|
1581
|
+
}
|
|
1379
1582
|
/**
|
|
1380
1583
|
* @returns {WasmCitationReference}
|
|
1381
1584
|
*/
|
|
@@ -1495,6 +1698,17 @@ export class WasmCitationResult {
|
|
|
1495
1698
|
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
1496
1699
|
}
|
|
1497
1700
|
}
|
|
1701
|
+
/**
|
|
1702
|
+
* Return an independent handle for an ownership-taking API.
|
|
1703
|
+
*
|
|
1704
|
+
* Use `copyForTransfer()` for each class value placed in an array when the original
|
|
1705
|
+
* handle must remain usable.
|
|
1706
|
+
* @returns {WasmCitationResult}
|
|
1707
|
+
*/
|
|
1708
|
+
copyForTransfer() {
|
|
1709
|
+
const ret = wasm.wasmcitationresult_copyForTransfer(this.__wbg_ptr);
|
|
1710
|
+
return WasmCitationResult.__wrap(ret);
|
|
1711
|
+
}
|
|
1498
1712
|
/**
|
|
1499
1713
|
* @returns {WasmCitationResult}
|
|
1500
1714
|
*/
|
|
@@ -1503,6 +1717,9 @@ export class WasmCitationResult {
|
|
|
1503
1717
|
return WasmCitationResult.__wrap(ret);
|
|
1504
1718
|
}
|
|
1505
1719
|
/**
|
|
1720
|
+
* Takes ownership of every element in `references`.
|
|
1721
|
+
* wasm-bindgen cannot borrow class values nested in an array. To keep those handles,
|
|
1722
|
+
* copy each retained element with `copyForTransfer()` before passing the array.
|
|
1506
1723
|
* @param {string | null} [content]
|
|
1507
1724
|
* @param {WasmCitationReference[] | null} [references]
|
|
1508
1725
|
*/
|
|
@@ -1517,6 +1734,10 @@ export class WasmCitationResult {
|
|
|
1517
1734
|
return this;
|
|
1518
1735
|
}
|
|
1519
1736
|
/**
|
|
1737
|
+
* Returns detached copies of the elements in `references`.
|
|
1738
|
+
*
|
|
1739
|
+
* Changes to the returned values do not update this object. Modify the copies,
|
|
1740
|
+
* then assign the array back to `references`.
|
|
1520
1741
|
* @returns {WasmCitationReference[]}
|
|
1521
1742
|
*/
|
|
1522
1743
|
get references() {
|
|
@@ -1534,6 +1755,9 @@ export class WasmCitationResult {
|
|
|
1534
1755
|
wasm.wasmcitationresult_set_content(this.__wbg_ptr, ptr0, len0);
|
|
1535
1756
|
}
|
|
1536
1757
|
/**
|
|
1758
|
+
* Takes ownership of every element in `references`.
|
|
1759
|
+
* wasm-bindgen cannot borrow class values nested in an array; copy each retained
|
|
1760
|
+
* element with `copyForTransfer()` before passing the array.
|
|
1537
1761
|
* @param {WasmCitationReference[]} value
|
|
1538
1762
|
*/
|
|
1539
1763
|
set references(value) {
|
|
@@ -1568,6 +1792,17 @@ export class WasmContentConfig {
|
|
|
1568
1792
|
const ptr = this.__destroy_into_raw();
|
|
1569
1793
|
wasm.__wbg_wasmcontentconfig_free(ptr, 0);
|
|
1570
1794
|
}
|
|
1795
|
+
/**
|
|
1796
|
+
* Return an independent handle for an ownership-taking API.
|
|
1797
|
+
*
|
|
1798
|
+
* Use `copyForTransfer()` for each class value placed in an array when the original
|
|
1799
|
+
* handle must remain usable.
|
|
1800
|
+
* @returns {WasmContentConfig}
|
|
1801
|
+
*/
|
|
1802
|
+
copyForTransfer() {
|
|
1803
|
+
const ret = wasm.wasmcontentconfig_copyForTransfer(this.__wbg_ptr);
|
|
1804
|
+
return WasmContentConfig.__wrap(ret);
|
|
1805
|
+
}
|
|
1571
1806
|
/**
|
|
1572
1807
|
* @returns {WasmContentConfig}
|
|
1573
1808
|
*/
|
|
@@ -1844,6 +2079,17 @@ export class WasmCookieInfo {
|
|
|
1844
2079
|
const ptr = this.__destroy_into_raw();
|
|
1845
2080
|
wasm.__wbg_wasmcookieinfo_free(ptr, 0);
|
|
1846
2081
|
}
|
|
2082
|
+
/**
|
|
2083
|
+
* Return an independent handle for an ownership-taking API.
|
|
2084
|
+
*
|
|
2085
|
+
* Use `copyForTransfer()` for each class value placed in an array when the original
|
|
2086
|
+
* handle must remain usable.
|
|
2087
|
+
* @returns {WasmCookieInfo}
|
|
2088
|
+
*/
|
|
2089
|
+
copyForTransfer() {
|
|
2090
|
+
const ret = wasm.wasmcookieinfo_copyForTransfer(this.__wbg_ptr);
|
|
2091
|
+
return WasmCookieInfo.__wrap(ret);
|
|
2092
|
+
}
|
|
1847
2093
|
/**
|
|
1848
2094
|
* @returns {WasmCookieInfo}
|
|
1849
2095
|
*/
|
|
@@ -2035,6 +2281,10 @@ export class WasmCrawlConfig {
|
|
|
2035
2281
|
return v1;
|
|
2036
2282
|
}
|
|
2037
2283
|
/**
|
|
2284
|
+
* Returns a detached copy of `browser`.
|
|
2285
|
+
*
|
|
2286
|
+
* Changes to the returned value do not update this object. To update `browser`,
|
|
2287
|
+
* read it, modify the copy, then assign the copy back to `browser`.
|
|
2038
2288
|
* @returns {WasmBrowserConfig}
|
|
2039
2289
|
*/
|
|
2040
2290
|
get browser() {
|
|
@@ -2048,6 +2298,9 @@ export class WasmCrawlConfig {
|
|
|
2048
2298
|
const ret = wasm.wasmcrawlconfig_captureScreenshot(this.__wbg_ptr);
|
|
2049
2299
|
return ret !== 0;
|
|
2050
2300
|
}
|
|
2301
|
+
clearProxy() {
|
|
2302
|
+
wasm.wasmcrawlconfig_clearProxy(this.__wbg_ptr);
|
|
2303
|
+
}
|
|
2051
2304
|
/**
|
|
2052
2305
|
* @returns {string | undefined}
|
|
2053
2306
|
*/
|
|
@@ -2061,6 +2314,10 @@ export class WasmCrawlConfig {
|
|
|
2061
2314
|
return v1;
|
|
2062
2315
|
}
|
|
2063
2316
|
/**
|
|
2317
|
+
* Returns a detached copy of `content`.
|
|
2318
|
+
*
|
|
2319
|
+
* Changes to the returned value do not update this object. To update `content`,
|
|
2320
|
+
* read it, modify the copy, then assign the copy back to `content`.
|
|
2064
2321
|
* @returns {WasmContentConfig}
|
|
2065
2322
|
*/
|
|
2066
2323
|
get content() {
|
|
@@ -2074,6 +2331,17 @@ export class WasmCrawlConfig {
|
|
|
2074
2331
|
const ret = wasm.wasmcrawlconfig_cookiesEnabled(this.__wbg_ptr);
|
|
2075
2332
|
return ret !== 0;
|
|
2076
2333
|
}
|
|
2334
|
+
/**
|
|
2335
|
+
* Return an independent handle for an ownership-taking API.
|
|
2336
|
+
*
|
|
2337
|
+
* Use `copyForTransfer()` for each class value placed in an array when the original
|
|
2338
|
+
* handle must remain usable.
|
|
2339
|
+
* @returns {WasmCrawlConfig}
|
|
2340
|
+
*/
|
|
2341
|
+
copyForTransfer() {
|
|
2342
|
+
const ret = wasm.wasmcrawlconfig_copyForTransfer(this.__wbg_ptr);
|
|
2343
|
+
return WasmCrawlConfig.__wrap(ret);
|
|
2344
|
+
}
|
|
2077
2345
|
/**
|
|
2078
2346
|
* @returns {string}
|
|
2079
2347
|
*/
|
|
@@ -2265,6 +2533,11 @@ export class WasmCrawlConfig {
|
|
|
2265
2533
|
return ret >>> 0;
|
|
2266
2534
|
}
|
|
2267
2535
|
/**
|
|
2536
|
+
* Takes ownership of `content`, `browser`, `proxy`, `ssrf`.
|
|
2537
|
+
* wasm-bindgen lowers a by-value class argument through `__destroy_into_raw()`, so each
|
|
2538
|
+
* of those handles is dead once this returns. Passing a freshly built value is fine. To
|
|
2539
|
+
* keep a handle you already hold, build with `default()` and assign the property instead:
|
|
2540
|
+
* the generated setter borrows and leaves your handle alive.
|
|
2268
2541
|
* @param {WasmCrawlStrategyKind | null} [crawlStrategy]
|
|
2269
2542
|
* @param {boolean | null} [respectRobotsTxt]
|
|
2270
2543
|
* @param {boolean | null} [softHttpErrors]
|
|
@@ -2273,6 +2546,7 @@ export class WasmCrawlConfig {
|
|
|
2273
2546
|
* @param {string[] | null} [includePaths]
|
|
2274
2547
|
* @param {string[] | null} [excludePaths]
|
|
2275
2548
|
* @param {boolean | null} [pathPatternsMatchQuery]
|
|
2549
|
+
* @param {boolean | null} [pathPatternsMatchUrl]
|
|
2276
2550
|
* @param {boolean | null} [dedupIncludeQuery]
|
|
2277
2551
|
* @param {boolean | null} [stripTrackingParams]
|
|
2278
2552
|
* @param {string[] | null} [trackingParams]
|
|
@@ -2320,7 +2594,7 @@ export class WasmCrawlConfig {
|
|
|
2320
2594
|
* @param {string | null} [browserProfile]
|
|
2321
2595
|
* @param {boolean | null} [ssrfDenyPrivateExplicit]
|
|
2322
2596
|
*/
|
|
2323
|
-
constructor(crawlStrategy, respectRobotsTxt, softHttpErrors, stayOnDomain, allowSubdomains, includePaths, excludePaths, pathPatternsMatchQuery, dedupIncludeQuery, stripTrackingParams, trackingParams, customHeaders, requestTimeout, maxRedirects, retryCount, retryCodes, retryInitialDelayMs, retryMaxDelayMs, rateLimitJitterRatio, cookiesEnabled, removeTags, content, downloadAssets, assetTypes, browser, userAgents, captureScreenshot, followDocumentUrls, downloadDocuments, documentMimeTypes, saveBrowserProfile, ssrf, maxDepth, maxPages, maxLinksPerPage, maxConcurrent, contentFilter, bm25Query, bm25Threshold, userAgent, rateLimitMs, auth, maxBodySize, mapLimit, mapSearch, maxAssetSize, proxy, documentUrlDepth, documentMaxSize, documentOutputDir, documentContentEncoding, warcOutput, browserProfile, ssrfDenyPrivateExplicit) {
|
|
2597
|
+
constructor(crawlStrategy, respectRobotsTxt, softHttpErrors, stayOnDomain, allowSubdomains, includePaths, excludePaths, pathPatternsMatchQuery, pathPatternsMatchUrl, dedupIncludeQuery, stripTrackingParams, trackingParams, customHeaders, requestTimeout, maxRedirects, retryCount, retryCodes, retryInitialDelayMs, retryMaxDelayMs, rateLimitJitterRatio, cookiesEnabled, removeTags, content, downloadAssets, assetTypes, browser, userAgents, captureScreenshot, followDocumentUrls, downloadDocuments, documentMimeTypes, saveBrowserProfile, ssrf, maxDepth, maxPages, maxLinksPerPage, maxConcurrent, contentFilter, bm25Query, bm25Threshold, userAgent, rateLimitMs, auth, maxBodySize, mapLimit, mapSearch, maxAssetSize, proxy, documentUrlDepth, documentMaxSize, documentOutputDir, documentContentEncoding, warcOutput, browserProfile, ssrfDenyPrivateExplicit) {
|
|
2324
2598
|
var ptr0 = isLikeNone(includePaths) ? 0 : passArrayJsValueToWasm0(includePaths, wasm.__wbindgen_malloc);
|
|
2325
2599
|
var len0 = WASM_VECTOR_LEN;
|
|
2326
2600
|
var ptr1 = isLikeNone(excludePaths) ? 0 : passArrayJsValueToWasm0(excludePaths, wasm.__wbindgen_malloc);
|
|
@@ -2369,7 +2643,7 @@ export class WasmCrawlConfig {
|
|
|
2369
2643
|
var len16 = WASM_VECTOR_LEN;
|
|
2370
2644
|
var ptr17 = isLikeNone(browserProfile) ? 0 : passStringToWasm0(browserProfile, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
2371
2645
|
var len17 = WASM_VECTOR_LEN;
|
|
2372
|
-
const ret = wasm.wasmcrawlconfig_new(isLikeNone(crawlStrategy) ? 4 : crawlStrategy, isLikeNone(respectRobotsTxt) ? 0xFFFFFF : respectRobotsTxt ? 1 : 0, isLikeNone(softHttpErrors) ? 0xFFFFFF : softHttpErrors ? 1 : 0, isLikeNone(stayOnDomain) ? 0xFFFFFF : stayOnDomain ? 1 : 0, isLikeNone(allowSubdomains) ? 0xFFFFFF : allowSubdomains ? 1 : 0, ptr0, len0, ptr1, len1, isLikeNone(pathPatternsMatchQuery) ? 0xFFFFFF : pathPatternsMatchQuery ? 1 : 0, isLikeNone(dedupIncludeQuery) ? 0xFFFFFF : dedupIncludeQuery ? 1 : 0, isLikeNone(stripTrackingParams) ? 0xFFFFFF : stripTrackingParams ? 1 : 0, ptr2, len2, isLikeNone(customHeaders) ? 0 : addToExternrefTable0(customHeaders), !isLikeNone(requestTimeout), isLikeNone(requestTimeout) ? BigInt(0) : requestTimeout, isLikeNone(maxRedirects) ? Number.MAX_SAFE_INTEGER : (maxRedirects) >>> 0, isLikeNone(retryCount) ? Number.MAX_SAFE_INTEGER : (retryCount) >>> 0, ptr3, len3, !isLikeNone(retryInitialDelayMs), isLikeNone(retryInitialDelayMs) ? BigInt(0) : retryInitialDelayMs, !isLikeNone(retryMaxDelayMs), isLikeNone(retryMaxDelayMs) ? BigInt(0) : retryMaxDelayMs, !isLikeNone(rateLimitJitterRatio), isLikeNone(rateLimitJitterRatio) ? 0 : rateLimitJitterRatio, isLikeNone(cookiesEnabled) ? 0xFFFFFF : cookiesEnabled ? 1 : 0, ptr4, len4, ptr5, isLikeNone(downloadAssets) ? 0xFFFFFF : downloadAssets ? 1 : 0, ptr6, len6, ptr7, ptr8, len8, isLikeNone(captureScreenshot) ? 0xFFFFFF : captureScreenshot ? 1 : 0, isLikeNone(followDocumentUrls) ? 0xFFFFFF : followDocumentUrls ? 1 : 0, isLikeNone(downloadDocuments) ? 0xFFFFFF : downloadDocuments ? 1 : 0, ptr9, len9, isLikeNone(saveBrowserProfile) ? 0xFFFFFF : saveBrowserProfile ? 1 : 0, ptr10, isLikeNone(maxDepth) ? Number.MAX_SAFE_INTEGER : (maxDepth) >>> 0, isLikeNone(maxPages) ? Number.MAX_SAFE_INTEGER : (maxPages) >>> 0, isLikeNone(maxLinksPerPage) ? Number.MAX_SAFE_INTEGER : (maxLinksPerPage) >>> 0, isLikeNone(maxConcurrent) ? Number.MAX_SAFE_INTEGER : (maxConcurrent) >>> 0, isLikeNone(contentFilter) ? 1 : contentFilter, ptr11, len11, !isLikeNone(bm25Threshold), isLikeNone(bm25Threshold) ? 0 : bm25Threshold, ptr12, len12, !isLikeNone(rateLimitMs), isLikeNone(rateLimitMs) ? BigInt(0) : rateLimitMs, isLikeNone(auth) ? 0 : addToExternrefTable0(auth), isLikeNone(maxBodySize) ? Number.MAX_SAFE_INTEGER : (maxBodySize) >>> 0, isLikeNone(mapLimit) ? Number.MAX_SAFE_INTEGER : (mapLimit) >>> 0, ptr13, len13, isLikeNone(maxAssetSize) ? Number.MAX_SAFE_INTEGER : (maxAssetSize) >>> 0, ptr14, isLikeNone(documentUrlDepth) ? Number.MAX_SAFE_INTEGER : (documentUrlDepth) >>> 0, isLikeNone(documentMaxSize) ? Number.MAX_SAFE_INTEGER : (documentMaxSize) >>> 0, ptr15, len15, isLikeNone(documentContentEncoding) ? 1 : documentContentEncoding, ptr16, len16, ptr17, len17, isLikeNone(ssrfDenyPrivateExplicit) ? 0xFFFFFF : ssrfDenyPrivateExplicit ? 1 : 0);
|
|
2646
|
+
const ret = wasm.wasmcrawlconfig_new(isLikeNone(crawlStrategy) ? 4 : crawlStrategy, isLikeNone(respectRobotsTxt) ? 0xFFFFFF : respectRobotsTxt ? 1 : 0, isLikeNone(softHttpErrors) ? 0xFFFFFF : softHttpErrors ? 1 : 0, isLikeNone(stayOnDomain) ? 0xFFFFFF : stayOnDomain ? 1 : 0, isLikeNone(allowSubdomains) ? 0xFFFFFF : allowSubdomains ? 1 : 0, ptr0, len0, ptr1, len1, isLikeNone(pathPatternsMatchQuery) ? 0xFFFFFF : pathPatternsMatchQuery ? 1 : 0, isLikeNone(pathPatternsMatchUrl) ? 0xFFFFFF : pathPatternsMatchUrl ? 1 : 0, isLikeNone(dedupIncludeQuery) ? 0xFFFFFF : dedupIncludeQuery ? 1 : 0, isLikeNone(stripTrackingParams) ? 0xFFFFFF : stripTrackingParams ? 1 : 0, ptr2, len2, isLikeNone(customHeaders) ? 0 : addToExternrefTable0(customHeaders), !isLikeNone(requestTimeout), isLikeNone(requestTimeout) ? BigInt(0) : requestTimeout, isLikeNone(maxRedirects) ? Number.MAX_SAFE_INTEGER : (maxRedirects) >>> 0, isLikeNone(retryCount) ? Number.MAX_SAFE_INTEGER : (retryCount) >>> 0, ptr3, len3, !isLikeNone(retryInitialDelayMs), isLikeNone(retryInitialDelayMs) ? BigInt(0) : retryInitialDelayMs, !isLikeNone(retryMaxDelayMs), isLikeNone(retryMaxDelayMs) ? BigInt(0) : retryMaxDelayMs, !isLikeNone(rateLimitJitterRatio), isLikeNone(rateLimitJitterRatio) ? 0 : rateLimitJitterRatio, isLikeNone(cookiesEnabled) ? 0xFFFFFF : cookiesEnabled ? 1 : 0, ptr4, len4, ptr5, isLikeNone(downloadAssets) ? 0xFFFFFF : downloadAssets ? 1 : 0, ptr6, len6, ptr7, ptr8, len8, isLikeNone(captureScreenshot) ? 0xFFFFFF : captureScreenshot ? 1 : 0, isLikeNone(followDocumentUrls) ? 0xFFFFFF : followDocumentUrls ? 1 : 0, isLikeNone(downloadDocuments) ? 0xFFFFFF : downloadDocuments ? 1 : 0, ptr9, len9, isLikeNone(saveBrowserProfile) ? 0xFFFFFF : saveBrowserProfile ? 1 : 0, ptr10, isLikeNone(maxDepth) ? Number.MAX_SAFE_INTEGER : (maxDepth) >>> 0, isLikeNone(maxPages) ? Number.MAX_SAFE_INTEGER : (maxPages) >>> 0, isLikeNone(maxLinksPerPage) ? Number.MAX_SAFE_INTEGER : (maxLinksPerPage) >>> 0, isLikeNone(maxConcurrent) ? Number.MAX_SAFE_INTEGER : (maxConcurrent) >>> 0, isLikeNone(contentFilter) ? 1 : contentFilter, ptr11, len11, !isLikeNone(bm25Threshold), isLikeNone(bm25Threshold) ? 0 : bm25Threshold, ptr12, len12, !isLikeNone(rateLimitMs), isLikeNone(rateLimitMs) ? BigInt(0) : rateLimitMs, isLikeNone(auth) ? 0 : addToExternrefTable0(auth), isLikeNone(maxBodySize) ? Number.MAX_SAFE_INTEGER : (maxBodySize) >>> 0, isLikeNone(mapLimit) ? Number.MAX_SAFE_INTEGER : (mapLimit) >>> 0, ptr13, len13, isLikeNone(maxAssetSize) ? Number.MAX_SAFE_INTEGER : (maxAssetSize) >>> 0, ptr14, isLikeNone(documentUrlDepth) ? Number.MAX_SAFE_INTEGER : (documentUrlDepth) >>> 0, isLikeNone(documentMaxSize) ? Number.MAX_SAFE_INTEGER : (documentMaxSize) >>> 0, ptr15, len15, isLikeNone(documentContentEncoding) ? 1 : documentContentEncoding, ptr16, len16, ptr17, len17, isLikeNone(ssrfDenyPrivateExplicit) ? 0xFFFFFF : ssrfDenyPrivateExplicit ? 1 : 0);
|
|
2373
2647
|
this.__wbg_ptr = ret;
|
|
2374
2648
|
WasmCrawlConfigFinalization.register(this, this.__wbg_ptr, this);
|
|
2375
2649
|
return this;
|
|
@@ -2382,6 +2656,17 @@ export class WasmCrawlConfig {
|
|
|
2382
2656
|
return ret !== 0;
|
|
2383
2657
|
}
|
|
2384
2658
|
/**
|
|
2659
|
+
* @returns {boolean}
|
|
2660
|
+
*/
|
|
2661
|
+
get pathPatternsMatchUrl() {
|
|
2662
|
+
const ret = wasm.wasmcrawlconfig_pathPatternsMatchUrl(this.__wbg_ptr);
|
|
2663
|
+
return ret !== 0;
|
|
2664
|
+
}
|
|
2665
|
+
/**
|
|
2666
|
+
* Returns a detached copy of `proxy`.
|
|
2667
|
+
*
|
|
2668
|
+
* Changes to the returned value do not update this object. To update `proxy`,
|
|
2669
|
+
* read it, modify the copy, then assign the copy back to `proxy`.
|
|
2385
2670
|
* @returns {WasmProxyConfig | undefined}
|
|
2386
2671
|
*/
|
|
2387
2672
|
get proxy() {
|
|
@@ -2509,8 +2794,7 @@ export class WasmCrawlConfig {
|
|
|
2509
2794
|
*/
|
|
2510
2795
|
set browser(value) {
|
|
2511
2796
|
_assertClass(value, WasmBrowserConfig);
|
|
2512
|
-
|
|
2513
|
-
wasm.wasmcrawlconfig_set_browser(this.__wbg_ptr, ptr0);
|
|
2797
|
+
wasm.wasmcrawlconfig_set_browser(this.__wbg_ptr, value.__wbg_ptr);
|
|
2514
2798
|
}
|
|
2515
2799
|
/**
|
|
2516
2800
|
* @param {boolean} value
|
|
@@ -2529,8 +2813,7 @@ export class WasmCrawlConfig {
|
|
|
2529
2813
|
*/
|
|
2530
2814
|
set content(value) {
|
|
2531
2815
|
_assertClass(value, WasmContentConfig);
|
|
2532
|
-
|
|
2533
|
-
wasm.wasmcrawlconfig_set_content(this.__wbg_ptr, ptr0);
|
|
2816
|
+
wasm.wasmcrawlconfig_set_content(this.__wbg_ptr, value.__wbg_ptr);
|
|
2534
2817
|
}
|
|
2535
2818
|
/**
|
|
2536
2819
|
* @param {boolean} value
|
|
@@ -2687,15 +2970,17 @@ export class WasmCrawlConfig {
|
|
|
2687
2970
|
wasm.wasmcrawlconfig_set_pathPatternsMatchQuery(this.__wbg_ptr, value);
|
|
2688
2971
|
}
|
|
2689
2972
|
/**
|
|
2690
|
-
* @param {
|
|
2973
|
+
* @param {boolean} value
|
|
2974
|
+
*/
|
|
2975
|
+
set pathPatternsMatchUrl(value) {
|
|
2976
|
+
wasm.wasmcrawlconfig_set_pathPatternsMatchUrl(this.__wbg_ptr, value);
|
|
2977
|
+
}
|
|
2978
|
+
/**
|
|
2979
|
+
* @param {WasmProxyConfig} value
|
|
2691
2980
|
*/
|
|
2692
2981
|
set proxy(value) {
|
|
2693
|
-
|
|
2694
|
-
|
|
2695
|
-
_assertClass(value, WasmProxyConfig);
|
|
2696
|
-
ptr0 = value.__destroy_into_raw();
|
|
2697
|
-
}
|
|
2698
|
-
wasm.wasmcrawlconfig_set_proxy(this.__wbg_ptr, ptr0);
|
|
2982
|
+
_assertClass(value, WasmProxyConfig);
|
|
2983
|
+
wasm.wasmcrawlconfig_set_proxy(this.__wbg_ptr, value.__wbg_ptr);
|
|
2699
2984
|
}
|
|
2700
2985
|
/**
|
|
2701
2986
|
* @param {number} value
|
|
@@ -2778,8 +3063,7 @@ export class WasmCrawlConfig {
|
|
|
2778
3063
|
*/
|
|
2779
3064
|
set ssrf(value) {
|
|
2780
3065
|
_assertClass(value, WasmSsrfPolicy);
|
|
2781
|
-
|
|
2782
|
-
wasm.wasmcrawlconfig_set_ssrf(this.__wbg_ptr, ptr0);
|
|
3066
|
+
wasm.wasmcrawlconfig_set_ssrf(this.__wbg_ptr, value.__wbg_ptr);
|
|
2783
3067
|
}
|
|
2784
3068
|
/**
|
|
2785
3069
|
* @param {boolean} value
|
|
@@ -2840,6 +3124,10 @@ export class WasmCrawlConfig {
|
|
|
2840
3124
|
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
2841
3125
|
}
|
|
2842
3126
|
/**
|
|
3127
|
+
* Returns a detached copy of `ssrf`.
|
|
3128
|
+
*
|
|
3129
|
+
* Changes to the returned value do not update this object. To update `ssrf`,
|
|
3130
|
+
* read it, modify the copy, then assign the copy back to `ssrf`.
|
|
2843
3131
|
* @returns {WasmSsrfPolicy}
|
|
2844
3132
|
*/
|
|
2845
3133
|
get ssrf() {
|
|
@@ -2940,6 +3228,17 @@ export class WasmCrawlEngineHandle {
|
|
|
2940
3228
|
const ptr = this.__destroy_into_raw();
|
|
2941
3229
|
wasm.__wbg_wasmcrawlenginehandle_free(ptr, 0);
|
|
2942
3230
|
}
|
|
3231
|
+
/**
|
|
3232
|
+
* Return an independent handle for an ownership-taking API.
|
|
3233
|
+
*
|
|
3234
|
+
* Use `copyForTransfer()` for each class value placed in an array when the original
|
|
3235
|
+
* handle must remain usable.
|
|
3236
|
+
* @returns {WasmCrawlEngineHandle}
|
|
3237
|
+
*/
|
|
3238
|
+
copyForTransfer() {
|
|
3239
|
+
const ret = wasm.wasmcrawlenginehandle_copyForTransfer(this.__wbg_ptr);
|
|
3240
|
+
return WasmCrawlEngineHandle.__wrap(ret);
|
|
3241
|
+
}
|
|
2943
3242
|
}
|
|
2944
3243
|
if (Symbol.dispose) WasmCrawlEngineHandle.prototype[Symbol.dispose] = WasmCrawlEngineHandle.prototype.free;
|
|
2945
3244
|
|
|
@@ -2983,6 +3282,15 @@ export class WasmCrawlPageResult {
|
|
|
2983
3282
|
const ret = wasm.wasmcrawlpageresult_browserUsed(this.__wbg_ptr);
|
|
2984
3283
|
return ret !== 0;
|
|
2985
3284
|
}
|
|
3285
|
+
clearDownloadedDocument() {
|
|
3286
|
+
wasm.wasmcrawlpageresult_clearDownloadedDocument(this.__wbg_ptr);
|
|
3287
|
+
}
|
|
3288
|
+
clearExtractionMeta() {
|
|
3289
|
+
wasm.wasmcrawlpageresult_clearExtractionMeta(this.__wbg_ptr);
|
|
3290
|
+
}
|
|
3291
|
+
clearMarkdown() {
|
|
3292
|
+
wasm.wasmcrawlpageresult_clearMarkdown(this.__wbg_ptr);
|
|
3293
|
+
}
|
|
2986
3294
|
/**
|
|
2987
3295
|
* @returns {string}
|
|
2988
3296
|
*/
|
|
@@ -2998,6 +3306,17 @@ export class WasmCrawlPageResult {
|
|
|
2998
3306
|
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
2999
3307
|
}
|
|
3000
3308
|
}
|
|
3309
|
+
/**
|
|
3310
|
+
* Return an independent handle for an ownership-taking API.
|
|
3311
|
+
*
|
|
3312
|
+
* Use `copyForTransfer()` for each class value placed in an array when the original
|
|
3313
|
+
* handle must remain usable.
|
|
3314
|
+
* @returns {WasmCrawlPageResult}
|
|
3315
|
+
*/
|
|
3316
|
+
copyForTransfer() {
|
|
3317
|
+
const ret = wasm.wasmcrawlpageresult_copyForTransfer(this.__wbg_ptr);
|
|
3318
|
+
return WasmCrawlPageResult.__wrap(ret);
|
|
3319
|
+
}
|
|
3001
3320
|
/**
|
|
3002
3321
|
* @returns {WasmCrawlPageResult}
|
|
3003
3322
|
*/
|
|
@@ -3025,6 +3344,10 @@ export class WasmCrawlPageResult {
|
|
|
3025
3344
|
return v1;
|
|
3026
3345
|
}
|
|
3027
3346
|
/**
|
|
3347
|
+
* Returns a detached copy of `downloadedDocument`.
|
|
3348
|
+
*
|
|
3349
|
+
* Changes to the returned value do not update this object. To update `downloadedDocument`,
|
|
3350
|
+
* read it, modify the copy, then assign the copy back to `downloadedDocument`.
|
|
3028
3351
|
* @returns {WasmDownloadedDocument | undefined}
|
|
3029
3352
|
*/
|
|
3030
3353
|
get downloadedDocument() {
|
|
@@ -3039,6 +3362,10 @@ export class WasmCrawlPageResult {
|
|
|
3039
3362
|
return ret;
|
|
3040
3363
|
}
|
|
3041
3364
|
/**
|
|
3365
|
+
* Returns a detached copy of `extractionMeta`.
|
|
3366
|
+
*
|
|
3367
|
+
* Changes to the returned value do not update this object. To update `extractionMeta`,
|
|
3368
|
+
* read it, modify the copy, then assign the copy back to `extractionMeta`.
|
|
3042
3369
|
* @returns {WasmExtractionMeta | undefined}
|
|
3043
3370
|
*/
|
|
3044
3371
|
get extractionMeta() {
|
|
@@ -3046,6 +3373,10 @@ export class WasmCrawlPageResult {
|
|
|
3046
3373
|
return ret === 0 ? undefined : WasmExtractionMeta.__wrap(ret);
|
|
3047
3374
|
}
|
|
3048
3375
|
/**
|
|
3376
|
+
* Returns detached copies of the elements in `feeds`.
|
|
3377
|
+
*
|
|
3378
|
+
* Changes to the returned values do not update this object. Modify the copies,
|
|
3379
|
+
* then assign the array back to `feeds`.
|
|
3049
3380
|
* @returns {WasmFeedInfo[]}
|
|
3050
3381
|
*/
|
|
3051
3382
|
get feeds() {
|
|
@@ -3085,6 +3416,10 @@ export class WasmCrawlPageResult {
|
|
|
3085
3416
|
}
|
|
3086
3417
|
}
|
|
3087
3418
|
/**
|
|
3419
|
+
* Returns detached copies of the elements in `images`.
|
|
3420
|
+
*
|
|
3421
|
+
* Changes to the returned values do not update this object. Modify the copies,
|
|
3422
|
+
* then assign the array back to `images`.
|
|
3088
3423
|
* @returns {WasmImageInfo[]}
|
|
3089
3424
|
*/
|
|
3090
3425
|
get images() {
|
|
@@ -3101,6 +3436,10 @@ export class WasmCrawlPageResult {
|
|
|
3101
3436
|
return ret !== 0;
|
|
3102
3437
|
}
|
|
3103
3438
|
/**
|
|
3439
|
+
* Returns detached copies of the elements in `jsonLd`.
|
|
3440
|
+
*
|
|
3441
|
+
* Changes to the returned values do not update this object. Modify the copies,
|
|
3442
|
+
* then assign the array back to `jsonLd`.
|
|
3104
3443
|
* @returns {WasmJsonLdEntry[]}
|
|
3105
3444
|
*/
|
|
3106
3445
|
get jsonLd() {
|
|
@@ -3110,6 +3449,10 @@ export class WasmCrawlPageResult {
|
|
|
3110
3449
|
return v1;
|
|
3111
3450
|
}
|
|
3112
3451
|
/**
|
|
3452
|
+
* Returns detached copies of the elements in `links`.
|
|
3453
|
+
*
|
|
3454
|
+
* Changes to the returned values do not update this object. Modify the copies,
|
|
3455
|
+
* then assign the array back to `links`.
|
|
3113
3456
|
* @returns {WasmLinkInfo[]}
|
|
3114
3457
|
*/
|
|
3115
3458
|
get links() {
|
|
@@ -3119,6 +3462,10 @@ export class WasmCrawlPageResult {
|
|
|
3119
3462
|
return v1;
|
|
3120
3463
|
}
|
|
3121
3464
|
/**
|
|
3465
|
+
* Returns a detached copy of `markdown`.
|
|
3466
|
+
*
|
|
3467
|
+
* Changes to the returned value do not update this object. To update `markdown`,
|
|
3468
|
+
* read it, modify the copy, then assign the copy back to `markdown`.
|
|
3122
3469
|
* @returns {WasmMarkdownResult | undefined}
|
|
3123
3470
|
*/
|
|
3124
3471
|
get markdown() {
|
|
@@ -3126,6 +3473,10 @@ export class WasmCrawlPageResult {
|
|
|
3126
3473
|
return ret === 0 ? undefined : WasmMarkdownResult.__wrap(ret);
|
|
3127
3474
|
}
|
|
3128
3475
|
/**
|
|
3476
|
+
* Returns a detached copy of `metadata`.
|
|
3477
|
+
*
|
|
3478
|
+
* Changes to the returned value do not update this object. To update `metadata`,
|
|
3479
|
+
* read it, modify the copy, then assign the copy back to `metadata`.
|
|
3129
3480
|
* @returns {WasmPageMetadata}
|
|
3130
3481
|
*/
|
|
3131
3482
|
get metadata() {
|
|
@@ -3133,6 +3484,14 @@ export class WasmCrawlPageResult {
|
|
|
3133
3484
|
return WasmPageMetadata.__wrap(ret);
|
|
3134
3485
|
}
|
|
3135
3486
|
/**
|
|
3487
|
+
* Takes ownership of `metadata`, `markdown`, `extractionMeta`, `downloadedDocument`.
|
|
3488
|
+
* wasm-bindgen lowers a by-value class argument through `__destroy_into_raw()`, so each
|
|
3489
|
+
* of those handles is dead once this returns. Passing a freshly built value is fine. To
|
|
3490
|
+
* keep a handle you already hold, build with `default()` and assign the property instead:
|
|
3491
|
+
* the generated setter borrows and leaves your handle alive.
|
|
3492
|
+
* Takes ownership of every element in `links`, `images`, `feeds`, `jsonLd`.
|
|
3493
|
+
* wasm-bindgen cannot borrow class values nested in an array. To keep those handles,
|
|
3494
|
+
* copy each retained element with `copyForTransfer()` before passing the array.
|
|
3136
3495
|
* @param {string | null} [url]
|
|
3137
3496
|
* @param {string | null} [normalizedUrl]
|
|
3138
3497
|
* @param {number | null} [statusCode]
|
|
@@ -3153,13 +3512,14 @@ export class WasmCrawlPageResult {
|
|
|
3153
3512
|
* @param {number | null} [redirectCount]
|
|
3154
3513
|
* @param {boolean | null} [noindexDetected]
|
|
3155
3514
|
* @param {boolean | null} [nofollowDetected]
|
|
3515
|
+
* @param {string[] | null} [ssrfRefusedUrls]
|
|
3156
3516
|
* @param {string | null} [detectedCharset]
|
|
3157
3517
|
* @param {WasmMarkdownResult | null} [markdown]
|
|
3158
3518
|
* @param {any | null} [extractedData]
|
|
3159
3519
|
* @param {WasmExtractionMeta | null} [extractionMeta]
|
|
3160
3520
|
* @param {WasmDownloadedDocument | null} [downloadedDocument]
|
|
3161
3521
|
*/
|
|
3162
|
-
constructor(url, normalizedUrl, statusCode, contentType, html, bodySize, metadata, links, images, feeds, jsonLd, depth, stayedOnDomain, wasSkipped, isPdf, browserUsed, finalUrl, redirectCount, noindexDetected, nofollowDetected, detectedCharset, markdown, extractedData, extractionMeta, downloadedDocument) {
|
|
3522
|
+
constructor(url, normalizedUrl, statusCode, contentType, html, bodySize, metadata, links, images, feeds, jsonLd, depth, stayedOnDomain, wasSkipped, isPdf, browserUsed, finalUrl, redirectCount, noindexDetected, nofollowDetected, ssrfRefusedUrls, detectedCharset, markdown, extractedData, extractionMeta, downloadedDocument) {
|
|
3163
3523
|
var ptr0 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
3164
3524
|
var len0 = WASM_VECTOR_LEN;
|
|
3165
3525
|
var ptr1 = isLikeNone(normalizedUrl) ? 0 : passStringToWasm0(normalizedUrl, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
@@ -3183,24 +3543,26 @@ export class WasmCrawlPageResult {
|
|
|
3183
3543
|
var len8 = WASM_VECTOR_LEN;
|
|
3184
3544
|
var ptr9 = isLikeNone(finalUrl) ? 0 : passStringToWasm0(finalUrl, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
3185
3545
|
var len9 = WASM_VECTOR_LEN;
|
|
3186
|
-
var ptr10 = isLikeNone(
|
|
3546
|
+
var ptr10 = isLikeNone(ssrfRefusedUrls) ? 0 : passArrayJsValueToWasm0(ssrfRefusedUrls, wasm.__wbindgen_malloc);
|
|
3187
3547
|
var len10 = WASM_VECTOR_LEN;
|
|
3188
|
-
|
|
3548
|
+
var ptr11 = isLikeNone(detectedCharset) ? 0 : passStringToWasm0(detectedCharset, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
3549
|
+
var len11 = WASM_VECTOR_LEN;
|
|
3550
|
+
let ptr12 = 0;
|
|
3189
3551
|
if (!isLikeNone(markdown)) {
|
|
3190
3552
|
_assertClass(markdown, WasmMarkdownResult);
|
|
3191
|
-
|
|
3553
|
+
ptr12 = markdown.__destroy_into_raw();
|
|
3192
3554
|
}
|
|
3193
|
-
let
|
|
3555
|
+
let ptr13 = 0;
|
|
3194
3556
|
if (!isLikeNone(extractionMeta)) {
|
|
3195
3557
|
_assertClass(extractionMeta, WasmExtractionMeta);
|
|
3196
|
-
|
|
3558
|
+
ptr13 = extractionMeta.__destroy_into_raw();
|
|
3197
3559
|
}
|
|
3198
|
-
let
|
|
3560
|
+
let ptr14 = 0;
|
|
3199
3561
|
if (!isLikeNone(downloadedDocument)) {
|
|
3200
3562
|
_assertClass(downloadedDocument, WasmDownloadedDocument);
|
|
3201
|
-
|
|
3563
|
+
ptr14 = downloadedDocument.__destroy_into_raw();
|
|
3202
3564
|
}
|
|
3203
|
-
const ret = wasm.wasmcrawlpageresult_new(ptr0, len0, ptr1, len1, isLikeNone(statusCode) ? 0xFFFFFF : statusCode, ptr2, len2, ptr3, len3, isLikeNone(bodySize) ? Number.MAX_SAFE_INTEGER : (bodySize) >>> 0, ptr4, ptr5, len5, ptr6, len6, ptr7, len7, ptr8, len8, isLikeNone(depth) ? Number.MAX_SAFE_INTEGER : (depth) >>> 0, isLikeNone(stayedOnDomain) ? 0xFFFFFF : stayedOnDomain ? 1 : 0, isLikeNone(wasSkipped) ? 0xFFFFFF : wasSkipped ? 1 : 0, isLikeNone(isPdf) ? 0xFFFFFF : isPdf ? 1 : 0, isLikeNone(browserUsed) ? 0xFFFFFF : browserUsed ? 1 : 0, ptr9, len9, isLikeNone(redirectCount) ? Number.MAX_SAFE_INTEGER : (redirectCount) >>> 0, isLikeNone(noindexDetected) ? 0xFFFFFF : noindexDetected ? 1 : 0, isLikeNone(nofollowDetected) ? 0xFFFFFF : nofollowDetected ? 1 : 0, ptr10, len10, ptr11, isLikeNone(extractedData) ? 0 : addToExternrefTable0(extractedData),
|
|
3565
|
+
const ret = wasm.wasmcrawlpageresult_new(ptr0, len0, ptr1, len1, isLikeNone(statusCode) ? 0xFFFFFF : statusCode, ptr2, len2, ptr3, len3, isLikeNone(bodySize) ? Number.MAX_SAFE_INTEGER : (bodySize) >>> 0, ptr4, ptr5, len5, ptr6, len6, ptr7, len7, ptr8, len8, isLikeNone(depth) ? Number.MAX_SAFE_INTEGER : (depth) >>> 0, isLikeNone(stayedOnDomain) ? 0xFFFFFF : stayedOnDomain ? 1 : 0, isLikeNone(wasSkipped) ? 0xFFFFFF : wasSkipped ? 1 : 0, isLikeNone(isPdf) ? 0xFFFFFF : isPdf ? 1 : 0, isLikeNone(browserUsed) ? 0xFFFFFF : browserUsed ? 1 : 0, ptr9, len9, isLikeNone(redirectCount) ? Number.MAX_SAFE_INTEGER : (redirectCount) >>> 0, isLikeNone(noindexDetected) ? 0xFFFFFF : noindexDetected ? 1 : 0, isLikeNone(nofollowDetected) ? 0xFFFFFF : nofollowDetected ? 1 : 0, ptr10, len10, ptr11, len11, ptr12, isLikeNone(extractedData) ? 0 : addToExternrefTable0(extractedData), ptr13, ptr14);
|
|
3204
3566
|
this.__wbg_ptr = ret;
|
|
3205
3567
|
WasmCrawlPageResultFinalization.register(this, this.__wbg_ptr, this);
|
|
3206
3568
|
return this;
|
|
@@ -3276,15 +3638,11 @@ export class WasmCrawlPageResult {
|
|
|
3276
3638
|
wasm.wasmcrawlpageresult_set_detectedCharset(this.__wbg_ptr, ptr0, len0);
|
|
3277
3639
|
}
|
|
3278
3640
|
/**
|
|
3279
|
-
* @param {WasmDownloadedDocument
|
|
3641
|
+
* @param {WasmDownloadedDocument} value
|
|
3280
3642
|
*/
|
|
3281
3643
|
set downloadedDocument(value) {
|
|
3282
|
-
|
|
3283
|
-
|
|
3284
|
-
_assertClass(value, WasmDownloadedDocument);
|
|
3285
|
-
ptr0 = value.__destroy_into_raw();
|
|
3286
|
-
}
|
|
3287
|
-
wasm.wasmcrawlpageresult_set_downloadedDocument(this.__wbg_ptr, ptr0);
|
|
3644
|
+
_assertClass(value, WasmDownloadedDocument);
|
|
3645
|
+
wasm.wasmcrawlpageresult_set_downloadedDocument(this.__wbg_ptr, value.__wbg_ptr);
|
|
3288
3646
|
}
|
|
3289
3647
|
/**
|
|
3290
3648
|
* @param {any | null} [value]
|
|
@@ -3293,17 +3651,16 @@ export class WasmCrawlPageResult {
|
|
|
3293
3651
|
wasm.wasmcrawlpageresult_set_extractedData(this.__wbg_ptr, isLikeNone(value) ? 0 : addToExternrefTable0(value));
|
|
3294
3652
|
}
|
|
3295
3653
|
/**
|
|
3296
|
-
* @param {WasmExtractionMeta
|
|
3654
|
+
* @param {WasmExtractionMeta} value
|
|
3297
3655
|
*/
|
|
3298
3656
|
set extractionMeta(value) {
|
|
3299
|
-
|
|
3300
|
-
|
|
3301
|
-
_assertClass(value, WasmExtractionMeta);
|
|
3302
|
-
ptr0 = value.__destroy_into_raw();
|
|
3303
|
-
}
|
|
3304
|
-
wasm.wasmcrawlpageresult_set_extractionMeta(this.__wbg_ptr, ptr0);
|
|
3657
|
+
_assertClass(value, WasmExtractionMeta);
|
|
3658
|
+
wasm.wasmcrawlpageresult_set_extractionMeta(this.__wbg_ptr, value.__wbg_ptr);
|
|
3305
3659
|
}
|
|
3306
3660
|
/**
|
|
3661
|
+
* Takes ownership of every element in `feeds`.
|
|
3662
|
+
* wasm-bindgen cannot borrow class values nested in an array; copy each retained
|
|
3663
|
+
* element with `copyForTransfer()` before passing the array.
|
|
3307
3664
|
* @param {WasmFeedInfo[]} value
|
|
3308
3665
|
*/
|
|
3309
3666
|
set feeds(value) {
|
|
@@ -3328,6 +3685,9 @@ export class WasmCrawlPageResult {
|
|
|
3328
3685
|
wasm.wasmcrawlpageresult_set_html(this.__wbg_ptr, ptr0, len0);
|
|
3329
3686
|
}
|
|
3330
3687
|
/**
|
|
3688
|
+
* Takes ownership of every element in `images`.
|
|
3689
|
+
* wasm-bindgen cannot borrow class values nested in an array; copy each retained
|
|
3690
|
+
* element with `copyForTransfer()` before passing the array.
|
|
3331
3691
|
* @param {WasmImageInfo[]} value
|
|
3332
3692
|
*/
|
|
3333
3693
|
set images(value) {
|
|
@@ -3342,6 +3702,9 @@ export class WasmCrawlPageResult {
|
|
|
3342
3702
|
wasm.wasmcrawlpageresult_set_isPdf(this.__wbg_ptr, value);
|
|
3343
3703
|
}
|
|
3344
3704
|
/**
|
|
3705
|
+
* Takes ownership of every element in `jsonLd`.
|
|
3706
|
+
* wasm-bindgen cannot borrow class values nested in an array; copy each retained
|
|
3707
|
+
* element with `copyForTransfer()` before passing the array.
|
|
3345
3708
|
* @param {WasmJsonLdEntry[]} value
|
|
3346
3709
|
*/
|
|
3347
3710
|
set jsonLd(value) {
|
|
@@ -3350,6 +3713,9 @@ export class WasmCrawlPageResult {
|
|
|
3350
3713
|
wasm.wasmcrawlpageresult_set_jsonLd(this.__wbg_ptr, ptr0, len0);
|
|
3351
3714
|
}
|
|
3352
3715
|
/**
|
|
3716
|
+
* Takes ownership of every element in `links`.
|
|
3717
|
+
* wasm-bindgen cannot borrow class values nested in an array; copy each retained
|
|
3718
|
+
* element with `copyForTransfer()` before passing the array.
|
|
3353
3719
|
* @param {WasmLinkInfo[]} value
|
|
3354
3720
|
*/
|
|
3355
3721
|
set links(value) {
|
|
@@ -3358,23 +3724,18 @@ export class WasmCrawlPageResult {
|
|
|
3358
3724
|
wasm.wasmcrawlpageresult_set_links(this.__wbg_ptr, ptr0, len0);
|
|
3359
3725
|
}
|
|
3360
3726
|
/**
|
|
3361
|
-
* @param {WasmMarkdownResult
|
|
3727
|
+
* @param {WasmMarkdownResult} value
|
|
3362
3728
|
*/
|
|
3363
3729
|
set markdown(value) {
|
|
3364
|
-
|
|
3365
|
-
|
|
3366
|
-
_assertClass(value, WasmMarkdownResult);
|
|
3367
|
-
ptr0 = value.__destroy_into_raw();
|
|
3368
|
-
}
|
|
3369
|
-
wasm.wasmcrawlpageresult_set_markdown(this.__wbg_ptr, ptr0);
|
|
3730
|
+
_assertClass(value, WasmMarkdownResult);
|
|
3731
|
+
wasm.wasmcrawlpageresult_set_markdown(this.__wbg_ptr, value.__wbg_ptr);
|
|
3370
3732
|
}
|
|
3371
3733
|
/**
|
|
3372
3734
|
* @param {WasmPageMetadata} value
|
|
3373
3735
|
*/
|
|
3374
3736
|
set metadata(value) {
|
|
3375
3737
|
_assertClass(value, WasmPageMetadata);
|
|
3376
|
-
|
|
3377
|
-
wasm.wasmcrawlpageresult_set_metadata(this.__wbg_ptr, ptr0);
|
|
3738
|
+
wasm.wasmcrawlpageresult_set_metadata(this.__wbg_ptr, value.__wbg_ptr);
|
|
3378
3739
|
}
|
|
3379
3740
|
/**
|
|
3380
3741
|
* @param {boolean} value
|
|
@@ -3402,6 +3763,14 @@ export class WasmCrawlPageResult {
|
|
|
3402
3763
|
set redirectCount(value) {
|
|
3403
3764
|
wasm.wasmcrawlpageresult_set_redirectCount(this.__wbg_ptr, value);
|
|
3404
3765
|
}
|
|
3766
|
+
/**
|
|
3767
|
+
* @param {string[]} value
|
|
3768
|
+
*/
|
|
3769
|
+
set ssrfRefusedUrls(value) {
|
|
3770
|
+
const ptr0 = passArrayJsValueToWasm0(value, wasm.__wbindgen_malloc);
|
|
3771
|
+
const len0 = WASM_VECTOR_LEN;
|
|
3772
|
+
wasm.wasmcrawlpageresult_set_ssrfRefusedUrls(this.__wbg_ptr, ptr0, len0);
|
|
3773
|
+
}
|
|
3405
3774
|
/**
|
|
3406
3775
|
* @param {number} value
|
|
3407
3776
|
*/
|
|
@@ -3428,6 +3797,15 @@ export class WasmCrawlPageResult {
|
|
|
3428
3797
|
set wasSkipped(value) {
|
|
3429
3798
|
wasm.wasmcrawlpageresult_set_wasSkipped(this.__wbg_ptr, value);
|
|
3430
3799
|
}
|
|
3800
|
+
/**
|
|
3801
|
+
* @returns {string[]}
|
|
3802
|
+
*/
|
|
3803
|
+
get ssrfRefusedUrls() {
|
|
3804
|
+
const ret = wasm.wasmcrawlpageresult_ssrfRefusedUrls(this.__wbg_ptr);
|
|
3805
|
+
var v1 = getArrayJsValueFromWasm0(ret[0], ret[1]);
|
|
3806
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
|
|
3807
|
+
return v1;
|
|
3808
|
+
}
|
|
3431
3809
|
/**
|
|
3432
3810
|
* @returns {number}
|
|
3433
3811
|
*/
|
|
@@ -3495,6 +3873,10 @@ export class WasmCrawlResult {
|
|
|
3495
3873
|
return ret !== 0;
|
|
3496
3874
|
}
|
|
3497
3875
|
/**
|
|
3876
|
+
* Returns detached copies of the elements in `cookies`.
|
|
3877
|
+
*
|
|
3878
|
+
* Changes to the returned values do not update this object. Modify the copies,
|
|
3879
|
+
* then assign the array back to `cookies`.
|
|
3498
3880
|
* @returns {WasmCookieInfo[]}
|
|
3499
3881
|
*/
|
|
3500
3882
|
get cookies() {
|
|
@@ -3503,6 +3885,17 @@ export class WasmCrawlResult {
|
|
|
3503
3885
|
wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
|
|
3504
3886
|
return v1;
|
|
3505
3887
|
}
|
|
3888
|
+
/**
|
|
3889
|
+
* Return an independent handle for an ownership-taking API.
|
|
3890
|
+
*
|
|
3891
|
+
* Use `copyForTransfer()` for each class value placed in an array when the original
|
|
3892
|
+
* handle must remain usable.
|
|
3893
|
+
* @returns {WasmCrawlResult}
|
|
3894
|
+
*/
|
|
3895
|
+
copyForTransfer() {
|
|
3896
|
+
const ret = wasm.wasmcrawlresult_copyForTransfer(this.__wbg_ptr);
|
|
3897
|
+
return WasmCrawlResult.__wrap(ret);
|
|
3898
|
+
}
|
|
3506
3899
|
/**
|
|
3507
3900
|
* @returns {WasmCrawlResult}
|
|
3508
3901
|
*/
|
|
@@ -3538,6 +3931,9 @@ export class WasmCrawlResult {
|
|
|
3538
3931
|
}
|
|
3539
3932
|
}
|
|
3540
3933
|
/**
|
|
3934
|
+
* Takes ownership of every element in `pages`, `cookies`.
|
|
3935
|
+
* wasm-bindgen cannot borrow class values nested in an array. To keep those handles,
|
|
3936
|
+
* copy each retained element with `copyForTransfer()` before passing the array.
|
|
3541
3937
|
* @param {WasmCrawlPageResult[] | null} [pages]
|
|
3542
3938
|
* @param {string | null} [finalUrl]
|
|
3543
3939
|
* @param {number | null} [redirectCount]
|
|
@@ -3562,6 +3958,10 @@ export class WasmCrawlResult {
|
|
|
3562
3958
|
return this;
|
|
3563
3959
|
}
|
|
3564
3960
|
/**
|
|
3961
|
+
* Returns detached copies of the elements in `pages`.
|
|
3962
|
+
*
|
|
3963
|
+
* Changes to the returned values do not update this object. Modify the copies,
|
|
3964
|
+
* then assign the array back to `pages`.
|
|
3565
3965
|
* @returns {WasmCrawlPageResult[]}
|
|
3566
3966
|
*/
|
|
3567
3967
|
get pages() {
|
|
@@ -3584,6 +3984,9 @@ export class WasmCrawlResult {
|
|
|
3584
3984
|
wasm.wasmcrawlresult_set_browserUsed(this.__wbg_ptr, value);
|
|
3585
3985
|
}
|
|
3586
3986
|
/**
|
|
3987
|
+
* Takes ownership of every element in `cookies`.
|
|
3988
|
+
* wasm-bindgen cannot borrow class values nested in an array; copy each retained
|
|
3989
|
+
* element with `copyForTransfer()` before passing the array.
|
|
3587
3990
|
* @param {WasmCookieInfo[]} value
|
|
3588
3991
|
*/
|
|
3589
3992
|
set cookies(value) {
|
|
@@ -3608,6 +4011,9 @@ export class WasmCrawlResult {
|
|
|
3608
4011
|
wasm.wasmcrawlresult_set_finalUrl(this.__wbg_ptr, ptr0, len0);
|
|
3609
4012
|
}
|
|
3610
4013
|
/**
|
|
4014
|
+
* Takes ownership of every element in `pages`.
|
|
4015
|
+
* wasm-bindgen cannot borrow class values nested in an array; copy each retained
|
|
4016
|
+
* element with `copyForTransfer()` before passing the array.
|
|
3611
4017
|
* @param {WasmCrawlPageResult[]} value
|
|
3612
4018
|
*/
|
|
3613
4019
|
set pages(value) {
|
|
@@ -3749,6 +4155,17 @@ export class WasmDownloadedAsset {
|
|
|
3749
4155
|
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
3750
4156
|
}
|
|
3751
4157
|
}
|
|
4158
|
+
/**
|
|
4159
|
+
* Return an independent handle for an ownership-taking API.
|
|
4160
|
+
*
|
|
4161
|
+
* Use `copyForTransfer()` for each class value placed in an array when the original
|
|
4162
|
+
* handle must remain usable.
|
|
4163
|
+
* @returns {WasmDownloadedAsset}
|
|
4164
|
+
*/
|
|
4165
|
+
copyForTransfer() {
|
|
4166
|
+
const ret = wasm.wasmdownloadedasset_copyForTransfer(this.__wbg_ptr);
|
|
4167
|
+
return WasmDownloadedAsset.__wrap(ret);
|
|
4168
|
+
}
|
|
3752
4169
|
/**
|
|
3753
4170
|
* @returns {WasmDownloadedAsset}
|
|
3754
4171
|
*/
|
|
@@ -3934,6 +4351,17 @@ export class WasmDownloadedDocument {
|
|
|
3934
4351
|
}
|
|
3935
4352
|
return v1;
|
|
3936
4353
|
}
|
|
4354
|
+
/**
|
|
4355
|
+
* Return an independent handle for an ownership-taking API.
|
|
4356
|
+
*
|
|
4357
|
+
* Use `copyForTransfer()` for each class value placed in an array when the original
|
|
4358
|
+
* handle must remain usable.
|
|
4359
|
+
* @returns {WasmDownloadedDocument}
|
|
4360
|
+
*/
|
|
4361
|
+
copyForTransfer() {
|
|
4362
|
+
const ret = wasm.wasmdownloadeddocument_copyForTransfer(this.__wbg_ptr);
|
|
4363
|
+
return WasmDownloadedDocument.__wrap(ret);
|
|
4364
|
+
}
|
|
3937
4365
|
/**
|
|
3938
4366
|
* @returns {WasmDownloadedDocument}
|
|
3939
4367
|
*/
|
|
@@ -4136,6 +4564,17 @@ export class WasmExtractionMeta {
|
|
|
4136
4564
|
const ret = wasm.wasmextractionmeta_completionTokens(this.__wbg_ptr);
|
|
4137
4565
|
return ret[0] === 0 ? undefined : BigInt.asUintN(64, ret[1]);
|
|
4138
4566
|
}
|
|
4567
|
+
/**
|
|
4568
|
+
* Return an independent handle for an ownership-taking API.
|
|
4569
|
+
*
|
|
4570
|
+
* Use `copyForTransfer()` for each class value placed in an array when the original
|
|
4571
|
+
* handle must remain usable.
|
|
4572
|
+
* @returns {WasmExtractionMeta}
|
|
4573
|
+
*/
|
|
4574
|
+
copyForTransfer() {
|
|
4575
|
+
const ret = wasm.wasmextractionmeta_copyForTransfer(this.__wbg_ptr);
|
|
4576
|
+
return WasmExtractionMeta.__wrap(ret);
|
|
4577
|
+
}
|
|
4139
4578
|
/**
|
|
4140
4579
|
* @returns {number | undefined}
|
|
4141
4580
|
*/
|
|
@@ -4245,6 +4684,17 @@ export class WasmFaviconInfo {
|
|
|
4245
4684
|
const ptr = this.__destroy_into_raw();
|
|
4246
4685
|
wasm.__wbg_wasmfaviconinfo_free(ptr, 0);
|
|
4247
4686
|
}
|
|
4687
|
+
/**
|
|
4688
|
+
* Return an independent handle for an ownership-taking API.
|
|
4689
|
+
*
|
|
4690
|
+
* Use `copyForTransfer()` for each class value placed in an array when the original
|
|
4691
|
+
* handle must remain usable.
|
|
4692
|
+
* @returns {WasmFaviconInfo}
|
|
4693
|
+
*/
|
|
4694
|
+
copyForTransfer() {
|
|
4695
|
+
const ret = wasm.wasmfaviconinfo_copyForTransfer(this.__wbg_ptr);
|
|
4696
|
+
return WasmFaviconInfo.__wrap(ret);
|
|
4697
|
+
}
|
|
4248
4698
|
/**
|
|
4249
4699
|
* @returns {WasmFaviconInfo}
|
|
4250
4700
|
*/
|
|
@@ -4387,6 +4837,17 @@ export class WasmFeedInfo {
|
|
|
4387
4837
|
const ptr = this.__destroy_into_raw();
|
|
4388
4838
|
wasm.__wbg_wasmfeedinfo_free(ptr, 0);
|
|
4389
4839
|
}
|
|
4840
|
+
/**
|
|
4841
|
+
* Return an independent handle for an ownership-taking API.
|
|
4842
|
+
*
|
|
4843
|
+
* Use `copyForTransfer()` for each class value placed in an array when the original
|
|
4844
|
+
* handle must remain usable.
|
|
4845
|
+
* @returns {WasmFeedInfo}
|
|
4846
|
+
*/
|
|
4847
|
+
copyForTransfer() {
|
|
4848
|
+
const ret = wasm.wasmfeedinfo_copyForTransfer(this.__wbg_ptr);
|
|
4849
|
+
return WasmFeedInfo.__wrap(ret);
|
|
4850
|
+
}
|
|
4390
4851
|
/**
|
|
4391
4852
|
* @returns {WasmFeedInfo}
|
|
4392
4853
|
*/
|
|
@@ -4512,6 +4973,17 @@ export class WasmHeadingInfo {
|
|
|
4512
4973
|
const ptr = this.__destroy_into_raw();
|
|
4513
4974
|
wasm.__wbg_wasmheadinginfo_free(ptr, 0);
|
|
4514
4975
|
}
|
|
4976
|
+
/**
|
|
4977
|
+
* Return an independent handle for an ownership-taking API.
|
|
4978
|
+
*
|
|
4979
|
+
* Use `copyForTransfer()` for each class value placed in an array when the original
|
|
4980
|
+
* handle must remain usable.
|
|
4981
|
+
* @returns {WasmHeadingInfo}
|
|
4982
|
+
*/
|
|
4983
|
+
copyForTransfer() {
|
|
4984
|
+
const ret = wasm.wasmheadinginfo_copyForTransfer(this.__wbg_ptr);
|
|
4985
|
+
return WasmHeadingInfo.__wrap(ret);
|
|
4986
|
+
}
|
|
4515
4987
|
/**
|
|
4516
4988
|
* @returns {WasmHeadingInfo}
|
|
4517
4989
|
*/
|
|
@@ -4689,6 +5161,17 @@ export class WasmHreflangEntry {
|
|
|
4689
5161
|
const ptr = this.__destroy_into_raw();
|
|
4690
5162
|
wasm.__wbg_wasmhreflangentry_free(ptr, 0);
|
|
4691
5163
|
}
|
|
5164
|
+
/**
|
|
5165
|
+
* Return an independent handle for an ownership-taking API.
|
|
5166
|
+
*
|
|
5167
|
+
* Use `copyForTransfer()` for each class value placed in an array when the original
|
|
5168
|
+
* handle must remain usable.
|
|
5169
|
+
* @returns {WasmHreflangEntry}
|
|
5170
|
+
*/
|
|
5171
|
+
copyForTransfer() {
|
|
5172
|
+
const ret = wasm.wasmhreflangentry_copyForTransfer(this.__wbg_ptr);
|
|
5173
|
+
return WasmHreflangEntry.__wrap(ret);
|
|
5174
|
+
}
|
|
4692
5175
|
/**
|
|
4693
5176
|
* @returns {WasmHreflangEntry}
|
|
4694
5177
|
*/
|
|
@@ -4797,6 +5280,17 @@ export class WasmImageInfo {
|
|
|
4797
5280
|
}
|
|
4798
5281
|
return v1;
|
|
4799
5282
|
}
|
|
5283
|
+
/**
|
|
5284
|
+
* Return an independent handle for an ownership-taking API.
|
|
5285
|
+
*
|
|
5286
|
+
* Use `copyForTransfer()` for each class value placed in an array when the original
|
|
5287
|
+
* handle must remain usable.
|
|
5288
|
+
* @returns {WasmImageInfo}
|
|
5289
|
+
*/
|
|
5290
|
+
copyForTransfer() {
|
|
5291
|
+
const ret = wasm.wasmimageinfo_copyForTransfer(this.__wbg_ptr);
|
|
5292
|
+
return WasmImageInfo.__wrap(ret);
|
|
5293
|
+
}
|
|
4800
5294
|
/**
|
|
4801
5295
|
* @returns {WasmImageInfo}
|
|
4802
5296
|
*/
|
|
@@ -4934,6 +5428,10 @@ export class WasmInteractionResult {
|
|
|
4934
5428
|
wasm.__wbg_wasminteractionresult_free(ptr, 0);
|
|
4935
5429
|
}
|
|
4936
5430
|
/**
|
|
5431
|
+
* Returns detached copies of the elements in `actionResults`.
|
|
5432
|
+
*
|
|
5433
|
+
* Changes to the returned values do not update this object. Modify the copies,
|
|
5434
|
+
* then assign the array back to `actionResults`.
|
|
4937
5435
|
* @returns {WasmActionResult[]}
|
|
4938
5436
|
*/
|
|
4939
5437
|
get actionResults() {
|
|
@@ -4942,6 +5440,17 @@ export class WasmInteractionResult {
|
|
|
4942
5440
|
wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
|
|
4943
5441
|
return v1;
|
|
4944
5442
|
}
|
|
5443
|
+
/**
|
|
5444
|
+
* Return an independent handle for an ownership-taking API.
|
|
5445
|
+
*
|
|
5446
|
+
* Use `copyForTransfer()` for each class value placed in an array when the original
|
|
5447
|
+
* handle must remain usable.
|
|
5448
|
+
* @returns {WasmInteractionResult}
|
|
5449
|
+
*/
|
|
5450
|
+
copyForTransfer() {
|
|
5451
|
+
const ret = wasm.wasminteractionresult_copyForTransfer(this.__wbg_ptr);
|
|
5452
|
+
return WasmInteractionResult.__wrap(ret);
|
|
5453
|
+
}
|
|
4945
5454
|
/**
|
|
4946
5455
|
* @returns {WasmInteractionResult}
|
|
4947
5456
|
*/
|
|
@@ -4980,21 +5489,27 @@ export class WasmInteractionResult {
|
|
|
4980
5489
|
}
|
|
4981
5490
|
}
|
|
4982
5491
|
/**
|
|
5492
|
+
* Takes ownership of every element in `actionResults`.
|
|
5493
|
+
* wasm-bindgen cannot borrow class values nested in an array. To keep those handles,
|
|
5494
|
+
* copy each retained element with `copyForTransfer()` before passing the array.
|
|
4983
5495
|
* @param {WasmActionResult[] | null} [actionResults]
|
|
4984
5496
|
* @param {string | null} [finalHtml]
|
|
4985
5497
|
* @param {string | null} [finalUrl]
|
|
5498
|
+
* @param {string[] | null} [ssrfRefusedUrls]
|
|
4986
5499
|
* @param {string | null} [screenshotBase64]
|
|
4987
5500
|
*/
|
|
4988
|
-
constructor(actionResults, finalHtml, finalUrl, screenshotBase64) {
|
|
5501
|
+
constructor(actionResults, finalHtml, finalUrl, ssrfRefusedUrls, screenshotBase64) {
|
|
4989
5502
|
var ptr0 = isLikeNone(actionResults) ? 0 : passArrayJsValueToWasm0(actionResults, wasm.__wbindgen_malloc);
|
|
4990
5503
|
var len0 = WASM_VECTOR_LEN;
|
|
4991
5504
|
var ptr1 = isLikeNone(finalHtml) ? 0 : passStringToWasm0(finalHtml, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
4992
5505
|
var len1 = WASM_VECTOR_LEN;
|
|
4993
5506
|
var ptr2 = isLikeNone(finalUrl) ? 0 : passStringToWasm0(finalUrl, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
4994
5507
|
var len2 = WASM_VECTOR_LEN;
|
|
4995
|
-
var ptr3 = isLikeNone(
|
|
5508
|
+
var ptr3 = isLikeNone(ssrfRefusedUrls) ? 0 : passArrayJsValueToWasm0(ssrfRefusedUrls, wasm.__wbindgen_malloc);
|
|
4996
5509
|
var len3 = WASM_VECTOR_LEN;
|
|
4997
|
-
|
|
5510
|
+
var ptr4 = isLikeNone(screenshotBase64) ? 0 : passStringToWasm0(screenshotBase64, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
5511
|
+
var len4 = WASM_VECTOR_LEN;
|
|
5512
|
+
const ret = wasm.wasminteractionresult_new(ptr0, len0, ptr1, len1, ptr2, len2, ptr3, len3, ptr4, len4);
|
|
4998
5513
|
this.__wbg_ptr = ret;
|
|
4999
5514
|
WasmInteractionResultFinalization.register(this, this.__wbg_ptr, this);
|
|
5000
5515
|
return this;
|
|
@@ -5012,6 +5527,9 @@ export class WasmInteractionResult {
|
|
|
5012
5527
|
return v1;
|
|
5013
5528
|
}
|
|
5014
5529
|
/**
|
|
5530
|
+
* Takes ownership of every element in `actionResults`.
|
|
5531
|
+
* wasm-bindgen cannot borrow class values nested in an array; copy each retained
|
|
5532
|
+
* element with `copyForTransfer()` before passing the array.
|
|
5015
5533
|
* @param {WasmActionResult[]} value
|
|
5016
5534
|
*/
|
|
5017
5535
|
set actionResults(value) {
|
|
@@ -5043,6 +5561,23 @@ export class WasmInteractionResult {
|
|
|
5043
5561
|
var len0 = WASM_VECTOR_LEN;
|
|
5044
5562
|
wasm.wasminteractionresult_set_screenshotBase64(this.__wbg_ptr, ptr0, len0);
|
|
5045
5563
|
}
|
|
5564
|
+
/**
|
|
5565
|
+
* @param {string[]} value
|
|
5566
|
+
*/
|
|
5567
|
+
set ssrfRefusedUrls(value) {
|
|
5568
|
+
const ptr0 = passArrayJsValueToWasm0(value, wasm.__wbindgen_malloc);
|
|
5569
|
+
const len0 = WASM_VECTOR_LEN;
|
|
5570
|
+
wasm.wasminteractionresult_set_ssrfRefusedUrls(this.__wbg_ptr, ptr0, len0);
|
|
5571
|
+
}
|
|
5572
|
+
/**
|
|
5573
|
+
* @returns {string[]}
|
|
5574
|
+
*/
|
|
5575
|
+
get ssrfRefusedUrls() {
|
|
5576
|
+
const ret = wasm.wasminteractionresult_ssrfRefusedUrls(this.__wbg_ptr);
|
|
5577
|
+
var v1 = getArrayJsValueFromWasm0(ret[0], ret[1]);
|
|
5578
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
|
|
5579
|
+
return v1;
|
|
5580
|
+
}
|
|
5046
5581
|
}
|
|
5047
5582
|
if (Symbol.dispose) WasmInteractionResult.prototype[Symbol.dispose] = WasmInteractionResult.prototype.free;
|
|
5048
5583
|
|
|
@@ -5072,6 +5607,17 @@ export class WasmJsonLdEntry {
|
|
|
5072
5607
|
const ptr = this.__destroy_into_raw();
|
|
5073
5608
|
wasm.__wbg_wasmjsonldentry_free(ptr, 0);
|
|
5074
5609
|
}
|
|
5610
|
+
/**
|
|
5611
|
+
* Return an independent handle for an ownership-taking API.
|
|
5612
|
+
*
|
|
5613
|
+
* Use `copyForTransfer()` for each class value placed in an array when the original
|
|
5614
|
+
* handle must remain usable.
|
|
5615
|
+
* @returns {WasmJsonLdEntry}
|
|
5616
|
+
*/
|
|
5617
|
+
copyForTransfer() {
|
|
5618
|
+
const ret = wasm.wasmjsonldentry_copyForTransfer(this.__wbg_ptr);
|
|
5619
|
+
return WasmJsonLdEntry.__wrap(ret);
|
|
5620
|
+
}
|
|
5075
5621
|
/**
|
|
5076
5622
|
* @returns {WasmJsonLdEntry}
|
|
5077
5623
|
*/
|
|
@@ -5191,6 +5737,17 @@ export class WasmLinkInfo {
|
|
|
5191
5737
|
const ptr = this.__destroy_into_raw();
|
|
5192
5738
|
wasm.__wbg_wasmlinkinfo_free(ptr, 0);
|
|
5193
5739
|
}
|
|
5740
|
+
/**
|
|
5741
|
+
* Return an independent handle for an ownership-taking API.
|
|
5742
|
+
*
|
|
5743
|
+
* Use `copyForTransfer()` for each class value placed in an array when the original
|
|
5744
|
+
* handle must remain usable.
|
|
5745
|
+
* @returns {WasmLinkInfo}
|
|
5746
|
+
*/
|
|
5747
|
+
copyForTransfer() {
|
|
5748
|
+
const ret = wasm.wasmlinkinfo_copyForTransfer(this.__wbg_ptr);
|
|
5749
|
+
return WasmLinkInfo.__wrap(ret);
|
|
5750
|
+
}
|
|
5194
5751
|
/**
|
|
5195
5752
|
* @returns {WasmLinkInfo}
|
|
5196
5753
|
*/
|
|
@@ -5351,6 +5908,17 @@ export class WasmMapResult {
|
|
|
5351
5908
|
const ptr = this.__destroy_into_raw();
|
|
5352
5909
|
wasm.__wbg_wasmmapresult_free(ptr, 0);
|
|
5353
5910
|
}
|
|
5911
|
+
/**
|
|
5912
|
+
* Return an independent handle for an ownership-taking API.
|
|
5913
|
+
*
|
|
5914
|
+
* Use `copyForTransfer()` for each class value placed in an array when the original
|
|
5915
|
+
* handle must remain usable.
|
|
5916
|
+
* @returns {WasmMapResult}
|
|
5917
|
+
*/
|
|
5918
|
+
copyForTransfer() {
|
|
5919
|
+
const ret = wasm.wasmmapresult_copyForTransfer(this.__wbg_ptr);
|
|
5920
|
+
return WasmMapResult.__wrap(ret);
|
|
5921
|
+
}
|
|
5354
5922
|
/**
|
|
5355
5923
|
* @returns {WasmMapResult}
|
|
5356
5924
|
*/
|
|
@@ -5359,6 +5927,9 @@ export class WasmMapResult {
|
|
|
5359
5927
|
return WasmMapResult.__wrap(ret);
|
|
5360
5928
|
}
|
|
5361
5929
|
/**
|
|
5930
|
+
* Takes ownership of every element in `urls`.
|
|
5931
|
+
* wasm-bindgen cannot borrow class values nested in an array. To keep those handles,
|
|
5932
|
+
* copy each retained element with `copyForTransfer()` before passing the array.
|
|
5362
5933
|
* @param {WasmSitemapUrl[] | null} [urls]
|
|
5363
5934
|
*/
|
|
5364
5935
|
constructor(urls) {
|
|
@@ -5370,6 +5941,9 @@ export class WasmMapResult {
|
|
|
5370
5941
|
return this;
|
|
5371
5942
|
}
|
|
5372
5943
|
/**
|
|
5944
|
+
* Takes ownership of every element in `urls`.
|
|
5945
|
+
* wasm-bindgen cannot borrow class values nested in an array; copy each retained
|
|
5946
|
+
* element with `copyForTransfer()` before passing the array.
|
|
5373
5947
|
* @param {WasmSitemapUrl[]} value
|
|
5374
5948
|
*/
|
|
5375
5949
|
set urls(value) {
|
|
@@ -5378,6 +5952,10 @@ export class WasmMapResult {
|
|
|
5378
5952
|
wasm.wasmmapresult_set_urls(this.__wbg_ptr, ptr0, len0);
|
|
5379
5953
|
}
|
|
5380
5954
|
/**
|
|
5955
|
+
* Returns detached copies of the elements in `urls`.
|
|
5956
|
+
*
|
|
5957
|
+
* Changes to the returned values do not update this object. Modify the copies,
|
|
5958
|
+
* then assign the array back to `urls`.
|
|
5381
5959
|
* @returns {WasmSitemapUrl[]}
|
|
5382
5960
|
*/
|
|
5383
5961
|
get urls() {
|
|
@@ -5431,6 +6009,17 @@ export class WasmMarkdownResult {
|
|
|
5431
6009
|
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
5432
6010
|
}
|
|
5433
6011
|
}
|
|
6012
|
+
/**
|
|
6013
|
+
* Return an independent handle for an ownership-taking API.
|
|
6014
|
+
*
|
|
6015
|
+
* Use `copyForTransfer()` for each class value placed in an array when the original
|
|
6016
|
+
* handle must remain usable.
|
|
6017
|
+
* @returns {WasmMarkdownResult}
|
|
6018
|
+
*/
|
|
6019
|
+
copyForTransfer() {
|
|
6020
|
+
const ret = wasm.wasmmarkdownresult_copyForTransfer(this.__wbg_ptr);
|
|
6021
|
+
return WasmMarkdownResult.__wrap(ret);
|
|
6022
|
+
}
|
|
5434
6023
|
/**
|
|
5435
6024
|
* @returns {WasmMarkdownResult}
|
|
5436
6025
|
*/
|
|
@@ -5759,6 +6348,10 @@ export class WasmPageMetadata {
|
|
|
5759
6348
|
wasm.__wbg_wasmpagemetadata_free(ptr, 0);
|
|
5760
6349
|
}
|
|
5761
6350
|
/**
|
|
6351
|
+
* Returns a detached copy of `article`.
|
|
6352
|
+
*
|
|
6353
|
+
* Changes to the returned value do not update this object. To update `article`,
|
|
6354
|
+
* read it, modify the copy, then assign the copy back to `article`.
|
|
5762
6355
|
* @returns {WasmArticleMetadata | undefined}
|
|
5763
6356
|
*/
|
|
5764
6357
|
get article() {
|
|
@@ -5789,6 +6382,20 @@ export class WasmPageMetadata {
|
|
|
5789
6382
|
}
|
|
5790
6383
|
return v1;
|
|
5791
6384
|
}
|
|
6385
|
+
clearArticle() {
|
|
6386
|
+
wasm.wasmpagemetadata_clearArticle(this.__wbg_ptr);
|
|
6387
|
+
}
|
|
6388
|
+
/**
|
|
6389
|
+
* Return an independent handle for an ownership-taking API.
|
|
6390
|
+
*
|
|
6391
|
+
* Use `copyForTransfer()` for each class value placed in an array when the original
|
|
6392
|
+
* handle must remain usable.
|
|
6393
|
+
* @returns {WasmPageMetadata}
|
|
6394
|
+
*/
|
|
6395
|
+
copyForTransfer() {
|
|
6396
|
+
const ret = wasm.wasmpagemetadata_copyForTransfer(this.__wbg_ptr);
|
|
6397
|
+
return WasmPageMetadata.__wrap(ret);
|
|
6398
|
+
}
|
|
5792
6399
|
/**
|
|
5793
6400
|
* @returns {string | undefined}
|
|
5794
6401
|
*/
|
|
@@ -5941,6 +6548,10 @@ export class WasmPageMetadata {
|
|
|
5941
6548
|
return v1;
|
|
5942
6549
|
}
|
|
5943
6550
|
/**
|
|
6551
|
+
* Returns detached copies of the elements in `favicons`.
|
|
6552
|
+
*
|
|
6553
|
+
* Changes to the returned values do not update this object. Modify the copies,
|
|
6554
|
+
* then assign the array back to `favicons`.
|
|
5944
6555
|
* @returns {Array<any> | undefined}
|
|
5945
6556
|
*/
|
|
5946
6557
|
get favicons() {
|
|
@@ -5960,6 +6571,10 @@ export class WasmPageMetadata {
|
|
|
5960
6571
|
return v1;
|
|
5961
6572
|
}
|
|
5962
6573
|
/**
|
|
6574
|
+
* Returns detached copies of the elements in `headings`.
|
|
6575
|
+
*
|
|
6576
|
+
* Changes to the returned values do not update this object. Modify the copies,
|
|
6577
|
+
* then assign the array back to `headings`.
|
|
5963
6578
|
* @returns {Array<any> | undefined}
|
|
5964
6579
|
*/
|
|
5965
6580
|
get headings() {
|
|
@@ -5967,6 +6582,10 @@ export class WasmPageMetadata {
|
|
|
5967
6582
|
return ret;
|
|
5968
6583
|
}
|
|
5969
6584
|
/**
|
|
6585
|
+
* Returns detached copies of the elements in `hreflangs`.
|
|
6586
|
+
*
|
|
6587
|
+
* Changes to the returned values do not update this object. Modify the copies,
|
|
6588
|
+
* then assign the array back to `hreflangs`.
|
|
5970
6589
|
* @returns {Array<any> | undefined}
|
|
5971
6590
|
*/
|
|
5972
6591
|
get hreflangs() {
|
|
@@ -6010,6 +6629,14 @@ export class WasmPageMetadata {
|
|
|
6010
6629
|
return v1;
|
|
6011
6630
|
}
|
|
6012
6631
|
/**
|
|
6632
|
+
* Takes ownership of `article`.
|
|
6633
|
+
* wasm-bindgen lowers a by-value class argument through `__destroy_into_raw()`, so each
|
|
6634
|
+
* of those handles is dead once this returns. Passing a freshly built value is fine. To
|
|
6635
|
+
* keep a handle you already hold, build with `default()` and assign the property instead:
|
|
6636
|
+
* the generated setter borrows and leaves your handle alive.
|
|
6637
|
+
* Takes ownership of every element in `hreflangs`, `favicons`, `headings`.
|
|
6638
|
+
* wasm-bindgen cannot borrow class values nested in an array. To keep those handles,
|
|
6639
|
+
* copy each retained element with `copyForTransfer()` before passing the array.
|
|
6013
6640
|
* @param {string | null} [title]
|
|
6014
6641
|
* @param {string | null} [description]
|
|
6015
6642
|
* @param {string | null} [canonicalUrl]
|
|
@@ -6280,15 +6907,11 @@ export class WasmPageMetadata {
|
|
|
6280
6907
|
return v1;
|
|
6281
6908
|
}
|
|
6282
6909
|
/**
|
|
6283
|
-
* @param {WasmArticleMetadata
|
|
6910
|
+
* @param {WasmArticleMetadata} value
|
|
6284
6911
|
*/
|
|
6285
6912
|
set article(value) {
|
|
6286
|
-
|
|
6287
|
-
|
|
6288
|
-
_assertClass(value, WasmArticleMetadata);
|
|
6289
|
-
ptr0 = value.__destroy_into_raw();
|
|
6290
|
-
}
|
|
6291
|
-
wasm.wasmpagemetadata_set_article(this.__wbg_ptr, ptr0);
|
|
6913
|
+
_assertClass(value, WasmArticleMetadata);
|
|
6914
|
+
wasm.wasmpagemetadata_set_article(this.__wbg_ptr, value.__wbg_ptr);
|
|
6292
6915
|
}
|
|
6293
6916
|
/**
|
|
6294
6917
|
* @param {string | null} [value]
|
|
@@ -6403,6 +7026,9 @@ export class WasmPageMetadata {
|
|
|
6403
7026
|
wasm.wasmpagemetadata_set_description(this.__wbg_ptr, ptr0, len0);
|
|
6404
7027
|
}
|
|
6405
7028
|
/**
|
|
7029
|
+
* Takes ownership of every element in `favicons`.
|
|
7030
|
+
* wasm-bindgen cannot borrow class values nested in an array; copy each retained
|
|
7031
|
+
* element with `copyForTransfer()` before passing the array.
|
|
6406
7032
|
* @param {WasmFaviconInfo[] | null} [value]
|
|
6407
7033
|
*/
|
|
6408
7034
|
set favicons(value) {
|
|
@@ -6419,6 +7045,9 @@ export class WasmPageMetadata {
|
|
|
6419
7045
|
wasm.wasmpagemetadata_set_generator(this.__wbg_ptr, ptr0, len0);
|
|
6420
7046
|
}
|
|
6421
7047
|
/**
|
|
7048
|
+
* Takes ownership of every element in `headings`.
|
|
7049
|
+
* wasm-bindgen cannot borrow class values nested in an array; copy each retained
|
|
7050
|
+
* element with `copyForTransfer()` before passing the array.
|
|
6422
7051
|
* @param {WasmHeadingInfo[] | null} [value]
|
|
6423
7052
|
*/
|
|
6424
7053
|
set headings(value) {
|
|
@@ -6427,6 +7056,9 @@ export class WasmPageMetadata {
|
|
|
6427
7056
|
wasm.wasmpagemetadata_set_headings(this.__wbg_ptr, ptr0, len0);
|
|
6428
7057
|
}
|
|
6429
7058
|
/**
|
|
7059
|
+
* Takes ownership of every element in `hreflangs`.
|
|
7060
|
+
* wasm-bindgen cannot borrow class values nested in an array; copy each retained
|
|
7061
|
+
* element with `copyForTransfer()` before passing the array.
|
|
6430
7062
|
* @param {WasmHreflangEntry[] | null} [value]
|
|
6431
7063
|
*/
|
|
6432
7064
|
set hreflangs(value) {
|
|
@@ -6762,6 +7394,17 @@ export class WasmProxyConfig {
|
|
|
6762
7394
|
const ptr = this.__destroy_into_raw();
|
|
6763
7395
|
wasm.__wbg_wasmproxyconfig_free(ptr, 0);
|
|
6764
7396
|
}
|
|
7397
|
+
/**
|
|
7398
|
+
* Return an independent handle for an ownership-taking API.
|
|
7399
|
+
*
|
|
7400
|
+
* Use `copyForTransfer()` for each class value placed in an array when the original
|
|
7401
|
+
* handle must remain usable.
|
|
7402
|
+
* @returns {WasmProxyConfig}
|
|
7403
|
+
*/
|
|
7404
|
+
copyForTransfer() {
|
|
7405
|
+
const ret = wasm.wasmproxyconfig_copyForTransfer(this.__wbg_ptr);
|
|
7406
|
+
return WasmProxyConfig.__wrap(ret);
|
|
7407
|
+
}
|
|
6765
7408
|
/**
|
|
6766
7409
|
* @returns {WasmProxyConfig}
|
|
6767
7410
|
*/
|
|
@@ -6914,6 +7557,17 @@ export class WasmResponseMeta {
|
|
|
6914
7557
|
}
|
|
6915
7558
|
return v1;
|
|
6916
7559
|
}
|
|
7560
|
+
/**
|
|
7561
|
+
* Return an independent handle for an ownership-taking API.
|
|
7562
|
+
*
|
|
7563
|
+
* Use `copyForTransfer()` for each class value placed in an array when the original
|
|
7564
|
+
* handle must remain usable.
|
|
7565
|
+
* @returns {WasmResponseMeta}
|
|
7566
|
+
*/
|
|
7567
|
+
copyForTransfer() {
|
|
7568
|
+
const ret = wasm.wasmresponsemeta_copyForTransfer(this.__wbg_ptr);
|
|
7569
|
+
return WasmResponseMeta.__wrap(ret);
|
|
7570
|
+
}
|
|
6917
7571
|
/**
|
|
6918
7572
|
* @returns {WasmResponseMeta}
|
|
6919
7573
|
*/
|
|
@@ -7078,6 +7732,10 @@ export class WasmScrapeResult {
|
|
|
7078
7732
|
wasm.__wbg_wasmscraperesult_free(ptr, 0);
|
|
7079
7733
|
}
|
|
7080
7734
|
/**
|
|
7735
|
+
* Returns detached copies of the elements in `assets`.
|
|
7736
|
+
*
|
|
7737
|
+
* Changes to the returned values do not update this object. Modify the copies,
|
|
7738
|
+
* then assign the array back to `assets`.
|
|
7081
7739
|
* @returns {WasmDownloadedAsset[]}
|
|
7082
7740
|
*/
|
|
7083
7741
|
get assets() {
|
|
@@ -7108,12 +7766,31 @@ export class WasmScrapeResult {
|
|
|
7108
7766
|
return ret !== 0;
|
|
7109
7767
|
}
|
|
7110
7768
|
/**
|
|
7769
|
+
* Returns a detached copy of `browser`.
|
|
7770
|
+
*
|
|
7771
|
+
* Changes to the returned value do not update this object. To update `browser`,
|
|
7772
|
+
* read it, modify the copy, then assign the copy back to `browser`.
|
|
7111
7773
|
* @returns {WasmBrowserExtras | undefined}
|
|
7112
7774
|
*/
|
|
7113
7775
|
get browser() {
|
|
7114
7776
|
const ret = wasm.wasmscraperesult_browser(this.__wbg_ptr);
|
|
7115
7777
|
return ret === 0 ? undefined : WasmBrowserExtras.__wrap(ret);
|
|
7116
7778
|
}
|
|
7779
|
+
clearBrowser() {
|
|
7780
|
+
wasm.wasmscraperesult_clearBrowser(this.__wbg_ptr);
|
|
7781
|
+
}
|
|
7782
|
+
clearDownloadedDocument() {
|
|
7783
|
+
wasm.wasmscraperesult_clearDownloadedDocument(this.__wbg_ptr);
|
|
7784
|
+
}
|
|
7785
|
+
clearExtractionMeta() {
|
|
7786
|
+
wasm.wasmscraperesult_clearExtractionMeta(this.__wbg_ptr);
|
|
7787
|
+
}
|
|
7788
|
+
clearMarkdown() {
|
|
7789
|
+
wasm.wasmscraperesult_clearMarkdown(this.__wbg_ptr);
|
|
7790
|
+
}
|
|
7791
|
+
clearResponseMeta() {
|
|
7792
|
+
wasm.wasmscraperesult_clearResponseMeta(this.__wbg_ptr);
|
|
7793
|
+
}
|
|
7117
7794
|
/**
|
|
7118
7795
|
* @returns {string}
|
|
7119
7796
|
*/
|
|
@@ -7129,6 +7806,17 @@ export class WasmScrapeResult {
|
|
|
7129
7806
|
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
7130
7807
|
}
|
|
7131
7808
|
}
|
|
7809
|
+
/**
|
|
7810
|
+
* Return an independent handle for an ownership-taking API.
|
|
7811
|
+
*
|
|
7812
|
+
* Use `copyForTransfer()` for each class value placed in an array when the original
|
|
7813
|
+
* handle must remain usable.
|
|
7814
|
+
* @returns {WasmScrapeResult}
|
|
7815
|
+
*/
|
|
7816
|
+
copyForTransfer() {
|
|
7817
|
+
const ret = wasm.wasmscraperesult_copyForTransfer(this.__wbg_ptr);
|
|
7818
|
+
return WasmScrapeResult.__wrap(ret);
|
|
7819
|
+
}
|
|
7132
7820
|
/**
|
|
7133
7821
|
* @returns {bigint | undefined}
|
|
7134
7822
|
*/
|
|
@@ -7156,6 +7844,10 @@ export class WasmScrapeResult {
|
|
|
7156
7844
|
return v1;
|
|
7157
7845
|
}
|
|
7158
7846
|
/**
|
|
7847
|
+
* Returns a detached copy of `downloadedDocument`.
|
|
7848
|
+
*
|
|
7849
|
+
* Changes to the returned value do not update this object. To update `downloadedDocument`,
|
|
7850
|
+
* read it, modify the copy, then assign the copy back to `downloadedDocument`.
|
|
7159
7851
|
* @returns {WasmDownloadedDocument | undefined}
|
|
7160
7852
|
*/
|
|
7161
7853
|
get downloadedDocument() {
|
|
@@ -7170,6 +7862,10 @@ export class WasmScrapeResult {
|
|
|
7170
7862
|
return ret;
|
|
7171
7863
|
}
|
|
7172
7864
|
/**
|
|
7865
|
+
* Returns a detached copy of `extractionMeta`.
|
|
7866
|
+
*
|
|
7867
|
+
* Changes to the returned value do not update this object. To update `extractionMeta`,
|
|
7868
|
+
* read it, modify the copy, then assign the copy back to `extractionMeta`.
|
|
7173
7869
|
* @returns {WasmExtractionMeta | undefined}
|
|
7174
7870
|
*/
|
|
7175
7871
|
get extractionMeta() {
|
|
@@ -7177,6 +7873,10 @@ export class WasmScrapeResult {
|
|
|
7177
7873
|
return ret === 0 ? undefined : WasmExtractionMeta.__wrap(ret);
|
|
7178
7874
|
}
|
|
7179
7875
|
/**
|
|
7876
|
+
* Returns detached copies of the elements in `feeds`.
|
|
7877
|
+
*
|
|
7878
|
+
* Changes to the returned values do not update this object. Modify the copies,
|
|
7879
|
+
* then assign the array back to `feeds`.
|
|
7180
7880
|
* @returns {WasmFeedInfo[]}
|
|
7181
7881
|
*/
|
|
7182
7882
|
get feeds() {
|
|
@@ -7216,6 +7916,10 @@ export class WasmScrapeResult {
|
|
|
7216
7916
|
}
|
|
7217
7917
|
}
|
|
7218
7918
|
/**
|
|
7919
|
+
* Returns detached copies of the elements in `images`.
|
|
7920
|
+
*
|
|
7921
|
+
* Changes to the returned values do not update this object. Modify the copies,
|
|
7922
|
+
* then assign the array back to `images`.
|
|
7219
7923
|
* @returns {WasmImageInfo[]}
|
|
7220
7924
|
*/
|
|
7221
7925
|
get images() {
|
|
@@ -7246,6 +7950,10 @@ export class WasmScrapeResult {
|
|
|
7246
7950
|
return ret !== 0;
|
|
7247
7951
|
}
|
|
7248
7952
|
/**
|
|
7953
|
+
* Returns detached copies of the elements in `jsonLd`.
|
|
7954
|
+
*
|
|
7955
|
+
* Changes to the returned values do not update this object. Modify the copies,
|
|
7956
|
+
* then assign the array back to `jsonLd`.
|
|
7249
7957
|
* @returns {WasmJsonLdEntry[]}
|
|
7250
7958
|
*/
|
|
7251
7959
|
get jsonLd() {
|
|
@@ -7255,6 +7963,10 @@ export class WasmScrapeResult {
|
|
|
7255
7963
|
return v1;
|
|
7256
7964
|
}
|
|
7257
7965
|
/**
|
|
7966
|
+
* Returns detached copies of the elements in `links`.
|
|
7967
|
+
*
|
|
7968
|
+
* Changes to the returned values do not update this object. Modify the copies,
|
|
7969
|
+
* then assign the array back to `links`.
|
|
7258
7970
|
* @returns {WasmLinkInfo[]}
|
|
7259
7971
|
*/
|
|
7260
7972
|
get links() {
|
|
@@ -7264,6 +7976,10 @@ export class WasmScrapeResult {
|
|
|
7264
7976
|
return v1;
|
|
7265
7977
|
}
|
|
7266
7978
|
/**
|
|
7979
|
+
* Returns a detached copy of `markdown`.
|
|
7980
|
+
*
|
|
7981
|
+
* Changes to the returned value do not update this object. To update `markdown`,
|
|
7982
|
+
* read it, modify the copy, then assign the copy back to `markdown`.
|
|
7267
7983
|
* @returns {WasmMarkdownResult | undefined}
|
|
7268
7984
|
*/
|
|
7269
7985
|
get markdown() {
|
|
@@ -7271,6 +7987,10 @@ export class WasmScrapeResult {
|
|
|
7271
7987
|
return ret === 0 ? undefined : WasmMarkdownResult.__wrap(ret);
|
|
7272
7988
|
}
|
|
7273
7989
|
/**
|
|
7990
|
+
* Returns a detached copy of `metadata`.
|
|
7991
|
+
*
|
|
7992
|
+
* Changes to the returned value do not update this object. To update `metadata`,
|
|
7993
|
+
* read it, modify the copy, then assign the copy back to `metadata`.
|
|
7274
7994
|
* @returns {WasmPageMetadata}
|
|
7275
7995
|
*/
|
|
7276
7996
|
get metadata() {
|
|
@@ -7278,6 +7998,14 @@ export class WasmScrapeResult {
|
|
|
7278
7998
|
return WasmPageMetadata.__wrap(ret);
|
|
7279
7999
|
}
|
|
7280
8000
|
/**
|
|
8001
|
+
* Takes ownership of `metadata`, `responseMeta`, `markdown`, `extractionMeta`, `downloadedDocument`, `browser`.
|
|
8002
|
+
* wasm-bindgen lowers a by-value class argument through `__destroy_into_raw()`, so each
|
|
8003
|
+
* of those handles is dead once this returns. Passing a freshly built value is fine. To
|
|
8004
|
+
* keep a handle you already hold, build with `default()` and assign the property instead:
|
|
8005
|
+
* the generated setter borrows and leaves your handle alive.
|
|
8006
|
+
* Takes ownership of every element in `links`, `images`, `feeds`, `jsonLd`, `assets`.
|
|
8007
|
+
* wasm-bindgen cannot borrow class values nested in an array. To keep those handles,
|
|
8008
|
+
* copy each retained element with `copyForTransfer()` before passing the array.
|
|
7281
8009
|
* @param {number | null} [statusCode]
|
|
7282
8010
|
* @param {string | null} [finalUrl]
|
|
7283
8011
|
* @param {string | null} [contentType]
|
|
@@ -7297,6 +8025,7 @@ export class WasmScrapeResult {
|
|
|
7297
8025
|
* @param {WasmDownloadedAsset[] | null} [assets]
|
|
7298
8026
|
* @param {boolean | null} [jsRenderHint]
|
|
7299
8027
|
* @param {boolean | null} [browserUsed]
|
|
8028
|
+
* @param {string[] | null} [ssrfRefusedUrls]
|
|
7300
8029
|
* @param {bigint | null} [crawlDelay]
|
|
7301
8030
|
* @param {string | null} [xRobotsTag]
|
|
7302
8031
|
* @param {string | null} [detectedCharset]
|
|
@@ -7308,7 +8037,7 @@ export class WasmScrapeResult {
|
|
|
7308
8037
|
* @param {WasmDownloadedDocument | null} [downloadedDocument]
|
|
7309
8038
|
* @param {WasmBrowserExtras | null} [browser]
|
|
7310
8039
|
*/
|
|
7311
|
-
constructor(statusCode, finalUrl, contentType, html, bodySize, metadata, links, images, feeds, jsonLd, isAllowed, noindexDetected, nofollowDetected, isPdf, wasSkipped, authHeaderSent, assets, jsRenderHint, browserUsed, crawlDelay, xRobotsTag, detectedCharset, responseMeta, markdown, extractedData, extractionMeta, screenshotBase64, downloadedDocument, browser) {
|
|
8040
|
+
constructor(statusCode, finalUrl, contentType, html, bodySize, metadata, links, images, feeds, jsonLd, isAllowed, noindexDetected, nofollowDetected, isPdf, wasSkipped, authHeaderSent, assets, jsRenderHint, browserUsed, ssrfRefusedUrls, crawlDelay, xRobotsTag, detectedCharset, responseMeta, markdown, extractedData, extractionMeta, screenshotBase64, downloadedDocument, browser) {
|
|
7312
8041
|
var ptr0 = isLikeNone(finalUrl) ? 0 : passStringToWasm0(finalUrl, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
7313
8042
|
var len0 = WASM_VECTOR_LEN;
|
|
7314
8043
|
var ptr1 = isLikeNone(contentType) ? 0 : passStringToWasm0(contentType, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
@@ -7330,38 +8059,40 @@ export class WasmScrapeResult {
|
|
|
7330
8059
|
var len7 = WASM_VECTOR_LEN;
|
|
7331
8060
|
var ptr8 = isLikeNone(assets) ? 0 : passArrayJsValueToWasm0(assets, wasm.__wbindgen_malloc);
|
|
7332
8061
|
var len8 = WASM_VECTOR_LEN;
|
|
7333
|
-
var ptr9 = isLikeNone(
|
|
8062
|
+
var ptr9 = isLikeNone(ssrfRefusedUrls) ? 0 : passArrayJsValueToWasm0(ssrfRefusedUrls, wasm.__wbindgen_malloc);
|
|
7334
8063
|
var len9 = WASM_VECTOR_LEN;
|
|
7335
|
-
var ptr10 = isLikeNone(
|
|
8064
|
+
var ptr10 = isLikeNone(xRobotsTag) ? 0 : passStringToWasm0(xRobotsTag, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
7336
8065
|
var len10 = WASM_VECTOR_LEN;
|
|
7337
|
-
|
|
8066
|
+
var ptr11 = isLikeNone(detectedCharset) ? 0 : passStringToWasm0(detectedCharset, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
8067
|
+
var len11 = WASM_VECTOR_LEN;
|
|
8068
|
+
let ptr12 = 0;
|
|
7338
8069
|
if (!isLikeNone(responseMeta)) {
|
|
7339
8070
|
_assertClass(responseMeta, WasmResponseMeta);
|
|
7340
|
-
|
|
8071
|
+
ptr12 = responseMeta.__destroy_into_raw();
|
|
7341
8072
|
}
|
|
7342
|
-
let
|
|
8073
|
+
let ptr13 = 0;
|
|
7343
8074
|
if (!isLikeNone(markdown)) {
|
|
7344
8075
|
_assertClass(markdown, WasmMarkdownResult);
|
|
7345
|
-
|
|
8076
|
+
ptr13 = markdown.__destroy_into_raw();
|
|
7346
8077
|
}
|
|
7347
|
-
let
|
|
8078
|
+
let ptr14 = 0;
|
|
7348
8079
|
if (!isLikeNone(extractionMeta)) {
|
|
7349
8080
|
_assertClass(extractionMeta, WasmExtractionMeta);
|
|
7350
|
-
|
|
8081
|
+
ptr14 = extractionMeta.__destroy_into_raw();
|
|
7351
8082
|
}
|
|
7352
|
-
var
|
|
7353
|
-
var
|
|
7354
|
-
let
|
|
8083
|
+
var ptr15 = isLikeNone(screenshotBase64) ? 0 : passStringToWasm0(screenshotBase64, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
8084
|
+
var len15 = WASM_VECTOR_LEN;
|
|
8085
|
+
let ptr16 = 0;
|
|
7355
8086
|
if (!isLikeNone(downloadedDocument)) {
|
|
7356
8087
|
_assertClass(downloadedDocument, WasmDownloadedDocument);
|
|
7357
|
-
|
|
8088
|
+
ptr16 = downloadedDocument.__destroy_into_raw();
|
|
7358
8089
|
}
|
|
7359
|
-
let
|
|
8090
|
+
let ptr17 = 0;
|
|
7360
8091
|
if (!isLikeNone(browser)) {
|
|
7361
8092
|
_assertClass(browser, WasmBrowserExtras);
|
|
7362
|
-
|
|
8093
|
+
ptr17 = browser.__destroy_into_raw();
|
|
7363
8094
|
}
|
|
7364
|
-
const ret = wasm.wasmscraperesult_new(isLikeNone(statusCode) ? 0xFFFFFF : statusCode, ptr0, len0, ptr1, len1, ptr2, len2, isLikeNone(bodySize) ? Number.MAX_SAFE_INTEGER : (bodySize) >>> 0, ptr3, ptr4, len4, ptr5, len5, ptr6, len6, ptr7, len7, isLikeNone(isAllowed) ? 0xFFFFFF : isAllowed ? 1 : 0, isLikeNone(noindexDetected) ? 0xFFFFFF : noindexDetected ? 1 : 0, isLikeNone(nofollowDetected) ? 0xFFFFFF : nofollowDetected ? 1 : 0, isLikeNone(isPdf) ? 0xFFFFFF : isPdf ? 1 : 0, isLikeNone(wasSkipped) ? 0xFFFFFF : wasSkipped ? 1 : 0, isLikeNone(authHeaderSent) ? 0xFFFFFF : authHeaderSent ? 1 : 0, ptr8, len8, isLikeNone(jsRenderHint) ? 0xFFFFFF : jsRenderHint ? 1 : 0, isLikeNone(browserUsed) ? 0xFFFFFF : browserUsed ? 1 : 0, !isLikeNone(crawlDelay), isLikeNone(crawlDelay) ? BigInt(0) : crawlDelay,
|
|
8095
|
+
const ret = wasm.wasmscraperesult_new(isLikeNone(statusCode) ? 0xFFFFFF : statusCode, ptr0, len0, ptr1, len1, ptr2, len2, isLikeNone(bodySize) ? Number.MAX_SAFE_INTEGER : (bodySize) >>> 0, ptr3, ptr4, len4, ptr5, len5, ptr6, len6, ptr7, len7, isLikeNone(isAllowed) ? 0xFFFFFF : isAllowed ? 1 : 0, isLikeNone(noindexDetected) ? 0xFFFFFF : noindexDetected ? 1 : 0, isLikeNone(nofollowDetected) ? 0xFFFFFF : nofollowDetected ? 1 : 0, isLikeNone(isPdf) ? 0xFFFFFF : isPdf ? 1 : 0, isLikeNone(wasSkipped) ? 0xFFFFFF : wasSkipped ? 1 : 0, isLikeNone(authHeaderSent) ? 0xFFFFFF : authHeaderSent ? 1 : 0, ptr8, len8, isLikeNone(jsRenderHint) ? 0xFFFFFF : jsRenderHint ? 1 : 0, isLikeNone(browserUsed) ? 0xFFFFFF : browserUsed ? 1 : 0, ptr9, len9, !isLikeNone(crawlDelay), isLikeNone(crawlDelay) ? BigInt(0) : crawlDelay, ptr10, len10, ptr11, len11, ptr12, ptr13, isLikeNone(extractedData) ? 0 : addToExternrefTable0(extractedData), ptr14, ptr15, len15, ptr16, ptr17);
|
|
7365
8096
|
this.__wbg_ptr = ret;
|
|
7366
8097
|
WasmScrapeResultFinalization.register(this, this.__wbg_ptr, this);
|
|
7367
8098
|
return this;
|
|
@@ -7381,6 +8112,10 @@ export class WasmScrapeResult {
|
|
|
7381
8112
|
return ret !== 0;
|
|
7382
8113
|
}
|
|
7383
8114
|
/**
|
|
8115
|
+
* Returns a detached copy of `responseMeta`.
|
|
8116
|
+
*
|
|
8117
|
+
* Changes to the returned value do not update this object. To update `responseMeta`,
|
|
8118
|
+
* read it, modify the copy, then assign the copy back to `responseMeta`.
|
|
7384
8119
|
* @returns {WasmResponseMeta | undefined}
|
|
7385
8120
|
*/
|
|
7386
8121
|
get responseMeta() {
|
|
@@ -7400,6 +8135,9 @@ export class WasmScrapeResult {
|
|
|
7400
8135
|
return v1;
|
|
7401
8136
|
}
|
|
7402
8137
|
/**
|
|
8138
|
+
* Takes ownership of every element in `assets`.
|
|
8139
|
+
* wasm-bindgen cannot borrow class values nested in an array; copy each retained
|
|
8140
|
+
* element with `copyForTransfer()` before passing the array.
|
|
7403
8141
|
* @param {WasmDownloadedAsset[]} value
|
|
7404
8142
|
*/
|
|
7405
8143
|
set assets(value) {
|
|
@@ -7426,15 +8164,11 @@ export class WasmScrapeResult {
|
|
|
7426
8164
|
wasm.wasmscraperesult_set_browserUsed(this.__wbg_ptr, value);
|
|
7427
8165
|
}
|
|
7428
8166
|
/**
|
|
7429
|
-
* @param {WasmBrowserExtras
|
|
8167
|
+
* @param {WasmBrowserExtras} value
|
|
7430
8168
|
*/
|
|
7431
8169
|
set browser(value) {
|
|
7432
|
-
|
|
7433
|
-
|
|
7434
|
-
_assertClass(value, WasmBrowserExtras);
|
|
7435
|
-
ptr0 = value.__destroy_into_raw();
|
|
7436
|
-
}
|
|
7437
|
-
wasm.wasmscraperesult_set_browser(this.__wbg_ptr, ptr0);
|
|
8170
|
+
_assertClass(value, WasmBrowserExtras);
|
|
8171
|
+
wasm.wasmscraperesult_set_browser(this.__wbg_ptr, value.__wbg_ptr);
|
|
7438
8172
|
}
|
|
7439
8173
|
/**
|
|
7440
8174
|
* @param {string} value
|
|
@@ -7459,15 +8193,11 @@ export class WasmScrapeResult {
|
|
|
7459
8193
|
wasm.wasmscraperesult_set_detectedCharset(this.__wbg_ptr, ptr0, len0);
|
|
7460
8194
|
}
|
|
7461
8195
|
/**
|
|
7462
|
-
* @param {WasmDownloadedDocument
|
|
8196
|
+
* @param {WasmDownloadedDocument} value
|
|
7463
8197
|
*/
|
|
7464
8198
|
set downloadedDocument(value) {
|
|
7465
|
-
|
|
7466
|
-
|
|
7467
|
-
_assertClass(value, WasmDownloadedDocument);
|
|
7468
|
-
ptr0 = value.__destroy_into_raw();
|
|
7469
|
-
}
|
|
7470
|
-
wasm.wasmscraperesult_set_downloadedDocument(this.__wbg_ptr, ptr0);
|
|
8199
|
+
_assertClass(value, WasmDownloadedDocument);
|
|
8200
|
+
wasm.wasmscraperesult_set_downloadedDocument(this.__wbg_ptr, value.__wbg_ptr);
|
|
7471
8201
|
}
|
|
7472
8202
|
/**
|
|
7473
8203
|
* @param {any | null} [value]
|
|
@@ -7476,17 +8206,16 @@ export class WasmScrapeResult {
|
|
|
7476
8206
|
wasm.wasmscraperesult_set_extractedData(this.__wbg_ptr, isLikeNone(value) ? 0 : addToExternrefTable0(value));
|
|
7477
8207
|
}
|
|
7478
8208
|
/**
|
|
7479
|
-
* @param {WasmExtractionMeta
|
|
8209
|
+
* @param {WasmExtractionMeta} value
|
|
7480
8210
|
*/
|
|
7481
8211
|
set extractionMeta(value) {
|
|
7482
|
-
|
|
7483
|
-
|
|
7484
|
-
_assertClass(value, WasmExtractionMeta);
|
|
7485
|
-
ptr0 = value.__destroy_into_raw();
|
|
7486
|
-
}
|
|
7487
|
-
wasm.wasmscraperesult_set_extractionMeta(this.__wbg_ptr, ptr0);
|
|
8212
|
+
_assertClass(value, WasmExtractionMeta);
|
|
8213
|
+
wasm.wasmscraperesult_set_extractionMeta(this.__wbg_ptr, value.__wbg_ptr);
|
|
7488
8214
|
}
|
|
7489
8215
|
/**
|
|
8216
|
+
* Takes ownership of every element in `feeds`.
|
|
8217
|
+
* wasm-bindgen cannot borrow class values nested in an array; copy each retained
|
|
8218
|
+
* element with `copyForTransfer()` before passing the array.
|
|
7490
8219
|
* @param {WasmFeedInfo[]} value
|
|
7491
8220
|
*/
|
|
7492
8221
|
set feeds(value) {
|
|
@@ -7511,6 +8240,9 @@ export class WasmScrapeResult {
|
|
|
7511
8240
|
wasm.wasmscraperesult_set_html(this.__wbg_ptr, ptr0, len0);
|
|
7512
8241
|
}
|
|
7513
8242
|
/**
|
|
8243
|
+
* Takes ownership of every element in `images`.
|
|
8244
|
+
* wasm-bindgen cannot borrow class values nested in an array; copy each retained
|
|
8245
|
+
* element with `copyForTransfer()` before passing the array.
|
|
7514
8246
|
* @param {WasmImageInfo[]} value
|
|
7515
8247
|
*/
|
|
7516
8248
|
set images(value) {
|
|
@@ -7537,6 +8269,9 @@ export class WasmScrapeResult {
|
|
|
7537
8269
|
wasm.wasmscraperesult_set_jsRenderHint(this.__wbg_ptr, value);
|
|
7538
8270
|
}
|
|
7539
8271
|
/**
|
|
8272
|
+
* Takes ownership of every element in `jsonLd`.
|
|
8273
|
+
* wasm-bindgen cannot borrow class values nested in an array; copy each retained
|
|
8274
|
+
* element with `copyForTransfer()` before passing the array.
|
|
7540
8275
|
* @param {WasmJsonLdEntry[]} value
|
|
7541
8276
|
*/
|
|
7542
8277
|
set jsonLd(value) {
|
|
@@ -7545,6 +8280,9 @@ export class WasmScrapeResult {
|
|
|
7545
8280
|
wasm.wasmscraperesult_set_jsonLd(this.__wbg_ptr, ptr0, len0);
|
|
7546
8281
|
}
|
|
7547
8282
|
/**
|
|
8283
|
+
* Takes ownership of every element in `links`.
|
|
8284
|
+
* wasm-bindgen cannot borrow class values nested in an array; copy each retained
|
|
8285
|
+
* element with `copyForTransfer()` before passing the array.
|
|
7548
8286
|
* @param {WasmLinkInfo[]} value
|
|
7549
8287
|
*/
|
|
7550
8288
|
set links(value) {
|
|
@@ -7553,23 +8291,18 @@ export class WasmScrapeResult {
|
|
|
7553
8291
|
wasm.wasmscraperesult_set_links(this.__wbg_ptr, ptr0, len0);
|
|
7554
8292
|
}
|
|
7555
8293
|
/**
|
|
7556
|
-
* @param {WasmMarkdownResult
|
|
8294
|
+
* @param {WasmMarkdownResult} value
|
|
7557
8295
|
*/
|
|
7558
8296
|
set markdown(value) {
|
|
7559
|
-
|
|
7560
|
-
|
|
7561
|
-
_assertClass(value, WasmMarkdownResult);
|
|
7562
|
-
ptr0 = value.__destroy_into_raw();
|
|
7563
|
-
}
|
|
7564
|
-
wasm.wasmscraperesult_set_markdown(this.__wbg_ptr, ptr0);
|
|
8297
|
+
_assertClass(value, WasmMarkdownResult);
|
|
8298
|
+
wasm.wasmscraperesult_set_markdown(this.__wbg_ptr, value.__wbg_ptr);
|
|
7565
8299
|
}
|
|
7566
8300
|
/**
|
|
7567
8301
|
* @param {WasmPageMetadata} value
|
|
7568
8302
|
*/
|
|
7569
8303
|
set metadata(value) {
|
|
7570
8304
|
_assertClass(value, WasmPageMetadata);
|
|
7571
|
-
|
|
7572
|
-
wasm.wasmscraperesult_set_metadata(this.__wbg_ptr, ptr0);
|
|
8305
|
+
wasm.wasmscraperesult_set_metadata(this.__wbg_ptr, value.__wbg_ptr);
|
|
7573
8306
|
}
|
|
7574
8307
|
/**
|
|
7575
8308
|
* @param {boolean} value
|
|
@@ -7584,15 +8317,11 @@ export class WasmScrapeResult {
|
|
|
7584
8317
|
wasm.wasmscraperesult_set_noindexDetected(this.__wbg_ptr, value);
|
|
7585
8318
|
}
|
|
7586
8319
|
/**
|
|
7587
|
-
* @param {WasmResponseMeta
|
|
8320
|
+
* @param {WasmResponseMeta} value
|
|
7588
8321
|
*/
|
|
7589
8322
|
set responseMeta(value) {
|
|
7590
|
-
|
|
7591
|
-
|
|
7592
|
-
_assertClass(value, WasmResponseMeta);
|
|
7593
|
-
ptr0 = value.__destroy_into_raw();
|
|
7594
|
-
}
|
|
7595
|
-
wasm.wasmscraperesult_set_responseMeta(this.__wbg_ptr, ptr0);
|
|
8323
|
+
_assertClass(value, WasmResponseMeta);
|
|
8324
|
+
wasm.wasmscraperesult_set_responseMeta(this.__wbg_ptr, value.__wbg_ptr);
|
|
7596
8325
|
}
|
|
7597
8326
|
/**
|
|
7598
8327
|
* @param {string | null} [value]
|
|
@@ -7602,6 +8331,14 @@ export class WasmScrapeResult {
|
|
|
7602
8331
|
var len0 = WASM_VECTOR_LEN;
|
|
7603
8332
|
wasm.wasmscraperesult_set_screenshotBase64(this.__wbg_ptr, ptr0, len0);
|
|
7604
8333
|
}
|
|
8334
|
+
/**
|
|
8335
|
+
* @param {string[]} value
|
|
8336
|
+
*/
|
|
8337
|
+
set ssrfRefusedUrls(value) {
|
|
8338
|
+
const ptr0 = passArrayJsValueToWasm0(value, wasm.__wbindgen_malloc);
|
|
8339
|
+
const len0 = WASM_VECTOR_LEN;
|
|
8340
|
+
wasm.wasmscraperesult_set_ssrfRefusedUrls(this.__wbg_ptr, ptr0, len0);
|
|
8341
|
+
}
|
|
7605
8342
|
/**
|
|
7606
8343
|
* @param {number} value
|
|
7607
8344
|
*/
|
|
@@ -7622,6 +8359,15 @@ export class WasmScrapeResult {
|
|
|
7622
8359
|
var len0 = WASM_VECTOR_LEN;
|
|
7623
8360
|
wasm.wasmscraperesult_set_xRobotsTag(this.__wbg_ptr, ptr0, len0);
|
|
7624
8361
|
}
|
|
8362
|
+
/**
|
|
8363
|
+
* @returns {string[]}
|
|
8364
|
+
*/
|
|
8365
|
+
get ssrfRefusedUrls() {
|
|
8366
|
+
const ret = wasm.wasmscraperesult_ssrfRefusedUrls(this.__wbg_ptr);
|
|
8367
|
+
var v1 = getArrayJsValueFromWasm0(ret[0], ret[1]);
|
|
8368
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
|
|
8369
|
+
return v1;
|
|
8370
|
+
}
|
|
7625
8371
|
/**
|
|
7626
8372
|
* @returns {number}
|
|
7627
8373
|
*/
|
|
@@ -7698,6 +8444,17 @@ export class WasmSitemapUrl {
|
|
|
7698
8444
|
}
|
|
7699
8445
|
return v1;
|
|
7700
8446
|
}
|
|
8447
|
+
/**
|
|
8448
|
+
* Return an independent handle for an ownership-taking API.
|
|
8449
|
+
*
|
|
8450
|
+
* Use `copyForTransfer()` for each class value placed in an array when the original
|
|
8451
|
+
* handle must remain usable.
|
|
8452
|
+
* @returns {WasmSitemapUrl}
|
|
8453
|
+
*/
|
|
8454
|
+
copyForTransfer() {
|
|
8455
|
+
const ret = wasm.wasmsitemapurl_copyForTransfer(this.__wbg_ptr);
|
|
8456
|
+
return WasmSitemapUrl.__wrap(ret);
|
|
8457
|
+
}
|
|
7701
8458
|
/**
|
|
7702
8459
|
* @returns {WasmSitemapUrl}
|
|
7703
8460
|
*/
|
|
@@ -7826,6 +8583,17 @@ export class WasmSsrfPolicy {
|
|
|
7826
8583
|
const ret = wasm.wasmssrfpolicy_allowlist(this.__wbg_ptr);
|
|
7827
8584
|
return ret;
|
|
7828
8585
|
}
|
|
8586
|
+
/**
|
|
8587
|
+
* Return an independent handle for an ownership-taking API.
|
|
8588
|
+
*
|
|
8589
|
+
* Use `copyForTransfer()` for each class value placed in an array when the original
|
|
8590
|
+
* handle must remain usable.
|
|
8591
|
+
* @returns {WasmSsrfPolicy}
|
|
8592
|
+
*/
|
|
8593
|
+
copyForTransfer() {
|
|
8594
|
+
const ret = wasm.wasmssrfpolicy_copyForTransfer(this.__wbg_ptr);
|
|
8595
|
+
return WasmSsrfPolicy.__wrap(ret);
|
|
8596
|
+
}
|
|
7829
8597
|
/**
|
|
7830
8598
|
* @returns {WasmSsrfPolicy}
|
|
7831
8599
|
*/
|
|
@@ -7840,6 +8608,13 @@ export class WasmSsrfPolicy {
|
|
|
7840
8608
|
const ret = wasm.wasmssrfpolicy_denyPrivate(this.__wbg_ptr);
|
|
7841
8609
|
return ret !== 0;
|
|
7842
8610
|
}
|
|
8611
|
+
/**
|
|
8612
|
+
* @returns {any}
|
|
8613
|
+
*/
|
|
8614
|
+
get denylist() {
|
|
8615
|
+
const ret = wasm.wasmssrfpolicy_denylist(this.__wbg_ptr);
|
|
8616
|
+
return ret;
|
|
8617
|
+
}
|
|
7843
8618
|
/**
|
|
7844
8619
|
* Create a policy from environment variables.
|
|
7845
8620
|
*
|
|
@@ -7852,13 +8627,13 @@ export class WasmSsrfPolicy {
|
|
|
7852
8627
|
* - Rust-side SSRF checking is unenforceable and redundant in a wasm32 context.
|
|
7853
8628
|
* - For testing and localhost access, the host's network sandbox is the enforcing boundary.
|
|
7854
8629
|
*
|
|
7855
|
-
* **Node.js caveat:** `deny_private`
|
|
7856
|
-
*
|
|
7857
|
-
*
|
|
7858
|
-
*
|
|
7859
|
-
*
|
|
7860
|
-
*
|
|
7861
|
-
*
|
|
8630
|
+
* **Node.js caveat:** `deny_private` and `denylist` have no effect on hostname-based requests
|
|
8631
|
+
* under `wasm32`. There is no DNS resolution on this target, so `validate_url` only ever
|
|
8632
|
+
* checks a literal IP host; a domain name falls straight through to `Ok(())`. In a browser
|
|
8633
|
+
* this is covered by same-origin/CORS. Node's `fetch` enforces no CORS, so a Node service
|
|
8634
|
+
* embedding this wasm module can be driven to internal hosts by domain name despite the
|
|
8635
|
+
* policy. Enforce egress restrictions (network policy, firewall, proxy allowlist) outside
|
|
8636
|
+
* the process.
|
|
7862
8637
|
* @returns {WasmSsrfPolicy}
|
|
7863
8638
|
*/
|
|
7864
8639
|
static fromEnv() {
|
|
@@ -7875,13 +8650,14 @@ export class WasmSsrfPolicy {
|
|
|
7875
8650
|
/**
|
|
7876
8651
|
* @param {boolean | null} [denyPrivate]
|
|
7877
8652
|
* @param {any | null} [allowlist]
|
|
8653
|
+
* @param {any | null} [denylist]
|
|
7878
8654
|
* @param {number | null} [maxRedirects]
|
|
7879
8655
|
* @param {string[] | null} [schemeAllowlist]
|
|
7880
8656
|
*/
|
|
7881
|
-
constructor(denyPrivate, allowlist, maxRedirects, schemeAllowlist) {
|
|
8657
|
+
constructor(denyPrivate, allowlist, denylist, maxRedirects, schemeAllowlist) {
|
|
7882
8658
|
var ptr0 = isLikeNone(schemeAllowlist) ? 0 : passArrayJsValueToWasm0(schemeAllowlist, wasm.__wbindgen_malloc);
|
|
7883
8659
|
var len0 = WASM_VECTOR_LEN;
|
|
7884
|
-
const ret = wasm.wasmssrfpolicy_new(isLikeNone(denyPrivate) ? 0xFFFFFF : denyPrivate ? 1 : 0, isLikeNone(allowlist) ? 0 : addToExternrefTable0(allowlist), isLikeNone(maxRedirects) ? 0xFFFFFF : maxRedirects, ptr0, len0);
|
|
8660
|
+
const ret = wasm.wasmssrfpolicy_new(isLikeNone(denyPrivate) ? 0xFFFFFF : denyPrivate ? 1 : 0, isLikeNone(allowlist) ? 0 : addToExternrefTable0(allowlist), isLikeNone(denylist) ? 0 : addToExternrefTable0(denylist), isLikeNone(maxRedirects) ? 0xFFFFFF : maxRedirects, ptr0, len0);
|
|
7885
8661
|
this.__wbg_ptr = ret;
|
|
7886
8662
|
WasmSsrfPolicyFinalization.register(this, this.__wbg_ptr, this);
|
|
7887
8663
|
return this;
|
|
@@ -7907,6 +8683,12 @@ export class WasmSsrfPolicy {
|
|
|
7907
8683
|
set denyPrivate(value) {
|
|
7908
8684
|
wasm.wasmssrfpolicy_set_denyPrivate(this.__wbg_ptr, value);
|
|
7909
8685
|
}
|
|
8686
|
+
/**
|
|
8687
|
+
* @param {any} value
|
|
8688
|
+
*/
|
|
8689
|
+
set denylist(value) {
|
|
8690
|
+
wasm.wasmssrfpolicy_set_denylist(this.__wbg_ptr, value);
|
|
8691
|
+
}
|
|
7910
8692
|
/**
|
|
7911
8693
|
* @param {number} value
|
|
7912
8694
|
*/
|
|
@@ -8582,13 +9364,13 @@ function __wbg_get_imports() {
|
|
|
8582
9364
|
return ret;
|
|
8583
9365
|
},
|
|
8584
9366
|
__wbindgen_generic_0000000000000001: function(arg0, arg1) {
|
|
8585
|
-
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [Externref], shim_idx:
|
|
9367
|
+
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [Externref], shim_idx: 1336, ret: Result(Unit), inner_ret: Some(Result(Unit)) }, mutable: true }) -> Externref`.
|
|
8586
9368
|
const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h2eedacf566f3748c);
|
|
8587
9369
|
return ret;
|
|
8588
9370
|
},
|
|
8589
9371
|
__wbindgen_generic_0000000000000002: function(arg0, arg1) {
|
|
8590
|
-
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [], shim_idx:
|
|
8591
|
-
const ret = makeMutClosure(arg0, arg1,
|
|
9372
|
+
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [], shim_idx: 1227, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
|
|
9373
|
+
const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h3a7ccac3e94bbb5c);
|
|
8592
9374
|
return ret;
|
|
8593
9375
|
},
|
|
8594
9376
|
__wbindgen_generic_0000000000000003: function(arg0) {
|
|
@@ -8627,8 +9409,8 @@ function __wbg_get_imports() {
|
|
|
8627
9409
|
};
|
|
8628
9410
|
}
|
|
8629
9411
|
|
|
8630
|
-
function
|
|
8631
|
-
wasm.
|
|
9412
|
+
function wasm_bindgen__convert__closures_____invoke__h3a7ccac3e94bbb5c(arg0, arg1) {
|
|
9413
|
+
wasm.wasm_bindgen__convert__closures_____invoke__h3a7ccac3e94bbb5c(arg0, arg1);
|
|
8632
9414
|
}
|
|
8633
9415
|
|
|
8634
9416
|
function wasm_bindgen__convert__closures_____invoke__h2eedacf566f3748c(arg0, arg1, arg2) {
|