1 |
|
2 |
|
3 |
|
4 |
|
5 |
|
6 |
|
7 |
|
8 |
|
9 |
|
10 |
|
11 |
|
12 |
|
13 |
|
14 |
|
15 |
|
16 |
|
17 |
|
18 |
|
19 |
|
20 | declare module 'inspector' {
|
21 | import EventEmitter = require('node:events');
|
22 | interface InspectorNotification<T> {
|
23 | method: string;
|
24 | params: T;
|
25 | }
|
26 | namespace Schema {
|
27 | |
28 |
|
29 |
|
30 | interface Domain {
|
31 | |
32 |
|
33 |
|
34 | name: string;
|
35 | |
36 |
|
37 |
|
38 | version: string;
|
39 | }
|
40 | interface GetDomainsReturnType {
|
41 | |
42 |
|
43 |
|
44 | domains: Domain[];
|
45 | }
|
46 | }
|
47 | namespace Runtime {
|
48 | |
49 |
|
50 |
|
51 | type ScriptId = string;
|
52 | |
53 |
|
54 |
|
55 | type RemoteObjectId = string;
|
56 | |
57 |
|
58 |
|
59 | type UnserializableValue = string;
|
60 | |
61 |
|
62 |
|
63 | interface RemoteObject {
|
64 | |
65 |
|
66 |
|
67 | type: string;
|
68 | |
69 |
|
70 |
|
71 | subtype?: string | undefined;
|
72 | |
73 |
|
74 |
|
75 | className?: string | undefined;
|
76 | |
77 |
|
78 |
|
79 | value?: any;
|
80 | |
81 |
|
82 |
|
83 | unserializableValue?: UnserializableValue | undefined;
|
84 | |
85 |
|
86 |
|
87 | description?: string | undefined;
|
88 | |
89 |
|
90 |
|
91 | objectId?: RemoteObjectId | undefined;
|
92 | |
93 |
|
94 |
|
95 |
|
96 | preview?: ObjectPreview | undefined;
|
97 | |
98 |
|
99 |
|
100 | customPreview?: CustomPreview | undefined;
|
101 | }
|
102 | |
103 |
|
104 |
|
105 | interface CustomPreview {
|
106 | header: string;
|
107 | hasBody: boolean;
|
108 | formatterObjectId: RemoteObjectId;
|
109 | bindRemoteObjectFunctionId: RemoteObjectId;
|
110 | configObjectId?: RemoteObjectId | undefined;
|
111 | }
|
112 | |
113 |
|
114 |
|
115 |
|
116 | interface ObjectPreview {
|
117 | |
118 |
|
119 |
|
120 | type: string;
|
121 | |
122 |
|
123 |
|
124 | subtype?: string | undefined;
|
125 | |
126 |
|
127 |
|
128 | description?: string | undefined;
|
129 | |
130 |
|
131 |
|
132 | overflow: boolean;
|
133 | |
134 |
|
135 |
|
136 | properties: PropertyPreview[];
|
137 | |
138 |
|
139 |
|
140 | entries?: EntryPreview[] | undefined;
|
141 | }
|
142 | |
143 |
|
144 |
|
145 | interface PropertyPreview {
|
146 | |
147 |
|
148 |
|
149 | name: string;
|
150 | |
151 |
|
152 |
|
153 | type: string;
|
154 | |
155 |
|
156 |
|
157 | value?: string | undefined;
|
158 | |
159 |
|
160 |
|
161 | valuePreview?: ObjectPreview | undefined;
|
162 | |
163 |
|
164 |
|
165 | subtype?: string | undefined;
|
166 | }
|
167 | |
168 |
|
169 |
|
170 | interface EntryPreview {
|
171 | |
172 |
|
173 |
|
174 | key?: ObjectPreview | undefined;
|
175 | |
176 |
|
177 |
|
178 | value: ObjectPreview;
|
179 | }
|
180 | |
181 |
|
182 |
|
183 | interface PropertyDescriptor {
|
184 | |
185 |
|
186 |
|
187 | name: string;
|
188 | |
189 |
|
190 |
|
191 | value?: RemoteObject | undefined;
|
192 | |
193 |
|
194 |
|
195 | writable?: boolean | undefined;
|
196 | |
197 |
|
198 |
|
199 | get?: RemoteObject | undefined;
|
200 | |
201 |
|
202 |
|
203 | set?: RemoteObject | undefined;
|
204 | |
205 |
|
206 |
|
207 | configurable: boolean;
|
208 | |
209 |
|
210 |
|
211 | enumerable: boolean;
|
212 | |
213 |
|
214 |
|
215 | wasThrown?: boolean | undefined;
|
216 | |
217 |
|
218 |
|
219 | isOwn?: boolean | undefined;
|
220 | |
221 |
|
222 |
|
223 | symbol?: RemoteObject | undefined;
|
224 | }
|
225 | |
226 |
|
227 |
|
228 | interface InternalPropertyDescriptor {
|
229 | |
230 |
|
231 |
|
232 | name: string;
|
233 | |
234 |
|
235 |
|
236 | value?: RemoteObject | undefined;
|
237 | }
|
238 | |
239 |
|
240 |
|
241 | interface CallArgument {
|
242 | |
243 |
|
244 |
|
245 | value?: any;
|
246 | |
247 |
|
248 |
|
249 | unserializableValue?: UnserializableValue | undefined;
|
250 | |
251 |
|
252 |
|
253 | objectId?: RemoteObjectId | undefined;
|
254 | }
|
255 | |
256 |
|
257 |
|
258 | type ExecutionContextId = number;
|
259 | |
260 |
|
261 |
|
262 | interface ExecutionContextDescription {
|
263 | |
264 |
|
265 |
|
266 | id: ExecutionContextId;
|
267 | |
268 |
|
269 |
|
270 | origin: string;
|
271 | |
272 |
|
273 |
|
274 | name: string;
|
275 | |
276 |
|
277 |
|
278 | auxData?: {} | undefined;
|
279 | }
|
280 | |
281 |
|
282 |
|
283 | interface ExceptionDetails {
|
284 | |
285 |
|
286 |
|
287 | exceptionId: number;
|
288 | |
289 |
|
290 |
|
291 | text: string;
|
292 | |
293 |
|
294 |
|
295 | lineNumber: number;
|
296 | |
297 |
|
298 |
|
299 | columnNumber: number;
|
300 | |
301 |
|
302 |
|
303 | scriptId?: ScriptId | undefined;
|
304 | |
305 |
|
306 |
|
307 | url?: string | undefined;
|
308 | |
309 |
|
310 |
|
311 | stackTrace?: StackTrace | undefined;
|
312 | |
313 |
|
314 |
|
315 | exception?: RemoteObject | undefined;
|
316 | |
317 |
|
318 |
|
319 | executionContextId?: ExecutionContextId | undefined;
|
320 | }
|
321 | |
322 |
|
323 |
|
324 | type Timestamp = number;
|
325 | |
326 |
|
327 |
|
328 | interface CallFrame {
|
329 | |
330 |
|
331 |
|
332 | functionName: string;
|
333 | |
334 |
|
335 |
|
336 | scriptId: ScriptId;
|
337 | |
338 |
|
339 |
|
340 | url: string;
|
341 | |
342 |
|
343 |
|
344 | lineNumber: number;
|
345 | |
346 |
|
347 |
|
348 | columnNumber: number;
|
349 | }
|
350 | |
351 |
|
352 |
|
353 | interface StackTrace {
|
354 | |
355 |
|
356 |
|
357 | description?: string | undefined;
|
358 | |
359 |
|
360 |
|
361 | callFrames: CallFrame[];
|
362 | |
363 |
|
364 |
|
365 | parent?: StackTrace | undefined;
|
366 | |
367 |
|
368 |
|
369 |
|
370 | parentId?: StackTraceId | undefined;
|
371 | }
|
372 | |
373 |
|
374 |
|
375 |
|
376 | type UniqueDebuggerId = string;
|
377 | |
378 |
|
379 |
|
380 |
|
381 | interface StackTraceId {
|
382 | id: string;
|
383 | debuggerId?: UniqueDebuggerId | undefined;
|
384 | }
|
385 | interface EvaluateParameterType {
|
386 | |
387 |
|
388 |
|
389 | expression: string;
|
390 | |
391 |
|
392 |
|
393 | objectGroup?: string | undefined;
|
394 | |
395 |
|
396 |
|
397 | includeCommandLineAPI?: boolean | undefined;
|
398 | |
399 |
|
400 |
|
401 | silent?: boolean | undefined;
|
402 | |
403 |
|
404 |
|
405 | contextId?: ExecutionContextId | undefined;
|
406 | |
407 |
|
408 |
|
409 | returnByValue?: boolean | undefined;
|
410 | |
411 |
|
412 |
|
413 |
|
414 | generatePreview?: boolean | undefined;
|
415 | |
416 |
|
417 |
|
418 | userGesture?: boolean | undefined;
|
419 | |
420 |
|
421 |
|
422 | awaitPromise?: boolean | undefined;
|
423 | }
|
424 | interface AwaitPromiseParameterType {
|
425 | |
426 |
|
427 |
|
428 | promiseObjectId: RemoteObjectId;
|
429 | |
430 |
|
431 |
|
432 | returnByValue?: boolean | undefined;
|
433 | |
434 |
|
435 |
|
436 | generatePreview?: boolean | undefined;
|
437 | }
|
438 | interface CallFunctionOnParameterType {
|
439 | |
440 |
|
441 |
|
442 | functionDeclaration: string;
|
443 | |
444 |
|
445 |
|
446 | objectId?: RemoteObjectId | undefined;
|
447 | |
448 |
|
449 |
|
450 | arguments?: CallArgument[] | undefined;
|
451 | |
452 |
|
453 |
|
454 | silent?: boolean | undefined;
|
455 | |
456 |
|
457 |
|
458 | returnByValue?: boolean | undefined;
|
459 | |
460 |
|
461 |
|
462 |
|
463 | generatePreview?: boolean | undefined;
|
464 | |
465 |
|
466 |
|
467 | userGesture?: boolean | undefined;
|
468 | |
469 |
|
470 |
|
471 | awaitPromise?: boolean | undefined;
|
472 | |
473 |
|
474 |
|
475 | executionContextId?: ExecutionContextId | undefined;
|
476 | |
477 |
|
478 |
|
479 | objectGroup?: string | undefined;
|
480 | }
|
481 | interface GetPropertiesParameterType {
|
482 | |
483 |
|
484 |
|
485 | objectId: RemoteObjectId;
|
486 | |
487 |
|
488 |
|
489 | ownProperties?: boolean | undefined;
|
490 | |
491 |
|
492 |
|
493 |
|
494 | accessorPropertiesOnly?: boolean | undefined;
|
495 | |
496 |
|
497 |
|
498 |
|
499 | generatePreview?: boolean | undefined;
|
500 | }
|
501 | interface ReleaseObjectParameterType {
|
502 | |
503 |
|
504 |
|
505 | objectId: RemoteObjectId;
|
506 | }
|
507 | interface ReleaseObjectGroupParameterType {
|
508 | |
509 |
|
510 |
|
511 | objectGroup: string;
|
512 | }
|
513 | interface SetCustomObjectFormatterEnabledParameterType {
|
514 | enabled: boolean;
|
515 | }
|
516 | interface CompileScriptParameterType {
|
517 | |
518 |
|
519 |
|
520 | expression: string;
|
521 | |
522 |
|
523 |
|
524 | sourceURL: string;
|
525 | |
526 |
|
527 |
|
528 | persistScript: boolean;
|
529 | |
530 |
|
531 |
|
532 | executionContextId?: ExecutionContextId | undefined;
|
533 | }
|
534 | interface RunScriptParameterType {
|
535 | |
536 |
|
537 |
|
538 | scriptId: ScriptId;
|
539 | |
540 |
|
541 |
|
542 | executionContextId?: ExecutionContextId | undefined;
|
543 | |
544 |
|
545 |
|
546 | objectGroup?: string | undefined;
|
547 | |
548 |
|
549 |
|
550 | silent?: boolean | undefined;
|
551 | |
552 |
|
553 |
|
554 | includeCommandLineAPI?: boolean | undefined;
|
555 | |
556 |
|
557 |
|
558 | returnByValue?: boolean | undefined;
|
559 | |
560 |
|
561 |
|
562 | generatePreview?: boolean | undefined;
|
563 | |
564 |
|
565 |
|
566 | awaitPromise?: boolean | undefined;
|
567 | }
|
568 | interface QueryObjectsParameterType {
|
569 | |
570 |
|
571 |
|
572 | prototypeObjectId: RemoteObjectId;
|
573 | }
|
574 | interface GlobalLexicalScopeNamesParameterType {
|
575 | |
576 |
|
577 |
|
578 | executionContextId?: ExecutionContextId | undefined;
|
579 | }
|
580 | interface EvaluateReturnType {
|
581 | |
582 |
|
583 |
|
584 | result: RemoteObject;
|
585 | |
586 |
|
587 |
|
588 | exceptionDetails?: ExceptionDetails | undefined;
|
589 | }
|
590 | interface AwaitPromiseReturnType {
|
591 | |
592 |
|
593 |
|
594 | result: RemoteObject;
|
595 | |
596 |
|
597 |
|
598 | exceptionDetails?: ExceptionDetails | undefined;
|
599 | }
|
600 | interface CallFunctionOnReturnType {
|
601 | |
602 |
|
603 |
|
604 | result: RemoteObject;
|
605 | |
606 |
|
607 |
|
608 | exceptionDetails?: ExceptionDetails | undefined;
|
609 | }
|
610 | interface GetPropertiesReturnType {
|
611 | |
612 |
|
613 |
|
614 | result: PropertyDescriptor[];
|
615 | |
616 |
|
617 |
|
618 | internalProperties?: InternalPropertyDescriptor[] | undefined;
|
619 | |
620 |
|
621 |
|
622 | exceptionDetails?: ExceptionDetails | undefined;
|
623 | }
|
624 | interface CompileScriptReturnType {
|
625 | |
626 |
|
627 |
|
628 | scriptId?: ScriptId | undefined;
|
629 | |
630 |
|
631 |
|
632 | exceptionDetails?: ExceptionDetails | undefined;
|
633 | }
|
634 | interface RunScriptReturnType {
|
635 | |
636 |
|
637 |
|
638 | result: RemoteObject;
|
639 | |
640 |
|
641 |
|
642 | exceptionDetails?: ExceptionDetails | undefined;
|
643 | }
|
644 | interface QueryObjectsReturnType {
|
645 | |
646 |
|
647 |
|
648 | objects: RemoteObject;
|
649 | }
|
650 | interface GlobalLexicalScopeNamesReturnType {
|
651 | names: string[];
|
652 | }
|
653 | interface ExecutionContextCreatedEventDataType {
|
654 | |
655 |
|
656 |
|
657 | context: ExecutionContextDescription;
|
658 | }
|
659 | interface ExecutionContextDestroyedEventDataType {
|
660 | |
661 |
|
662 |
|
663 | executionContextId: ExecutionContextId;
|
664 | }
|
665 | interface ExceptionThrownEventDataType {
|
666 | |
667 |
|
668 |
|
669 | timestamp: Timestamp;
|
670 | exceptionDetails: ExceptionDetails;
|
671 | }
|
672 | interface ExceptionRevokedEventDataType {
|
673 | |
674 |
|
675 |
|
676 | reason: string;
|
677 | |
678 |
|
679 |
|
680 | exceptionId: number;
|
681 | }
|
682 | interface ConsoleAPICalledEventDataType {
|
683 | |
684 |
|
685 |
|
686 | type: string;
|
687 | |
688 |
|
689 |
|
690 | args: RemoteObject[];
|
691 | |
692 |
|
693 |
|
694 | executionContextId: ExecutionContextId;
|
695 | |
696 |
|
697 |
|
698 | timestamp: Timestamp;
|
699 | |
700 |
|
701 |
|
702 | stackTrace?: StackTrace | undefined;
|
703 | |
704 |
|
705 |
|
706 |
|
707 | context?: string | undefined;
|
708 | }
|
709 | interface InspectRequestedEventDataType {
|
710 | object: RemoteObject;
|
711 | hints: {};
|
712 | }
|
713 | }
|
714 | namespace Debugger {
|
715 | |
716 |
|
717 |
|
718 | type BreakpointId = string;
|
719 | |
720 |
|
721 |
|
722 | type CallFrameId = string;
|
723 | |
724 |
|
725 |
|
726 | interface Location {
|
727 | |
728 |
|
729 |
|
730 | scriptId: Runtime.ScriptId;
|
731 | |
732 |
|
733 |
|
734 | lineNumber: number;
|
735 | |
736 |
|
737 |
|
738 | columnNumber?: number | undefined;
|
739 | }
|
740 | |
741 |
|
742 |
|
743 |
|
744 | interface ScriptPosition {
|
745 | lineNumber: number;
|
746 | columnNumber: number;
|
747 | }
|
748 | |
749 |
|
750 |
|
751 | interface CallFrame {
|
752 | |
753 |
|
754 |
|
755 | callFrameId: CallFrameId;
|
756 | |
757 |
|
758 |
|
759 | functionName: string;
|
760 | |
761 |
|
762 |
|
763 | functionLocation?: Location | undefined;
|
764 | |
765 |
|
766 |
|
767 | location: Location;
|
768 | |
769 |
|
770 |
|
771 | url: string;
|
772 | |
773 |
|
774 |
|
775 | scopeChain: Scope[];
|
776 | |
777 |
|
778 |
|
779 | this: Runtime.RemoteObject;
|
780 | |
781 |
|
782 |
|
783 | returnValue?: Runtime.RemoteObject | undefined;
|
784 | }
|
785 | |
786 |
|
787 |
|
788 | interface Scope {
|
789 | |
790 |
|
791 |
|
792 | type: string;
|
793 | |
794 |
|
795 |
|
796 | object: Runtime.RemoteObject;
|
797 | name?: string | undefined;
|
798 | |
799 |
|
800 |
|
801 | startLocation?: Location | undefined;
|
802 | |
803 |
|
804 |
|
805 | endLocation?: Location | undefined;
|
806 | }
|
807 | |
808 |
|
809 |
|
810 | interface SearchMatch {
|
811 | |
812 |
|
813 |
|
814 | lineNumber: number;
|
815 | |
816 |
|
817 |
|
818 | lineContent: string;
|
819 | }
|
820 | interface BreakLocation {
|
821 | |
822 |
|
823 |
|
824 | scriptId: Runtime.ScriptId;
|
825 | |
826 |
|
827 |
|
828 | lineNumber: number;
|
829 | |
830 |
|
831 |
|
832 | columnNumber?: number | undefined;
|
833 | type?: string | undefined;
|
834 | }
|
835 | interface SetBreakpointsActiveParameterType {
|
836 | |
837 |
|
838 |
|
839 | active: boolean;
|
840 | }
|
841 | interface SetSkipAllPausesParameterType {
|
842 | |
843 |
|
844 |
|
845 | skip: boolean;
|
846 | }
|
847 | interface SetBreakpointByUrlParameterType {
|
848 | |
849 |
|
850 |
|
851 | lineNumber: number;
|
852 | |
853 |
|
854 |
|
855 | url?: string | undefined;
|
856 | |
857 |
|
858 |
|
859 | urlRegex?: string | undefined;
|
860 | |
861 |
|
862 |
|
863 | scriptHash?: string | undefined;
|
864 | |
865 |
|
866 |
|
867 | columnNumber?: number | undefined;
|
868 | |
869 |
|
870 |
|
871 | condition?: string | undefined;
|
872 | }
|
873 | interface SetBreakpointParameterType {
|
874 | |
875 |
|
876 |
|
877 | location: Location;
|
878 | |
879 |
|
880 |
|
881 | condition?: string | undefined;
|
882 | }
|
883 | interface RemoveBreakpointParameterType {
|
884 | breakpointId: BreakpointId;
|
885 | }
|
886 | interface GetPossibleBreakpointsParameterType {
|
887 | |
888 |
|
889 |
|
890 | start: Location;
|
891 | |
892 |
|
893 |
|
894 | end?: Location | undefined;
|
895 | |
896 |
|
897 |
|
898 | restrictToFunction?: boolean | undefined;
|
899 | }
|
900 | interface ContinueToLocationParameterType {
|
901 | |
902 |
|
903 |
|
904 | location: Location;
|
905 | targetCallFrames?: string | undefined;
|
906 | }
|
907 | interface PauseOnAsyncCallParameterType {
|
908 | |
909 |
|
910 |
|
911 | parentStackTraceId: Runtime.StackTraceId;
|
912 | }
|
913 | interface StepIntoParameterType {
|
914 | |
915 |
|
916 |
|
917 |
|
918 | breakOnAsyncCall?: boolean | undefined;
|
919 | }
|
920 | interface GetStackTraceParameterType {
|
921 | stackTraceId: Runtime.StackTraceId;
|
922 | }
|
923 | interface SearchInContentParameterType {
|
924 | |
925 |
|
926 |
|
927 | scriptId: Runtime.ScriptId;
|
928 | |
929 |
|
930 |
|
931 | query: string;
|
932 | |
933 |
|
934 |
|
935 | caseSensitive?: boolean | undefined;
|
936 | |
937 |
|
938 |
|
939 | isRegex?: boolean | undefined;
|
940 | }
|
941 | interface SetScriptSourceParameterType {
|
942 | |
943 |
|
944 |
|
945 | scriptId: Runtime.ScriptId;
|
946 | |
947 |
|
948 |
|
949 | scriptSource: string;
|
950 | |
951 |
|
952 |
|
953 | dryRun?: boolean | undefined;
|
954 | }
|
955 | interface RestartFrameParameterType {
|
956 | |
957 |
|
958 |
|
959 | callFrameId: CallFrameId;
|
960 | }
|
961 | interface GetScriptSourceParameterType {
|
962 | |
963 |
|
964 |
|
965 | scriptId: Runtime.ScriptId;
|
966 | }
|
967 | interface SetPauseOnExceptionsParameterType {
|
968 | |
969 |
|
970 |
|
971 | state: string;
|
972 | }
|
973 | interface EvaluateOnCallFrameParameterType {
|
974 | |
975 |
|
976 |
|
977 | callFrameId: CallFrameId;
|
978 | |
979 |
|
980 |
|
981 | expression: string;
|
982 | |
983 |
|
984 |
|
985 | objectGroup?: string | undefined;
|
986 | |
987 |
|
988 |
|
989 | includeCommandLineAPI?: boolean | undefined;
|
990 | |
991 |
|
992 |
|
993 | silent?: boolean | undefined;
|
994 | |
995 |
|
996 |
|
997 | returnByValue?: boolean | undefined;
|
998 | |
999 |
|
1000 |
|
1001 |
|
1002 | generatePreview?: boolean | undefined;
|
1003 | |
1004 |
|
1005 |
|
1006 | throwOnSideEffect?: boolean | undefined;
|
1007 | }
|
1008 | interface SetVariableValueParameterType {
|
1009 | |
1010 |
|
1011 |
|
1012 | scopeNumber: number;
|
1013 | |
1014 |
|
1015 |
|
1016 | variableName: string;
|
1017 | |
1018 |
|
1019 |
|
1020 | newValue: Runtime.CallArgument;
|
1021 | |
1022 |
|
1023 |
|
1024 | callFrameId: CallFrameId;
|
1025 | }
|
1026 | interface SetReturnValueParameterType {
|
1027 | |
1028 |
|
1029 |
|
1030 | newValue: Runtime.CallArgument;
|
1031 | }
|
1032 | interface SetAsyncCallStackDepthParameterType {
|
1033 | |
1034 |
|
1035 |
|
1036 | maxDepth: number;
|
1037 | }
|
1038 | interface SetBlackboxPatternsParameterType {
|
1039 | |
1040 |
|
1041 |
|
1042 | patterns: string[];
|
1043 | }
|
1044 | interface SetBlackboxedRangesParameterType {
|
1045 | |
1046 |
|
1047 |
|
1048 | scriptId: Runtime.ScriptId;
|
1049 | positions: ScriptPosition[];
|
1050 | }
|
1051 | interface EnableReturnType {
|
1052 | |
1053 |
|
1054 |
|
1055 |
|
1056 | debuggerId: Runtime.UniqueDebuggerId;
|
1057 | }
|
1058 | interface SetBreakpointByUrlReturnType {
|
1059 | |
1060 |
|
1061 |
|
1062 | breakpointId: BreakpointId;
|
1063 | |
1064 |
|
1065 |
|
1066 | locations: Location[];
|
1067 | }
|
1068 | interface SetBreakpointReturnType {
|
1069 | |
1070 |
|
1071 |
|
1072 | breakpointId: BreakpointId;
|
1073 | |
1074 |
|
1075 |
|
1076 | actualLocation: Location;
|
1077 | }
|
1078 | interface GetPossibleBreakpointsReturnType {
|
1079 | |
1080 |
|
1081 |
|
1082 | locations: BreakLocation[];
|
1083 | }
|
1084 | interface GetStackTraceReturnType {
|
1085 | stackTrace: Runtime.StackTrace;
|
1086 | }
|
1087 | interface SearchInContentReturnType {
|
1088 | |
1089 |
|
1090 |
|
1091 | result: SearchMatch[];
|
1092 | }
|
1093 | interface SetScriptSourceReturnType {
|
1094 | |
1095 |
|
1096 |
|
1097 | callFrames?: CallFrame[] | undefined;
|
1098 | |
1099 |
|
1100 |
|
1101 | stackChanged?: boolean | undefined;
|
1102 | |
1103 |
|
1104 |
|
1105 | asyncStackTrace?: Runtime.StackTrace | undefined;
|
1106 | |
1107 |
|
1108 |
|
1109 |
|
1110 | asyncStackTraceId?: Runtime.StackTraceId | undefined;
|
1111 | |
1112 |
|
1113 |
|
1114 | exceptionDetails?: Runtime.ExceptionDetails | undefined;
|
1115 | }
|
1116 | interface RestartFrameReturnType {
|
1117 | |
1118 |
|
1119 |
|
1120 | callFrames: CallFrame[];
|
1121 | |
1122 |
|
1123 |
|
1124 | asyncStackTrace?: Runtime.StackTrace | undefined;
|
1125 | |
1126 |
|
1127 |
|
1128 |
|
1129 | asyncStackTraceId?: Runtime.StackTraceId | undefined;
|
1130 | }
|
1131 | interface GetScriptSourceReturnType {
|
1132 | |
1133 |
|
1134 |
|
1135 | scriptSource: string;
|
1136 | }
|
1137 | interface EvaluateOnCallFrameReturnType {
|
1138 | |
1139 |
|
1140 |
|
1141 | result: Runtime.RemoteObject;
|
1142 | |
1143 |
|
1144 |
|
1145 | exceptionDetails?: Runtime.ExceptionDetails | undefined;
|
1146 | }
|
1147 | interface ScriptParsedEventDataType {
|
1148 | |
1149 |
|
1150 |
|
1151 | scriptId: Runtime.ScriptId;
|
1152 | |
1153 |
|
1154 |
|
1155 | url: string;
|
1156 | |
1157 |
|
1158 |
|
1159 | startLine: number;
|
1160 | |
1161 |
|
1162 |
|
1163 | startColumn: number;
|
1164 | |
1165 |
|
1166 |
|
1167 | endLine: number;
|
1168 | |
1169 |
|
1170 |
|
1171 | endColumn: number;
|
1172 | |
1173 |
|
1174 |
|
1175 | executionContextId: Runtime.ExecutionContextId;
|
1176 | |
1177 |
|
1178 |
|
1179 | hash: string;
|
1180 | |
1181 |
|
1182 |
|
1183 | executionContextAuxData?: {} | undefined;
|
1184 | |
1185 |
|
1186 |
|
1187 |
|
1188 | isLiveEdit?: boolean | undefined;
|
1189 | |
1190 |
|
1191 |
|
1192 | sourceMapURL?: string | undefined;
|
1193 | |
1194 |
|
1195 |
|
1196 | hasSourceURL?: boolean | undefined;
|
1197 | |
1198 |
|
1199 |
|
1200 | isModule?: boolean | undefined;
|
1201 | |
1202 |
|
1203 |
|
1204 | length?: number | undefined;
|
1205 | |
1206 |
|
1207 |
|
1208 |
|
1209 | stackTrace?: Runtime.StackTrace | undefined;
|
1210 | }
|
1211 | interface ScriptFailedToParseEventDataType {
|
1212 | |
1213 |
|
1214 |
|
1215 | scriptId: Runtime.ScriptId;
|
1216 | |
1217 |
|
1218 |
|
1219 | url: string;
|
1220 | |
1221 |
|
1222 |
|
1223 | startLine: number;
|
1224 | |
1225 |
|
1226 |
|
1227 | startColumn: number;
|
1228 | |
1229 |
|
1230 |
|
1231 | endLine: number;
|
1232 | |
1233 |
|
1234 |
|
1235 | endColumn: number;
|
1236 | |
1237 |
|
1238 |
|
1239 | executionContextId: Runtime.ExecutionContextId;
|
1240 | |
1241 |
|
1242 |
|
1243 | hash: string;
|
1244 | |
1245 |
|
1246 |
|
1247 | executionContextAuxData?: {} | undefined;
|
1248 | |
1249 |
|
1250 |
|
1251 | sourceMapURL?: string | undefined;
|
1252 | |
1253 |
|
1254 |
|
1255 | hasSourceURL?: boolean | undefined;
|
1256 | |
1257 |
|
1258 |
|
1259 | isModule?: boolean | undefined;
|
1260 | |
1261 |
|
1262 |
|
1263 | length?: number | undefined;
|
1264 | |
1265 |
|
1266 |
|
1267 |
|
1268 | stackTrace?: Runtime.StackTrace | undefined;
|
1269 | }
|
1270 | interface BreakpointResolvedEventDataType {
|
1271 | |
1272 |
|
1273 |
|
1274 | breakpointId: BreakpointId;
|
1275 | |
1276 |
|
1277 |
|
1278 | location: Location;
|
1279 | }
|
1280 | interface PausedEventDataType {
|
1281 | |
1282 |
|
1283 |
|
1284 | callFrames: CallFrame[];
|
1285 | |
1286 |
|
1287 |
|
1288 | reason: string;
|
1289 | |
1290 |
|
1291 |
|
1292 | data?: {} | undefined;
|
1293 | |
1294 |
|
1295 |
|
1296 | hitBreakpoints?: string[] | undefined;
|
1297 | |
1298 |
|
1299 |
|
1300 | asyncStackTrace?: Runtime.StackTrace | undefined;
|
1301 | |
1302 |
|
1303 |
|
1304 |
|
1305 | asyncStackTraceId?: Runtime.StackTraceId | undefined;
|
1306 | |
1307 |
|
1308 |
|
1309 |
|
1310 | asyncCallStackTraceId?: Runtime.StackTraceId | undefined;
|
1311 | }
|
1312 | }
|
1313 | namespace Console {
|
1314 | |
1315 |
|
1316 |
|
1317 | interface ConsoleMessage {
|
1318 | |
1319 |
|
1320 |
|
1321 | source: string;
|
1322 | |
1323 |
|
1324 |
|
1325 | level: string;
|
1326 | |
1327 |
|
1328 |
|
1329 | text: string;
|
1330 | |
1331 |
|
1332 |
|
1333 | url?: string | undefined;
|
1334 | |
1335 |
|
1336 |
|
1337 | line?: number | undefined;
|
1338 | |
1339 |
|
1340 |
|
1341 | column?: number | undefined;
|
1342 | }
|
1343 | interface MessageAddedEventDataType {
|
1344 | |
1345 |
|
1346 |
|
1347 | message: ConsoleMessage;
|
1348 | }
|
1349 | }
|
1350 | namespace Profiler {
|
1351 | |
1352 |
|
1353 |
|
1354 | interface ProfileNode {
|
1355 | |
1356 |
|
1357 |
|
1358 | id: number;
|
1359 | |
1360 |
|
1361 |
|
1362 | callFrame: Runtime.CallFrame;
|
1363 | |
1364 |
|
1365 |
|
1366 | hitCount?: number | undefined;
|
1367 | |
1368 |
|
1369 |
|
1370 | children?: number[] | undefined;
|
1371 | |
1372 |
|
1373 |
|
1374 | deoptReason?: string | undefined;
|
1375 | |
1376 |
|
1377 |
|
1378 | positionTicks?: PositionTickInfo[] | undefined;
|
1379 | }
|
1380 | |
1381 |
|
1382 |
|
1383 | interface Profile {
|
1384 | |
1385 |
|
1386 |
|
1387 | nodes: ProfileNode[];
|
1388 | |
1389 |
|
1390 |
|
1391 | startTime: number;
|
1392 | |
1393 |
|
1394 |
|
1395 | endTime: number;
|
1396 | |
1397 |
|
1398 |
|
1399 | samples?: number[] | undefined;
|
1400 | |
1401 |
|
1402 |
|
1403 | timeDeltas?: number[] | undefined;
|
1404 | }
|
1405 | |
1406 |
|
1407 |
|
1408 | interface PositionTickInfo {
|
1409 | |
1410 |
|
1411 |
|
1412 | line: number;
|
1413 | |
1414 |
|
1415 |
|
1416 | ticks: number;
|
1417 | }
|
1418 | |
1419 |
|
1420 |
|
1421 | interface CoverageRange {
|
1422 | |
1423 |
|
1424 |
|
1425 | startOffset: number;
|
1426 | |
1427 |
|
1428 |
|
1429 | endOffset: number;
|
1430 | |
1431 |
|
1432 |
|
1433 | count: number;
|
1434 | }
|
1435 | |
1436 |
|
1437 |
|
1438 | interface FunctionCoverage {
|
1439 | |
1440 |
|
1441 |
|
1442 | functionName: string;
|
1443 | |
1444 |
|
1445 |
|
1446 | ranges: CoverageRange[];
|
1447 | |
1448 |
|
1449 |
|
1450 | isBlockCoverage: boolean;
|
1451 | }
|
1452 | |
1453 |
|
1454 |
|
1455 | interface ScriptCoverage {
|
1456 | |
1457 |
|
1458 |
|
1459 | scriptId: Runtime.ScriptId;
|
1460 | |
1461 |
|
1462 |
|
1463 | url: string;
|
1464 | |
1465 |
|
1466 |
|
1467 | functions: FunctionCoverage[];
|
1468 | }
|
1469 | |
1470 |
|
1471 |
|
1472 |
|
1473 | interface TypeObject {
|
1474 | |
1475 |
|
1476 |
|
1477 | name: string;
|
1478 | }
|
1479 | |
1480 |
|
1481 |
|
1482 |
|
1483 | interface TypeProfileEntry {
|
1484 | |
1485 |
|
1486 |
|
1487 | offset: number;
|
1488 | |
1489 |
|
1490 |
|
1491 | types: TypeObject[];
|
1492 | }
|
1493 | |
1494 |
|
1495 |
|
1496 |
|
1497 | interface ScriptTypeProfile {
|
1498 | |
1499 |
|
1500 |
|
1501 | scriptId: Runtime.ScriptId;
|
1502 | |
1503 |
|
1504 |
|
1505 | url: string;
|
1506 | |
1507 |
|
1508 |
|
1509 | entries: TypeProfileEntry[];
|
1510 | }
|
1511 | interface SetSamplingIntervalParameterType {
|
1512 | |
1513 |
|
1514 |
|
1515 | interval: number;
|
1516 | }
|
1517 | interface StartPreciseCoverageParameterType {
|
1518 | |
1519 |
|
1520 |
|
1521 | callCount?: boolean | undefined;
|
1522 | |
1523 |
|
1524 |
|
1525 | detailed?: boolean | undefined;
|
1526 | }
|
1527 | interface StopReturnType {
|
1528 | |
1529 |
|
1530 |
|
1531 | profile: Profile;
|
1532 | }
|
1533 | interface TakePreciseCoverageReturnType {
|
1534 | |
1535 |
|
1536 |
|
1537 | result: ScriptCoverage[];
|
1538 | }
|
1539 | interface GetBestEffortCoverageReturnType {
|
1540 | |
1541 |
|
1542 |
|
1543 | result: ScriptCoverage[];
|
1544 | }
|
1545 | interface TakeTypeProfileReturnType {
|
1546 | |
1547 |
|
1548 |
|
1549 | result: ScriptTypeProfile[];
|
1550 | }
|
1551 | interface ConsoleProfileStartedEventDataType {
|
1552 | id: string;
|
1553 | |
1554 |
|
1555 |
|
1556 | location: Debugger.Location;
|
1557 | |
1558 |
|
1559 |
|
1560 | title?: string | undefined;
|
1561 | }
|
1562 | interface ConsoleProfileFinishedEventDataType {
|
1563 | id: string;
|
1564 | |
1565 |
|
1566 |
|
1567 | location: Debugger.Location;
|
1568 | profile: Profile;
|
1569 | |
1570 |
|
1571 |
|
1572 | title?: string | undefined;
|
1573 | }
|
1574 | }
|
1575 | namespace HeapProfiler {
|
1576 | |
1577 |
|
1578 |
|
1579 | type HeapSnapshotObjectId = string;
|
1580 | |
1581 |
|
1582 |
|
1583 | interface SamplingHeapProfileNode {
|
1584 | |
1585 |
|
1586 |
|
1587 | callFrame: Runtime.CallFrame;
|
1588 | |
1589 |
|
1590 |
|
1591 | selfSize: number;
|
1592 | |
1593 |
|
1594 |
|
1595 | children: SamplingHeapProfileNode[];
|
1596 | }
|
1597 | |
1598 |
|
1599 |
|
1600 | interface SamplingHeapProfile {
|
1601 | head: SamplingHeapProfileNode;
|
1602 | }
|
1603 | interface StartTrackingHeapObjectsParameterType {
|
1604 | trackAllocations?: boolean | undefined;
|
1605 | }
|
1606 | interface StopTrackingHeapObjectsParameterType {
|
1607 | |
1608 |
|
1609 |
|
1610 | reportProgress?: boolean | undefined;
|
1611 | }
|
1612 | interface TakeHeapSnapshotParameterType {
|
1613 | |
1614 |
|
1615 |
|
1616 | reportProgress?: boolean | undefined;
|
1617 | }
|
1618 | interface GetObjectByHeapObjectIdParameterType {
|
1619 | objectId: HeapSnapshotObjectId;
|
1620 | |
1621 |
|
1622 |
|
1623 | objectGroup?: string | undefined;
|
1624 | }
|
1625 | interface AddInspectedHeapObjectParameterType {
|
1626 | |
1627 |
|
1628 |
|
1629 | heapObjectId: HeapSnapshotObjectId;
|
1630 | }
|
1631 | interface GetHeapObjectIdParameterType {
|
1632 | |
1633 |
|
1634 |
|
1635 | objectId: Runtime.RemoteObjectId;
|
1636 | }
|
1637 | interface StartSamplingParameterType {
|
1638 | |
1639 |
|
1640 |
|
1641 | samplingInterval?: number | undefined;
|
1642 | }
|
1643 | interface GetObjectByHeapObjectIdReturnType {
|
1644 | |
1645 |
|
1646 |
|
1647 | result: Runtime.RemoteObject;
|
1648 | }
|
1649 | interface GetHeapObjectIdReturnType {
|
1650 | |
1651 |
|
1652 |
|
1653 | heapSnapshotObjectId: HeapSnapshotObjectId;
|
1654 | }
|
1655 | interface StopSamplingReturnType {
|
1656 | |
1657 |
|
1658 |
|
1659 | profile: SamplingHeapProfile;
|
1660 | }
|
1661 | interface GetSamplingProfileReturnType {
|
1662 | |
1663 |
|
1664 |
|
1665 | profile: SamplingHeapProfile;
|
1666 | }
|
1667 | interface AddHeapSnapshotChunkEventDataType {
|
1668 | chunk: string;
|
1669 | }
|
1670 | interface ReportHeapSnapshotProgressEventDataType {
|
1671 | done: number;
|
1672 | total: number;
|
1673 | finished?: boolean | undefined;
|
1674 | }
|
1675 | interface LastSeenObjectIdEventDataType {
|
1676 | lastSeenObjectId: number;
|
1677 | timestamp: number;
|
1678 | }
|
1679 | interface HeapStatsUpdateEventDataType {
|
1680 | |
1681 |
|
1682 |
|
1683 | statsUpdate: number[];
|
1684 | }
|
1685 | }
|
1686 | namespace NodeTracing {
|
1687 | interface TraceConfig {
|
1688 | |
1689 |
|
1690 |
|
1691 | recordMode?: string;
|
1692 | |
1693 |
|
1694 |
|
1695 | includedCategories: string[];
|
1696 | }
|
1697 | interface StartParameterType {
|
1698 | traceConfig: TraceConfig;
|
1699 | }
|
1700 | interface GetCategoriesReturnType {
|
1701 | |
1702 |
|
1703 |
|
1704 | categories: string[];
|
1705 | }
|
1706 | interface DataCollectedEventDataType {
|
1707 | value: Array<{}>;
|
1708 | }
|
1709 | }
|
1710 | namespace NodeWorker {
|
1711 | type WorkerID = string;
|
1712 | |
1713 |
|
1714 |
|
1715 | type SessionID = string;
|
1716 | interface WorkerInfo {
|
1717 | workerId: WorkerID;
|
1718 | type: string;
|
1719 | title: string;
|
1720 | url: string;
|
1721 | }
|
1722 | interface SendMessageToWorkerParameterType {
|
1723 | message: string;
|
1724 | |
1725 |
|
1726 |
|
1727 | sessionId: SessionID;
|
1728 | }
|
1729 | interface EnableParameterType {
|
1730 | |
1731 |
|
1732 |
|
1733 |
|
1734 | waitForDebuggerOnStart: boolean;
|
1735 | }
|
1736 | interface DetachParameterType {
|
1737 | sessionId: SessionID;
|
1738 | }
|
1739 | interface AttachedToWorkerEventDataType {
|
1740 | |
1741 |
|
1742 |
|
1743 | sessionId: SessionID;
|
1744 | workerInfo: WorkerInfo;
|
1745 | waitingForDebugger: boolean;
|
1746 | }
|
1747 | interface DetachedFromWorkerEventDataType {
|
1748 | |
1749 |
|
1750 |
|
1751 | sessionId: SessionID;
|
1752 | }
|
1753 | interface ReceivedMessageFromWorkerEventDataType {
|
1754 | |
1755 |
|
1756 |
|
1757 | sessionId: SessionID;
|
1758 | message: string;
|
1759 | }
|
1760 | }
|
1761 | namespace NodeRuntime {
|
1762 | interface NotifyWhenWaitingForDisconnectParameterType {
|
1763 | enabled: boolean;
|
1764 | }
|
1765 | }
|
1766 | |
1767 |
|
1768 |
|
1769 |
|
1770 | class Session extends EventEmitter {
|
1771 | |
1772 |
|
1773 |
|
1774 |
|
1775 | constructor();
|
1776 | /**
|
1777 | * Connects a session to the inspector back-end.
|
1778 | * @since v8.0.0
|
1779 | */
|
1780 | connect(): void;
|
1781 | /**
|
1782 | * Immediately close the session. All pending message callbacks will be called
|
1783 | * with an error. `session.connect()` will need to be called to be able to send
|
1784 | * messages again. Reconnected session will lose all inspector state, such as
|
1785 | * enabled agents or configured breakpoints.
|
1786 | * @since v8.0.0
|
1787 | */
|
1788 | disconnect(): void;
|
1789 | /**
|
1790 | * Posts a message to the inspector back-end. `callback` will be notified when
|
1791 | * a response is received. `callback` is a function that accepts two optional
|
1792 | * arguments: error and message-specific result.
|
1793 | *
|
1794 | * ```js
|
1795 | * session.post('Runtime.evaluate', { expression: '2 + 2' },
|
1796 | * (error, { result }) => console.log(result));
|
1797 | * // Output: { type: 'number', value: 4, description: '4' }
|
1798 | * ```
|
1799 | *
|
1800 | * The latest version of the V8 inspector protocol is published on the[Chrome DevTools Protocol Viewer](https://chromedevtools.github.io/devtools-protocol/v8/).
|
1801 | *
|
1802 | * Node.js inspector supports all the Chrome DevTools Protocol domains declared
|
1803 | * by V8\. Chrome DevTools Protocol domain provides an interface for interacting
|
1804 | * with one of the runtime agents used to inspect the application state and listen
|
1805 | * to the run-time events.
|
1806 | *
|
1807 | * ## Example usage
|
1808 | *
|
1809 | * Apart from the debugger, various V8 Profilers are available through the DevTools
|
1810 | * protocol.
|
1811 | * @since v8.0.0
|
1812 | */
|
1813 | post(method: string, params?: {}, callback?: (err: Error | null, params?: {}) => void): void;
|
1814 | post(method: string, callback?: (err: Error | null, params?: {}) => void): void;
|
1815 | /**
|
1816 | * Returns supported domains.
|
1817 | */
|
1818 | post(method: 'Schema.getDomains', callback?: (err: Error | null, params: Schema.GetDomainsReturnType) => void): void;
|
1819 | /**
|
1820 | * Evaluates expression on global object.
|
1821 | */
|
1822 | post(method: 'Runtime.evaluate', params?: Runtime.EvaluateParameterType, callback?: (err: Error | null, params: Runtime.EvaluateReturnType) => void): void;
|
1823 | post(method: 'Runtime.evaluate', callback?: (err: Error | null, params: Runtime.EvaluateReturnType) => void): void;
|
1824 | /**
|
1825 | * Add handler to promise with given promise object id.
|
1826 | */
|
1827 | post(method: 'Runtime.awaitPromise', params?: Runtime.AwaitPromiseParameterType, callback?: (err: Error | null, params: Runtime.AwaitPromiseReturnType) => void): void;
|
1828 | post(method: 'Runtime.awaitPromise', callback?: (err: Error | null, params: Runtime.AwaitPromiseReturnType) => void): void;
|
1829 | /**
|
1830 | * Calls function with given declaration on the given object. Object group of the result is inherited from the target object.
|
1831 | */
|
1832 | post(method: 'Runtime.callFunctionOn', params?: Runtime.CallFunctionOnParameterType, callback?: (err: Error | null, params: Runtime.CallFunctionOnReturnType) => void): void;
|
1833 | post(method: 'Runtime.callFunctionOn', callback?: (err: Error | null, params: Runtime.CallFunctionOnReturnType) => void): void;
|
1834 | /**
|
1835 | * Returns properties of a given object. Object group of the result is inherited from the target object.
|
1836 | */
|
1837 | post(method: 'Runtime.getProperties', params?: Runtime.GetPropertiesParameterType, callback?: (err: Error | null, params: Runtime.GetPropertiesReturnType) => void): void;
|
1838 | post(method: 'Runtime.getProperties', callback?: (err: Error | null, params: Runtime.GetPropertiesReturnType) => void): void;
|
1839 | /**
|
1840 | * Releases remote object with given id.
|
1841 | */
|
1842 | post(method: 'Runtime.releaseObject', params?: Runtime.ReleaseObjectParameterType, callback?: (err: Error | null) => void): void;
|
1843 | post(method: 'Runtime.releaseObject', callback?: (err: Error | null) => void): void;
|
1844 | /**
|
1845 | * Releases all remote objects that belong to a given group.
|
1846 | */
|
1847 | post(method: 'Runtime.releaseObjectGroup', params?: Runtime.ReleaseObjectGroupParameterType, callback?: (err: Error | null) => void): void;
|
1848 | post(method: 'Runtime.releaseObjectGroup', callback?: (err: Error | null) => void): void;
|
1849 | /**
|
1850 | * Tells inspected instance to run if it was waiting for debugger to attach.
|
1851 | */
|
1852 | post(method: 'Runtime.runIfWaitingForDebugger', callback?: (err: Error | null) => void): void;
|
1853 | /**
|
1854 | * Enables reporting of execution contexts creation by means of <code>executionContextCreated</code> event. When the reporting gets enabled the event will be sent immediately for each existing execution context.
|
1855 | */
|
1856 | post(method: 'Runtime.enable', callback?: (err: Error | null) => void): void;
|
1857 | /**
|
1858 | * Disables reporting of execution contexts creation.
|
1859 | */
|
1860 | post(method: 'Runtime.disable', callback?: (err: Error | null) => void): void;
|
1861 | /**
|
1862 | * Discards collected exceptions and console API calls.
|
1863 | */
|
1864 | post(method: 'Runtime.discardConsoleEntries', callback?: (err: Error | null) => void): void;
|
1865 | /**
|
1866 | * @experimental
|
1867 | */
|
1868 | post(method: 'Runtime.setCustomObjectFormatterEnabled', params?: Runtime.SetCustomObjectFormatterEnabledParameterType, callback?: (err: Error | null) => void): void;
|
1869 | post(method: 'Runtime.setCustomObjectFormatterEnabled', callback?: (err: Error | null) => void): void;
|
1870 | /**
|
1871 | * Compiles expression.
|
1872 | */
|
1873 | post(method: 'Runtime.compileScript', params?: Runtime.CompileScriptParameterType, callback?: (err: Error | null, params: Runtime.CompileScriptReturnType) => void): void;
|
1874 | post(method: 'Runtime.compileScript', callback?: (err: Error | null, params: Runtime.CompileScriptReturnType) => void): void;
|
1875 | /**
|
1876 | * Runs script with given id in a given context.
|
1877 | */
|
1878 | post(method: 'Runtime.runScript', params?: Runtime.RunScriptParameterType, callback?: (err: Error | null, params: Runtime.RunScriptReturnType) => void): void;
|
1879 | post(method: 'Runtime.runScript', callback?: (err: Error | null, params: Runtime.RunScriptReturnType) => void): void;
|
1880 | post(method: 'Runtime.queryObjects', params?: Runtime.QueryObjectsParameterType, callback?: (err: Error | null, params: Runtime.QueryObjectsReturnType) => void): void;
|
1881 | post(method: 'Runtime.queryObjects', callback?: (err: Error | null, params: Runtime.QueryObjectsReturnType) => void): void;
|
1882 | /**
|
1883 | * Returns all let, const and class variables from global scope.
|
1884 | */
|
1885 | post(
|
1886 | method: 'Runtime.globalLexicalScopeNames',
|
1887 | params?: Runtime.GlobalLexicalScopeNamesParameterType,
|
1888 | callback?: (err: Error | null, params: Runtime.GlobalLexicalScopeNamesReturnType) => void
|
1889 | ): void;
|
1890 | post(method: 'Runtime.globalLexicalScopeNames', callback?: (err: Error | null, params: Runtime.GlobalLexicalScopeNamesReturnType) => void): void;
|
1891 | /**
|
1892 | * Enables debugger for the given page. Clients should not assume that the debugging has been enabled until the result for this command is received.
|
1893 | */
|
1894 | post(method: 'Debugger.enable', callback?: (err: Error | null, params: Debugger.EnableReturnType) => void): void;
|
1895 | /**
|
1896 | * Disables debugger for given page.
|
1897 | */
|
1898 | post(method: 'Debugger.disable', callback?: (err: Error | null) => void): void;
|
1899 | /**
|
1900 | * Activates / deactivates all breakpoints on the page.
|
1901 | */
|
1902 | post(method: 'Debugger.setBreakpointsActive', params?: Debugger.SetBreakpointsActiveParameterType, callback?: (err: Error | null) => void): void;
|
1903 | post(method: 'Debugger.setBreakpointsActive', callback?: (err: Error | null) => void): void;
|
1904 | /**
|
1905 | * Makes page not interrupt on any pauses (breakpoint, exception, dom exception etc).
|
1906 | */
|
1907 | post(method: 'Debugger.setSkipAllPauses', params?: Debugger.SetSkipAllPausesParameterType, callback?: (err: Error | null) => void): void;
|
1908 | post(method: 'Debugger.setSkipAllPauses', callback?: (err: Error | null) => void): void;
|
1909 | /**
|
1910 | * Sets JavaScript breakpoint at given location specified either by URL or URL regex. Once this command is issued, all existing parsed scripts will have breakpoints resolved and returned in <code>locations</code> property. Further matching script parsing will result in subsequent <code>breakpointResolved</code> events issued. This logical breakpoint will survive page reloads.
|
1911 | */
|
1912 | post(method: 'Debugger.setBreakpointByUrl', params?: Debugger.SetBreakpointByUrlParameterType, callback?: (err: Error | null, params: Debugger.SetBreakpointByUrlReturnType) => void): void;
|
1913 | post(method: 'Debugger.setBreakpointByUrl', callback?: (err: Error | null, params: Debugger.SetBreakpointByUrlReturnType) => void): void;
|
1914 | /**
|
1915 | * Sets JavaScript breakpoint at a given location.
|
1916 | */
|
1917 | post(method: 'Debugger.setBreakpoint', params?: Debugger.SetBreakpointParameterType, callback?: (err: Error | null, params: Debugger.SetBreakpointReturnType) => void): void;
|
1918 | post(method: 'Debugger.setBreakpoint', callback?: (err: Error | null, params: Debugger.SetBreakpointReturnType) => void): void;
|
1919 | /**
|
1920 | * Removes JavaScript breakpoint.
|
1921 | */
|
1922 | post(method: 'Debugger.removeBreakpoint', params?: Debugger.RemoveBreakpointParameterType, callback?: (err: Error | null) => void): void;
|
1923 | post(method: 'Debugger.removeBreakpoint', callback?: (err: Error | null) => void): void;
|
1924 | /**
|
1925 | * Returns possible locations for breakpoint. scriptId in start and end range locations should be the same.
|
1926 | */
|
1927 | post(
|
1928 | method: 'Debugger.getPossibleBreakpoints',
|
1929 | params?: Debugger.GetPossibleBreakpointsParameterType,
|
1930 | callback?: (err: Error | null, params: Debugger.GetPossibleBreakpointsReturnType) => void
|
1931 | ): void;
|
1932 | post(method: 'Debugger.getPossibleBreakpoints', callback?: (err: Error | null, params: Debugger.GetPossibleBreakpointsReturnType) => void): void;
|
1933 | /**
|
1934 | * Continues execution until specific location is reached.
|
1935 | */
|
1936 | post(method: 'Debugger.continueToLocation', params?: Debugger.ContinueToLocationParameterType, callback?: (err: Error | null) => void): void;
|
1937 | post(method: 'Debugger.continueToLocation', callback?: (err: Error | null) => void): void;
|
1938 | /**
|
1939 | * @experimental
|
1940 | */
|
1941 | post(method: 'Debugger.pauseOnAsyncCall', params?: Debugger.PauseOnAsyncCallParameterType, callback?: (err: Error | null) => void): void;
|
1942 | post(method: 'Debugger.pauseOnAsyncCall', callback?: (err: Error | null) => void): void;
|
1943 | /**
|
1944 | * Steps over the statement.
|
1945 | */
|
1946 | post(method: 'Debugger.stepOver', callback?: (err: Error | null) => void): void;
|
1947 | /**
|
1948 | * Steps into the function call.
|
1949 | */
|
1950 | post(method: 'Debugger.stepInto', params?: Debugger.StepIntoParameterType, callback?: (err: Error | null) => void): void;
|
1951 | post(method: 'Debugger.stepInto', callback?: (err: Error | null) => void): void;
|
1952 | /**
|
1953 | * Steps out of the function call.
|
1954 | */
|
1955 | post(method: 'Debugger.stepOut', callback?: (err: Error | null) => void): void;
|
1956 | /**
|
1957 | * Stops on the next JavaScript statement.
|
1958 | */
|
1959 | post(method: 'Debugger.pause', callback?: (err: Error | null) => void): void;
|
1960 | /**
|
1961 | * This method is deprecated - use Debugger.stepInto with breakOnAsyncCall and Debugger.pauseOnAsyncTask instead. Steps into next scheduled async task if any is scheduled before next pause. Returns success when async task is actually scheduled, returns error if no task were scheduled or another scheduleStepIntoAsync was called.
|
1962 | * @experimental
|
1963 | */
|
1964 | post(method: 'Debugger.scheduleStepIntoAsync', callback?: (err: Error | null) => void): void;
|
1965 | /**
|
1966 | * Resumes JavaScript execution.
|
1967 | */
|
1968 | post(method: 'Debugger.resume', callback?: (err: Error | null) => void): void;
|
1969 | /**
|
1970 | * Returns stack trace with given <code>stackTraceId</code>.
|
1971 | * @experimental
|
1972 | */
|
1973 | post(method: 'Debugger.getStackTrace', params?: Debugger.GetStackTraceParameterType, callback?: (err: Error | null, params: Debugger.GetStackTraceReturnType) => void): void;
|
1974 | post(method: 'Debugger.getStackTrace', callback?: (err: Error | null, params: Debugger.GetStackTraceReturnType) => void): void;
|
1975 | /**
|
1976 | * Searches for given string in script content.
|
1977 | */
|
1978 | post(method: 'Debugger.searchInContent', params?: Debugger.SearchInContentParameterType, callback?: (err: Error | null, params: Debugger.SearchInContentReturnType) => void): void;
|
1979 | post(method: 'Debugger.searchInContent', callback?: (err: Error | null, params: Debugger.SearchInContentReturnType) => void): void;
|
1980 | /**
|
1981 | * Edits JavaScript source live.
|
1982 | */
|
1983 | post(method: 'Debugger.setScriptSource', params?: Debugger.SetScriptSourceParameterType, callback?: (err: Error | null, params: Debugger.SetScriptSourceReturnType) => void): void;
|
1984 | post(method: 'Debugger.setScriptSource', callback?: (err: Error | null, params: Debugger.SetScriptSourceReturnType) => void): void;
|
1985 | /**
|
1986 | * Restarts particular call frame from the beginning.
|
1987 | */
|
1988 | post(method: 'Debugger.restartFrame', params?: Debugger.RestartFrameParameterType, callback?: (err: Error | null, params: Debugger.RestartFrameReturnType) => void): void;
|
1989 | post(method: 'Debugger.restartFrame', callback?: (err: Error | null, params: Debugger.RestartFrameReturnType) => void): void;
|
1990 | /**
|
1991 | * Returns source for the script with given id.
|
1992 | */
|
1993 | post(method: 'Debugger.getScriptSource', params?: Debugger.GetScriptSourceParameterType, callback?: (err: Error | null, params: Debugger.GetScriptSourceReturnType) => void): void;
|
1994 | post(method: 'Debugger.getScriptSource', callback?: (err: Error | null, params: Debugger.GetScriptSourceReturnType) => void): void;
|
1995 | /**
|
1996 | * Defines pause on exceptions state. Can be set to stop on all exceptions, uncaught exceptions or no exceptions. Initial pause on exceptions state is <code>none</code>.
|
1997 | */
|
1998 | post(method: 'Debugger.setPauseOnExceptions', params?: Debugger.SetPauseOnExceptionsParameterType, callback?: (err: Error | null) => void): void;
|
1999 | post(method: 'Debugger.setPauseOnExceptions', callback?: (err: Error | null) => void): void;
|
2000 | /**
|
2001 | * Evaluates expression on a given call frame.
|
2002 | */
|
2003 | post(method: 'Debugger.evaluateOnCallFrame', params?: Debugger.EvaluateOnCallFrameParameterType, callback?: (err: Error | null, params: Debugger.EvaluateOnCallFrameReturnType) => void): void;
|
2004 | post(method: 'Debugger.evaluateOnCallFrame', callback?: (err: Error | null, params: Debugger.EvaluateOnCallFrameReturnType) => void): void;
|
2005 | /**
|
2006 | * Changes value of variable in a callframe. Object-based scopes are not supported and must be mutated manually.
|
2007 | */
|
2008 | post(method: 'Debugger.setVariableValue', params?: Debugger.SetVariableValueParameterType, callback?: (err: Error | null) => void): void;
|
2009 | post(method: 'Debugger.setVariableValue', callback?: (err: Error | null) => void): void;
|
2010 | /**
|
2011 | * Changes return value in top frame. Available only at return break position.
|
2012 | * @experimental
|
2013 | */
|
2014 | post(method: 'Debugger.setReturnValue', params?: Debugger.SetReturnValueParameterType, callback?: (err: Error | null) => void): void;
|
2015 | post(method: 'Debugger.setReturnValue', callback?: (err: Error | null) => void): void;
|
2016 | /**
|
2017 | * Enables or disables async call stacks tracking.
|
2018 | */
|
2019 | post(method: 'Debugger.setAsyncCallStackDepth', params?: Debugger.SetAsyncCallStackDepthParameterType, callback?: (err: Error | null) => void): void;
|
2020 | post(method: 'Debugger.setAsyncCallStackDepth', callback?: (err: Error | null) => void): void;
|
2021 | /**
|
2022 | * Replace previous blackbox patterns with passed ones. Forces backend to skip stepping/pausing in scripts with url matching one of the patterns. VM will try to leave blackboxed script by performing 'step in' several times, finally resorting to 'step out' if unsuccessful.
|
2023 | * @experimental
|
2024 | */
|
2025 | post(method: 'Debugger.setBlackboxPatterns', params?: Debugger.SetBlackboxPatternsParameterType, callback?: (err: Error | null) => void): void;
|
2026 | post(method: 'Debugger.setBlackboxPatterns', callback?: (err: Error | null) => void): void;
|
2027 | /**
|
2028 | * Makes backend skip steps in the script in blackboxed ranges. VM will try leave blacklisted scripts by performing 'step in' several times, finally resorting to 'step out' if unsuccessful. Positions array contains positions where blackbox state is changed. First interval isn't blackboxed. Array should be sorted.
|
2029 | * @experimental
|
2030 | */
|
2031 | post(method: 'Debugger.setBlackboxedRanges', params?: Debugger.SetBlackboxedRangesParameterType, callback?: (err: Error | null) => void): void;
|
2032 | post(method: 'Debugger.setBlackboxedRanges', callback?: (err: Error | null) => void): void;
|
2033 | /**
|
2034 | * Enables console domain, sends the messages collected so far to the client by means of the <code>messageAdded</code> notification.
|
2035 | */
|
2036 | post(method: 'Console.enable', callback?: (err: Error | null) => void): void;
|
2037 | /**
|
2038 | * Disables console domain, prevents further console messages from being reported to the client.
|
2039 | */
|
2040 | post(method: 'Console.disable', callback?: (err: Error | null) => void): void;
|
2041 | /**
|
2042 | * Does nothing.
|
2043 | */
|
2044 | post(method: 'Console.clearMessages', callback?: (err: Error | null) => void): void;
|
2045 | post(method: 'Profiler.enable', callback?: (err: Error | null) => void): void;
|
2046 | post(method: 'Profiler.disable', callback?: (err: Error | null) => void): void;
|
2047 | /**
|
2048 | * Changes CPU profiler sampling interval. Must be called before CPU profiles recording started.
|
2049 | */
|
2050 | post(method: 'Profiler.setSamplingInterval', params?: Profiler.SetSamplingIntervalParameterType, callback?: (err: Error | null) => void): void;
|
2051 | post(method: 'Profiler.setSamplingInterval', callback?: (err: Error | null) => void): void;
|
2052 | post(method: 'Profiler.start', callback?: (err: Error | null) => void): void;
|
2053 | post(method: 'Profiler.stop', callback?: (err: Error | null, params: Profiler.StopReturnType) => void): void;
|
2054 | /**
|
2055 | * Enable precise code coverage. Coverage data for JavaScript executed before enabling precise code coverage may be incomplete. Enabling prevents running optimized code and resets execution counters.
|
2056 | */
|
2057 | post(method: 'Profiler.startPreciseCoverage', params?: Profiler.StartPreciseCoverageParameterType, callback?: (err: Error | null) => void): void;
|
2058 | post(method: 'Profiler.startPreciseCoverage', callback?: (err: Error | null) => void): void;
|
2059 | /**
|
2060 | * Disable precise code coverage. Disabling releases unnecessary execution count records and allows executing optimized code.
|
2061 | */
|
2062 | post(method: 'Profiler.stopPreciseCoverage', callback?: (err: Error | null) => void): void;
|
2063 | /**
|
2064 | * Collect coverage data for the current isolate, and resets execution counters. Precise code coverage needs to have started.
|
2065 | */
|
2066 | post(method: 'Profiler.takePreciseCoverage', callback?: (err: Error | null, params: Profiler.TakePreciseCoverageReturnType) => void): void;
|
2067 | /**
|
2068 | * Collect coverage data for the current isolate. The coverage data may be incomplete due to garbage collection.
|
2069 | */
|
2070 | post(method: 'Profiler.getBestEffortCoverage', callback?: (err: Error | null, params: Profiler.GetBestEffortCoverageReturnType) => void): void;
|
2071 | /**
|
2072 | * Enable type profile.
|
2073 | * @experimental
|
2074 | */
|
2075 | post(method: 'Profiler.startTypeProfile', callback?: (err: Error | null) => void): void;
|
2076 | /**
|
2077 | * Disable type profile. Disabling releases type profile data collected so far.
|
2078 | * @experimental
|
2079 | */
|
2080 | post(method: 'Profiler.stopTypeProfile', callback?: (err: Error | null) => void): void;
|
2081 | /**
|
2082 | * Collect type profile.
|
2083 | * @experimental
|
2084 | */
|
2085 | post(method: 'Profiler.takeTypeProfile', callback?: (err: Error | null, params: Profiler.TakeTypeProfileReturnType) => void): void;
|
2086 | post(method: 'HeapProfiler.enable', callback?: (err: Error | null) => void): void;
|
2087 | post(method: 'HeapProfiler.disable', callback?: (err: Error | null) => void): void;
|
2088 | post(method: 'HeapProfiler.startTrackingHeapObjects', params?: HeapProfiler.StartTrackingHeapObjectsParameterType, callback?: (err: Error | null) => void): void;
|
2089 | post(method: 'HeapProfiler.startTrackingHeapObjects', callback?: (err: Error | null) => void): void;
|
2090 | post(method: 'HeapProfiler.stopTrackingHeapObjects', params?: HeapProfiler.StopTrackingHeapObjectsParameterType, callback?: (err: Error | null) => void): void;
|
2091 | post(method: 'HeapProfiler.stopTrackingHeapObjects', callback?: (err: Error | null) => void): void;
|
2092 | post(method: 'HeapProfiler.takeHeapSnapshot', params?: HeapProfiler.TakeHeapSnapshotParameterType, callback?: (err: Error | null) => void): void;
|
2093 | post(method: 'HeapProfiler.takeHeapSnapshot', callback?: (err: Error | null) => void): void;
|
2094 | post(method: 'HeapProfiler.collectGarbage', callback?: (err: Error | null) => void): void;
|
2095 | post(
|
2096 | method: 'HeapProfiler.getObjectByHeapObjectId',
|
2097 | params?: HeapProfiler.GetObjectByHeapObjectIdParameterType,
|
2098 | callback?: (err: Error | null, params: HeapProfiler.GetObjectByHeapObjectIdReturnType) => void
|
2099 | ): void;
|
2100 | post(method: 'HeapProfiler.getObjectByHeapObjectId', callback?: (err: Error | null, params: HeapProfiler.GetObjectByHeapObjectIdReturnType) => void): void;
|
2101 | /**
|
2102 | * Enables console to refer to the node with given id via $x (see Command Line API for more details $x functions).
|
2103 | */
|
2104 | post(method: 'HeapProfiler.addInspectedHeapObject', params?: HeapProfiler.AddInspectedHeapObjectParameterType, callback?: (err: Error | null) => void): void;
|
2105 | post(method: 'HeapProfiler.addInspectedHeapObject', callback?: (err: Error | null) => void): void;
|
2106 | post(method: 'HeapProfiler.getHeapObjectId', params?: HeapProfiler.GetHeapObjectIdParameterType, callback?: (err: Error | null, params: HeapProfiler.GetHeapObjectIdReturnType) => void): void;
|
2107 | post(method: 'HeapProfiler.getHeapObjectId', callback?: (err: Error | null, params: HeapProfiler.GetHeapObjectIdReturnType) => void): void;
|
2108 | post(method: 'HeapProfiler.startSampling', params?: HeapProfiler.StartSamplingParameterType, callback?: (err: Error | null) => void): void;
|
2109 | post(method: 'HeapProfiler.startSampling', callback?: (err: Error | null) => void): void;
|
2110 | post(method: 'HeapProfiler.stopSampling', callback?: (err: Error | null, params: HeapProfiler.StopSamplingReturnType) => void): void;
|
2111 | post(method: 'HeapProfiler.getSamplingProfile', callback?: (err: Error | null, params: HeapProfiler.GetSamplingProfileReturnType) => void): void;
|
2112 | /**
|
2113 | * Gets supported tracing categories.
|
2114 | */
|
2115 | post(method: 'NodeTracing.getCategories', callback?: (err: Error | null, params: NodeTracing.GetCategoriesReturnType) => void): void;
|
2116 | /**
|
2117 | * Start trace events collection.
|
2118 | */
|
2119 | post(method: 'NodeTracing.start', params?: NodeTracing.StartParameterType, callback?: (err: Error | null) => void): void;
|
2120 | post(method: 'NodeTracing.start', callback?: (err: Error | null) => void): void;
|
2121 | /**
|
2122 | * Stop trace events collection. Remaining collected events will be sent as a sequence of
|
2123 | * dataCollected events followed by tracingComplete event.
|
2124 | */
|
2125 | post(method: 'NodeTracing.stop', callback?: (err: Error | null) => void): void;
|
2126 | /**
|
2127 | * Sends protocol message over session with given id.
|
2128 | */
|
2129 | post(method: 'NodeWorker.sendMessageToWorker', params?: NodeWorker.SendMessageToWorkerParameterType, callback?: (err: Error | null) => void): void;
|
2130 | post(method: 'NodeWorker.sendMessageToWorker', callback?: (err: Error | null) => void): void;
|
2131 | /**
|
2132 | * Instructs the inspector to attach to running workers. Will also attach to new workers
|
2133 | * as they start
|
2134 | */
|
2135 | post(method: 'NodeWorker.enable', params?: NodeWorker.EnableParameterType, callback?: (err: Error | null) => void): void;
|
2136 | post(method: 'NodeWorker.enable', callback?: (err: Error | null) => void): void;
|
2137 | /**
|
2138 | * Detaches from all running workers and disables attaching to new workers as they are started.
|
2139 | */
|
2140 | post(method: 'NodeWorker.disable', callback?: (err: Error | null) => void): void;
|
2141 | /**
|
2142 | * Detached from the worker with given sessionId.
|
2143 | */
|
2144 | post(method: 'NodeWorker.detach', params?: NodeWorker.DetachParameterType, callback?: (err: Error | null) => void): void;
|
2145 | post(method: 'NodeWorker.detach', callback?: (err: Error | null) => void): void;
|
2146 | /**
|
2147 | * Enable the `NodeRuntime.waitingForDisconnect`.
|
2148 | */
|
2149 | post(method: 'NodeRuntime.notifyWhenWaitingForDisconnect', params?: NodeRuntime.NotifyWhenWaitingForDisconnectParameterType, callback?: (err: Error | null) => void): void;
|
2150 | post(method: 'NodeRuntime.notifyWhenWaitingForDisconnect', callback?: (err: Error | null) => void): void;
|
2151 | // Events
|
2152 | addListener(event: string, listener: (...args: any[]) => void): this;
|
2153 | /**
|
2154 | * Emitted when any notification from the V8 Inspector is received.
|
2155 | */
|
2156 | addListener(event: 'inspectorNotification', listener: (message: InspectorNotification<{}>) => void): this;
|
2157 | /**
|
2158 | * Issued when new execution context is created.
|
2159 | */
|
2160 | addListener(event: 'Runtime.executionContextCreated', listener: (message: InspectorNotification<Runtime.ExecutionContextCreatedEventDataType>) => void): this;
|
2161 | /**
|
2162 | * Issued when execution context is destroyed.
|
2163 | */
|
2164 | addListener(event: 'Runtime.executionContextDestroyed', listener: (message: InspectorNotification<Runtime.ExecutionContextDestroyedEventDataType>) => void): this;
|
2165 | /**
|
2166 | * Issued when all executionContexts were cleared in browser
|
2167 | */
|
2168 | addListener(event: 'Runtime.executionContextsCleared', listener: () => void): this;
|
2169 | /**
|
2170 | * Issued when exception was thrown and unhandled.
|
2171 | */
|
2172 | addListener(event: 'Runtime.exceptionThrown', listener: (message: InspectorNotification<Runtime.ExceptionThrownEventDataType>) => void): this;
|
2173 | /**
|
2174 | * Issued when unhandled exception was revoked.
|
2175 | */
|
2176 | addListener(event: 'Runtime.exceptionRevoked', listener: (message: InspectorNotification<Runtime.ExceptionRevokedEventDataType>) => void): this;
|
2177 | /**
|
2178 | * Issued when console API was called.
|
2179 | */
|
2180 | addListener(event: 'Runtime.consoleAPICalled', listener: (message: InspectorNotification<Runtime.ConsoleAPICalledEventDataType>) => void): this;
|
2181 | /**
|
2182 | * Issued when object should be inspected (for example, as a result of inspect() command line API call).
|
2183 | */
|
2184 | addListener(event: 'Runtime.inspectRequested', listener: (message: InspectorNotification<Runtime.InspectRequestedEventDataType>) => void): this;
|
2185 | /**
|
2186 | * Fired when virtual machine parses script. This event is also fired for all known and uncollected scripts upon enabling debugger.
|
2187 | */
|
2188 | addListener(event: 'Debugger.scriptParsed', listener: (message: InspectorNotification<Debugger.ScriptParsedEventDataType>) => void): this;
|
2189 | /**
|
2190 | * Fired when virtual machine fails to parse the script.
|
2191 | */
|
2192 | addListener(event: 'Debugger.scriptFailedToParse', listener: (message: InspectorNotification<Debugger.ScriptFailedToParseEventDataType>) => void): this;
|
2193 | /**
|
2194 | * Fired when breakpoint is resolved to an actual script and location.
|
2195 | */
|
2196 | addListener(event: 'Debugger.breakpointResolved', listener: (message: InspectorNotification<Debugger.BreakpointResolvedEventDataType>) => void): this;
|
2197 | /**
|
2198 | * Fired when the virtual machine stopped on breakpoint or exception or any other stop criteria.
|
2199 | */
|
2200 | addListener(event: 'Debugger.paused', listener: (message: InspectorNotification<Debugger.PausedEventDataType>) => void): this;
|
2201 | /**
|
2202 | * Fired when the virtual machine resumed execution.
|
2203 | */
|
2204 | addListener(event: 'Debugger.resumed', listener: () => void): this;
|
2205 | /**
|
2206 | * Issued when new console message is added.
|
2207 | */
|
2208 | addListener(event: 'Console.messageAdded', listener: (message: InspectorNotification<Console.MessageAddedEventDataType>) => void): this;
|
2209 | /**
|
2210 | * Sent when new profile recording is started using console.profile() call.
|
2211 | */
|
2212 | addListener(event: 'Profiler.consoleProfileStarted', listener: (message: InspectorNotification<Profiler.ConsoleProfileStartedEventDataType>) => void): this;
|
2213 | addListener(event: 'Profiler.consoleProfileFinished', listener: (message: InspectorNotification<Profiler.ConsoleProfileFinishedEventDataType>) => void): this;
|
2214 | addListener(event: 'HeapProfiler.addHeapSnapshotChunk', listener: (message: InspectorNotification<HeapProfiler.AddHeapSnapshotChunkEventDataType>) => void): this;
|
2215 | addListener(event: 'HeapProfiler.resetProfiles', listener: () => void): this;
|
2216 | addListener(event: 'HeapProfiler.reportHeapSnapshotProgress', listener: (message: InspectorNotification<HeapProfiler.ReportHeapSnapshotProgressEventDataType>) => void): this;
|
2217 | /**
|
2218 | * If heap objects tracking has been started then backend regularly sends a current value for last seen object id and corresponding timestamp. If the were changes in the heap since last event then one or more heapStatsUpdate events will be sent before a new lastSeenObjectId event.
|
2219 | */
|
2220 | addListener(event: 'HeapProfiler.lastSeenObjectId', listener: (message: InspectorNotification<HeapProfiler.LastSeenObjectIdEventDataType>) => void): this;
|
2221 | /**
|
2222 | * If heap objects tracking has been started then backend may send update for one or more fragments
|
2223 | */
|
2224 | addListener(event: 'HeapProfiler.heapStatsUpdate', listener: (message: InspectorNotification<HeapProfiler.HeapStatsUpdateEventDataType>) => void): this;
|
2225 | /**
|
2226 | * Contains an bucket of collected trace events.
|
2227 | */
|
2228 | addListener(event: 'NodeTracing.dataCollected', listener: (message: InspectorNotification<NodeTracing.DataCollectedEventDataType>) => void): this;
|
2229 | /**
|
2230 | * Signals that tracing is stopped and there is no trace buffers pending flush, all data were
|
2231 | * delivered via dataCollected events.
|
2232 | */
|
2233 | addListener(event: 'NodeTracing.tracingComplete', listener: () => void): this;
|
2234 | /**
|
2235 | * Issued when attached to a worker.
|
2236 | */
|
2237 | addListener(event: 'NodeWorker.attachedToWorker', listener: (message: InspectorNotification<NodeWorker.AttachedToWorkerEventDataType>) => void): this;
|
2238 | /**
|
2239 | * Issued when detached from the worker.
|
2240 | */
|
2241 | addListener(event: 'NodeWorker.detachedFromWorker', listener: (message: InspectorNotification<NodeWorker.DetachedFromWorkerEventDataType>) => void): this;
|
2242 | /**
|
2243 | * Notifies about a new protocol message received from the session
|
2244 | * (session ID is provided in attachedToWorker notification).
|
2245 | */
|
2246 | addListener(event: 'NodeWorker.receivedMessageFromWorker', listener: (message: InspectorNotification<NodeWorker.ReceivedMessageFromWorkerEventDataType>) => void): this;
|
2247 | /**
|
2248 | * This event is fired instead of `Runtime.executionContextDestroyed` when
|
2249 | * enabled.
|
2250 | * It is fired when the Node process finished all code execution and is
|
2251 | * waiting for all frontends to disconnect.
|
2252 | */
|
2253 | addListener(event: 'NodeRuntime.waitingForDisconnect', listener: () => void): this;
|
2254 | emit(event: string | symbol, ...args: any[]): boolean;
|
2255 | emit(event: 'inspectorNotification', message: InspectorNotification<{}>): boolean;
|
2256 | emit(event: 'Runtime.executionContextCreated', message: InspectorNotification<Runtime.ExecutionContextCreatedEventDataType>): boolean;
|
2257 | emit(event: 'Runtime.executionContextDestroyed', message: InspectorNotification<Runtime.ExecutionContextDestroyedEventDataType>): boolean;
|
2258 | emit(event: 'Runtime.executionContextsCleared'): boolean;
|
2259 | emit(event: 'Runtime.exceptionThrown', message: InspectorNotification<Runtime.ExceptionThrownEventDataType>): boolean;
|
2260 | emit(event: 'Runtime.exceptionRevoked', message: InspectorNotification<Runtime.ExceptionRevokedEventDataType>): boolean;
|
2261 | emit(event: 'Runtime.consoleAPICalled', message: InspectorNotification<Runtime.ConsoleAPICalledEventDataType>): boolean;
|
2262 | emit(event: 'Runtime.inspectRequested', message: InspectorNotification<Runtime.InspectRequestedEventDataType>): boolean;
|
2263 | emit(event: 'Debugger.scriptParsed', message: InspectorNotification<Debugger.ScriptParsedEventDataType>): boolean;
|
2264 | emit(event: 'Debugger.scriptFailedToParse', message: InspectorNotification<Debugger.ScriptFailedToParseEventDataType>): boolean;
|
2265 | emit(event: 'Debugger.breakpointResolved', message: InspectorNotification<Debugger.BreakpointResolvedEventDataType>): boolean;
|
2266 | emit(event: 'Debugger.paused', message: InspectorNotification<Debugger.PausedEventDataType>): boolean;
|
2267 | emit(event: 'Debugger.resumed'): boolean;
|
2268 | emit(event: 'Console.messageAdded', message: InspectorNotification<Console.MessageAddedEventDataType>): boolean;
|
2269 | emit(event: 'Profiler.consoleProfileStarted', message: InspectorNotification<Profiler.ConsoleProfileStartedEventDataType>): boolean;
|
2270 | emit(event: 'Profiler.consoleProfileFinished', message: InspectorNotification<Profiler.ConsoleProfileFinishedEventDataType>): boolean;
|
2271 | emit(event: 'HeapProfiler.addHeapSnapshotChunk', message: InspectorNotification<HeapProfiler.AddHeapSnapshotChunkEventDataType>): boolean;
|
2272 | emit(event: 'HeapProfiler.resetProfiles'): boolean;
|
2273 | emit(event: 'HeapProfiler.reportHeapSnapshotProgress', message: InspectorNotification<HeapProfiler.ReportHeapSnapshotProgressEventDataType>): boolean;
|
2274 | emit(event: 'HeapProfiler.lastSeenObjectId', message: InspectorNotification<HeapProfiler.LastSeenObjectIdEventDataType>): boolean;
|
2275 | emit(event: 'HeapProfiler.heapStatsUpdate', message: InspectorNotification<HeapProfiler.HeapStatsUpdateEventDataType>): boolean;
|
2276 | emit(event: 'NodeTracing.dataCollected', message: InspectorNotification<NodeTracing.DataCollectedEventDataType>): boolean;
|
2277 | emit(event: 'NodeTracing.tracingComplete'): boolean;
|
2278 | emit(event: 'NodeWorker.attachedToWorker', message: InspectorNotification<NodeWorker.AttachedToWorkerEventDataType>): boolean;
|
2279 | emit(event: 'NodeWorker.detachedFromWorker', message: InspectorNotification<NodeWorker.DetachedFromWorkerEventDataType>): boolean;
|
2280 | emit(event: 'NodeWorker.receivedMessageFromWorker', message: InspectorNotification<NodeWorker.ReceivedMessageFromWorkerEventDataType>): boolean;
|
2281 | emit(event: 'NodeRuntime.waitingForDisconnect'): boolean;
|
2282 | on(event: string, listener: (...args: any[]) => void): this;
|
2283 | /**
|
2284 | * Emitted when any notification from the V8 Inspector is received.
|
2285 | */
|
2286 | on(event: 'inspectorNotification', listener: (message: InspectorNotification<{}>) => void): this;
|
2287 | /**
|
2288 | * Issued when new execution context is created.
|
2289 | */
|
2290 | on(event: 'Runtime.executionContextCreated', listener: (message: InspectorNotification<Runtime.ExecutionContextCreatedEventDataType>) => void): this;
|
2291 | /**
|
2292 | * Issued when execution context is destroyed.
|
2293 | */
|
2294 | on(event: 'Runtime.executionContextDestroyed', listener: (message: InspectorNotification<Runtime.ExecutionContextDestroyedEventDataType>) => void): this;
|
2295 | /**
|
2296 | * Issued when all executionContexts were cleared in browser
|
2297 | */
|
2298 | on(event: 'Runtime.executionContextsCleared', listener: () => void): this;
|
2299 | /**
|
2300 | * Issued when exception was thrown and unhandled.
|
2301 | */
|
2302 | on(event: 'Runtime.exceptionThrown', listener: (message: InspectorNotification<Runtime.ExceptionThrownEventDataType>) => void): this;
|
2303 | /**
|
2304 | * Issued when unhandled exception was revoked.
|
2305 | */
|
2306 | on(event: 'Runtime.exceptionRevoked', listener: (message: InspectorNotification<Runtime.ExceptionRevokedEventDataType>) => void): this;
|
2307 | /**
|
2308 | * Issued when console API was called.
|
2309 | */
|
2310 | on(event: 'Runtime.consoleAPICalled', listener: (message: InspectorNotification<Runtime.ConsoleAPICalledEventDataType>) => void): this;
|
2311 | /**
|
2312 | * Issued when object should be inspected (for example, as a result of inspect() command line API call).
|
2313 | */
|
2314 | on(event: 'Runtime.inspectRequested', listener: (message: InspectorNotification<Runtime.InspectRequestedEventDataType>) => void): this;
|
2315 | /**
|
2316 | * Fired when virtual machine parses script. This event is also fired for all known and uncollected scripts upon enabling debugger.
|
2317 | */
|
2318 | on(event: 'Debugger.scriptParsed', listener: (message: InspectorNotification<Debugger.ScriptParsedEventDataType>) => void): this;
|
2319 | /**
|
2320 | * Fired when virtual machine fails to parse the script.
|
2321 | */
|
2322 | on(event: 'Debugger.scriptFailedToParse', listener: (message: InspectorNotification<Debugger.ScriptFailedToParseEventDataType>) => void): this;
|
2323 | /**
|
2324 | * Fired when breakpoint is resolved to an actual script and location.
|
2325 | */
|
2326 | on(event: 'Debugger.breakpointResolved', listener: (message: InspectorNotification<Debugger.BreakpointResolvedEventDataType>) => void): this;
|
2327 | /**
|
2328 | * Fired when the virtual machine stopped on breakpoint or exception or any other stop criteria.
|
2329 | */
|
2330 | on(event: 'Debugger.paused', listener: (message: InspectorNotification<Debugger.PausedEventDataType>) => void): this;
|
2331 | /**
|
2332 | * Fired when the virtual machine resumed execution.
|
2333 | */
|
2334 | on(event: 'Debugger.resumed', listener: () => void): this;
|
2335 | /**
|
2336 | * Issued when new console message is added.
|
2337 | */
|
2338 | on(event: 'Console.messageAdded', listener: (message: InspectorNotification<Console.MessageAddedEventDataType>) => void): this;
|
2339 | /**
|
2340 | * Sent when new profile recording is started using console.profile() call.
|
2341 | */
|
2342 | on(event: 'Profiler.consoleProfileStarted', listener: (message: InspectorNotification<Profiler.ConsoleProfileStartedEventDataType>) => void): this;
|
2343 | on(event: 'Profiler.consoleProfileFinished', listener: (message: InspectorNotification<Profiler.ConsoleProfileFinishedEventDataType>) => void): this;
|
2344 | on(event: 'HeapProfiler.addHeapSnapshotChunk', listener: (message: InspectorNotification<HeapProfiler.AddHeapSnapshotChunkEventDataType>) => void): this;
|
2345 | on(event: 'HeapProfiler.resetProfiles', listener: () => void): this;
|
2346 | on(event: 'HeapProfiler.reportHeapSnapshotProgress', listener: (message: InspectorNotification<HeapProfiler.ReportHeapSnapshotProgressEventDataType>) => void): this;
|
2347 | /**
|
2348 | * If heap objects tracking has been started then backend regularly sends a current value for last seen object id and corresponding timestamp. If the were changes in the heap since last event then one or more heapStatsUpdate events will be sent before a new lastSeenObjectId event.
|
2349 | */
|
2350 | on(event: 'HeapProfiler.lastSeenObjectId', listener: (message: InspectorNotification<HeapProfiler.LastSeenObjectIdEventDataType>) => void): this;
|
2351 | /**
|
2352 | * If heap objects tracking has been started then backend may send update for one or more fragments
|
2353 | */
|
2354 | on(event: 'HeapProfiler.heapStatsUpdate', listener: (message: InspectorNotification<HeapProfiler.HeapStatsUpdateEventDataType>) => void): this;
|
2355 | /**
|
2356 | * Contains an bucket of collected trace events.
|
2357 | */
|
2358 | on(event: 'NodeTracing.dataCollected', listener: (message: InspectorNotification<NodeTracing.DataCollectedEventDataType>) => void): this;
|
2359 | /**
|
2360 | * Signals that tracing is stopped and there is no trace buffers pending flush, all data were
|
2361 | * delivered via dataCollected events.
|
2362 | */
|
2363 | on(event: 'NodeTracing.tracingComplete', listener: () => void): this;
|
2364 | /**
|
2365 | * Issued when attached to a worker.
|
2366 | */
|
2367 | on(event: 'NodeWorker.attachedToWorker', listener: (message: InspectorNotification<NodeWorker.AttachedToWorkerEventDataType>) => void): this;
|
2368 | /**
|
2369 | * Issued when detached from the worker.
|
2370 | */
|
2371 | on(event: 'NodeWorker.detachedFromWorker', listener: (message: InspectorNotification<NodeWorker.DetachedFromWorkerEventDataType>) => void): this;
|
2372 | /**
|
2373 | * Notifies about a new protocol message received from the session
|
2374 | * (session ID is provided in attachedToWorker notification).
|
2375 | */
|
2376 | on(event: 'NodeWorker.receivedMessageFromWorker', listener: (message: InspectorNotification<NodeWorker.ReceivedMessageFromWorkerEventDataType>) => void): this;
|
2377 | /**
|
2378 | * This event is fired instead of `Runtime.executionContextDestroyed` when
|
2379 | * enabled.
|
2380 | * It is fired when the Node process finished all code execution and is
|
2381 | * waiting for all frontends to disconnect.
|
2382 | */
|
2383 | on(event: 'NodeRuntime.waitingForDisconnect', listener: () => void): this;
|
2384 | once(event: string, listener: (...args: any[]) => void): this;
|
2385 | /**
|
2386 | * Emitted when any notification from the V8 Inspector is received.
|
2387 | */
|
2388 | once(event: 'inspectorNotification', listener: (message: InspectorNotification<{}>) => void): this;
|
2389 | /**
|
2390 | * Issued when new execution context is created.
|
2391 | */
|
2392 | once(event: 'Runtime.executionContextCreated', listener: (message: InspectorNotification<Runtime.ExecutionContextCreatedEventDataType>) => void): this;
|
2393 | /**
|
2394 | * Issued when execution context is destroyed.
|
2395 | */
|
2396 | once(event: 'Runtime.executionContextDestroyed', listener: (message: InspectorNotification<Runtime.ExecutionContextDestroyedEventDataType>) => void): this;
|
2397 | /**
|
2398 | * Issued when all executionContexts were cleared in browser
|
2399 | */
|
2400 | once(event: 'Runtime.executionContextsCleared', listener: () => void): this;
|
2401 | /**
|
2402 | * Issued when exception was thrown and unhandled.
|
2403 | */
|
2404 | once(event: 'Runtime.exceptionThrown', listener: (message: InspectorNotification<Runtime.ExceptionThrownEventDataType>) => void): this;
|
2405 | /**
|
2406 | * Issued when unhandled exception was revoked.
|
2407 | */
|
2408 | once(event: 'Runtime.exceptionRevoked', listener: (message: InspectorNotification<Runtime.ExceptionRevokedEventDataType>) => void): this;
|
2409 | /**
|
2410 | * Issued when console API was called.
|
2411 | */
|
2412 | once(event: 'Runtime.consoleAPICalled', listener: (message: InspectorNotification<Runtime.ConsoleAPICalledEventDataType>) => void): this;
|
2413 | /**
|
2414 | * Issued when object should be inspected (for example, as a result of inspect() command line API call).
|
2415 | */
|
2416 | once(event: 'Runtime.inspectRequested', listener: (message: InspectorNotification<Runtime.InspectRequestedEventDataType>) => void): this;
|
2417 | /**
|
2418 | * Fired when virtual machine parses script. This event is also fired for all known and uncollected scripts upon enabling debugger.
|
2419 | */
|
2420 | once(event: 'Debugger.scriptParsed', listener: (message: InspectorNotification<Debugger.ScriptParsedEventDataType>) => void): this;
|
2421 | /**
|
2422 | * Fired when virtual machine fails to parse the script.
|
2423 | */
|
2424 | once(event: 'Debugger.scriptFailedToParse', listener: (message: InspectorNotification<Debugger.ScriptFailedToParseEventDataType>) => void): this;
|
2425 | /**
|
2426 | * Fired when breakpoint is resolved to an actual script and location.
|
2427 | */
|
2428 | once(event: 'Debugger.breakpointResolved', listener: (message: InspectorNotification<Debugger.BreakpointResolvedEventDataType>) => void): this;
|
2429 | /**
|
2430 | * Fired when the virtual machine stopped on breakpoint or exception or any other stop criteria.
|
2431 | */
|
2432 | once(event: 'Debugger.paused', listener: (message: InspectorNotification<Debugger.PausedEventDataType>) => void): this;
|
2433 | /**
|
2434 | * Fired when the virtual machine resumed execution.
|
2435 | */
|
2436 | once(event: 'Debugger.resumed', listener: () => void): this;
|
2437 | /**
|
2438 | * Issued when new console message is added.
|
2439 | */
|
2440 | once(event: 'Console.messageAdded', listener: (message: InspectorNotification<Console.MessageAddedEventDataType>) => void): this;
|
2441 | /**
|
2442 | * Sent when new profile recording is started using console.profile() call.
|
2443 | */
|
2444 | once(event: 'Profiler.consoleProfileStarted', listener: (message: InspectorNotification<Profiler.ConsoleProfileStartedEventDataType>) => void): this;
|
2445 | once(event: 'Profiler.consoleProfileFinished', listener: (message: InspectorNotification<Profiler.ConsoleProfileFinishedEventDataType>) => void): this;
|
2446 | once(event: 'HeapProfiler.addHeapSnapshotChunk', listener: (message: InspectorNotification<HeapProfiler.AddHeapSnapshotChunkEventDataType>) => void): this;
|
2447 | once(event: 'HeapProfiler.resetProfiles', listener: () => void): this;
|
2448 | once(event: 'HeapProfiler.reportHeapSnapshotProgress', listener: (message: InspectorNotification<HeapProfiler.ReportHeapSnapshotProgressEventDataType>) => void): this;
|
2449 | /**
|
2450 | * If heap objects tracking has been started then backend regularly sends a current value for last seen object id and corresponding timestamp. If the were changes in the heap since last event then one or more heapStatsUpdate events will be sent before a new lastSeenObjectId event.
|
2451 | */
|
2452 | once(event: 'HeapProfiler.lastSeenObjectId', listener: (message: InspectorNotification<HeapProfiler.LastSeenObjectIdEventDataType>) => void): this;
|
2453 | /**
|
2454 | * If heap objects tracking has been started then backend may send update for one or more fragments
|
2455 | */
|
2456 | once(event: 'HeapProfiler.heapStatsUpdate', listener: (message: InspectorNotification<HeapProfiler.HeapStatsUpdateEventDataType>) => void): this;
|
2457 | /**
|
2458 | * Contains an bucket of collected trace events.
|
2459 | */
|
2460 | once(event: 'NodeTracing.dataCollected', listener: (message: InspectorNotification<NodeTracing.DataCollectedEventDataType>) => void): this;
|
2461 | /**
|
2462 | * Signals that tracing is stopped and there is no trace buffers pending flush, all data were
|
2463 | * delivered via dataCollected events.
|
2464 | */
|
2465 | once(event: 'NodeTracing.tracingComplete', listener: () => void): this;
|
2466 | /**
|
2467 | * Issued when attached to a worker.
|
2468 | */
|
2469 | once(event: 'NodeWorker.attachedToWorker', listener: (message: InspectorNotification<NodeWorker.AttachedToWorkerEventDataType>) => void): this;
|
2470 | /**
|
2471 | * Issued when detached from the worker.
|
2472 | */
|
2473 | once(event: 'NodeWorker.detachedFromWorker', listener: (message: InspectorNotification<NodeWorker.DetachedFromWorkerEventDataType>) => void): this;
|
2474 | /**
|
2475 | * Notifies about a new protocol message received from the session
|
2476 | * (session ID is provided in attachedToWorker notification).
|
2477 | */
|
2478 | once(event: 'NodeWorker.receivedMessageFromWorker', listener: (message: InspectorNotification<NodeWorker.ReceivedMessageFromWorkerEventDataType>) => void): this;
|
2479 | /**
|
2480 | * This event is fired instead of `Runtime.executionContextDestroyed` when
|
2481 | * enabled.
|
2482 | * It is fired when the Node process finished all code execution and is
|
2483 | * waiting for all frontends to disconnect.
|
2484 | */
|
2485 | once(event: 'NodeRuntime.waitingForDisconnect', listener: () => void): this;
|
2486 | prependListener(event: string, listener: (...args: any[]) => void): this;
|
2487 | /**
|
2488 | * Emitted when any notification from the V8 Inspector is received.
|
2489 | */
|
2490 | prependListener(event: 'inspectorNotification', listener: (message: InspectorNotification<{}>) => void): this;
|
2491 | /**
|
2492 | * Issued when new execution context is created.
|
2493 | */
|
2494 | prependListener(event: 'Runtime.executionContextCreated', listener: (message: InspectorNotification<Runtime.ExecutionContextCreatedEventDataType>) => void): this;
|
2495 | /**
|
2496 | * Issued when execution context is destroyed.
|
2497 | */
|
2498 | prependListener(event: 'Runtime.executionContextDestroyed', listener: (message: InspectorNotification<Runtime.ExecutionContextDestroyedEventDataType>) => void): this;
|
2499 | /**
|
2500 | * Issued when all executionContexts were cleared in browser
|
2501 | */
|
2502 | prependListener(event: 'Runtime.executionContextsCleared', listener: () => void): this;
|
2503 | /**
|
2504 | * Issued when exception was thrown and unhandled.
|
2505 | */
|
2506 | prependListener(event: 'Runtime.exceptionThrown', listener: (message: InspectorNotification<Runtime.ExceptionThrownEventDataType>) => void): this;
|
2507 | /**
|
2508 | * Issued when unhandled exception was revoked.
|
2509 | */
|
2510 | prependListener(event: 'Runtime.exceptionRevoked', listener: (message: InspectorNotification<Runtime.ExceptionRevokedEventDataType>) => void): this;
|
2511 | /**
|
2512 | * Issued when console API was called.
|
2513 | */
|
2514 | prependListener(event: 'Runtime.consoleAPICalled', listener: (message: InspectorNotification<Runtime.ConsoleAPICalledEventDataType>) => void): this;
|
2515 | /**
|
2516 | * Issued when object should be inspected (for example, as a result of inspect() command line API call).
|
2517 | */
|
2518 | prependListener(event: 'Runtime.inspectRequested', listener: (message: InspectorNotification<Runtime.InspectRequestedEventDataType>) => void): this;
|
2519 | /**
|
2520 | * Fired when virtual machine parses script. This event is also fired for all known and uncollected scripts upon enabling debugger.
|
2521 | */
|
2522 | prependListener(event: 'Debugger.scriptParsed', listener: (message: InspectorNotification<Debugger.ScriptParsedEventDataType>) => void): this;
|
2523 | /**
|
2524 | * Fired when virtual machine fails to parse the script.
|
2525 | */
|
2526 | prependListener(event: 'Debugger.scriptFailedToParse', listener: (message: InspectorNotification<Debugger.ScriptFailedToParseEventDataType>) => void): this;
|
2527 | /**
|
2528 | * Fired when breakpoint is resolved to an actual script and location.
|
2529 | */
|
2530 | prependListener(event: 'Debugger.breakpointResolved', listener: (message: InspectorNotification<Debugger.BreakpointResolvedEventDataType>) => void): this;
|
2531 | /**
|
2532 | * Fired when the virtual machine stopped on breakpoint or exception or any other stop criteria.
|
2533 | */
|
2534 | prependListener(event: 'Debugger.paused', listener: (message: InspectorNotification<Debugger.PausedEventDataType>) => void): this;
|
2535 | /**
|
2536 | * Fired when the virtual machine resumed execution.
|
2537 | */
|
2538 | prependListener(event: 'Debugger.resumed', listener: () => void): this;
|
2539 | /**
|
2540 | * Issued when new console message is added.
|
2541 | */
|
2542 | prependListener(event: 'Console.messageAdded', listener: (message: InspectorNotification<Console.MessageAddedEventDataType>) => void): this;
|
2543 | /**
|
2544 | * Sent when new profile recording is started using console.profile() call.
|
2545 | */
|
2546 | prependListener(event: 'Profiler.consoleProfileStarted', listener: (message: InspectorNotification<Profiler.ConsoleProfileStartedEventDataType>) => void): this;
|
2547 | prependListener(event: 'Profiler.consoleProfileFinished', listener: (message: InspectorNotification<Profiler.ConsoleProfileFinishedEventDataType>) => void): this;
|
2548 | prependListener(event: 'HeapProfiler.addHeapSnapshotChunk', listener: (message: InspectorNotification<HeapProfiler.AddHeapSnapshotChunkEventDataType>) => void): this;
|
2549 | prependListener(event: 'HeapProfiler.resetProfiles', listener: () => void): this;
|
2550 | prependListener(event: 'HeapProfiler.reportHeapSnapshotProgress', listener: (message: InspectorNotification<HeapProfiler.ReportHeapSnapshotProgressEventDataType>) => void): this;
|
2551 | /**
|
2552 | * If heap objects tracking has been started then backend regularly sends a current value for last seen object id and corresponding timestamp. If the were changes in the heap since last event then one or more heapStatsUpdate events will be sent before a new lastSeenObjectId event.
|
2553 | */
|
2554 | prependListener(event: 'HeapProfiler.lastSeenObjectId', listener: (message: InspectorNotification<HeapProfiler.LastSeenObjectIdEventDataType>) => void): this;
|
2555 | /**
|
2556 | * If heap objects tracking has been started then backend may send update for one or more fragments
|
2557 | */
|
2558 | prependListener(event: 'HeapProfiler.heapStatsUpdate', listener: (message: InspectorNotification<HeapProfiler.HeapStatsUpdateEventDataType>) => void): this;
|
2559 | /**
|
2560 | * Contains an bucket of collected trace events.
|
2561 | */
|
2562 | prependListener(event: 'NodeTracing.dataCollected', listener: (message: InspectorNotification<NodeTracing.DataCollectedEventDataType>) => void): this;
|
2563 | /**
|
2564 | * Signals that tracing is stopped and there is no trace buffers pending flush, all data were
|
2565 | * delivered via dataCollected events.
|
2566 | */
|
2567 | prependListener(event: 'NodeTracing.tracingComplete', listener: () => void): this;
|
2568 | /**
|
2569 | * Issued when attached to a worker.
|
2570 | */
|
2571 | prependListener(event: 'NodeWorker.attachedToWorker', listener: (message: InspectorNotification<NodeWorker.AttachedToWorkerEventDataType>) => void): this;
|
2572 | /**
|
2573 | * Issued when detached from the worker.
|
2574 | */
|
2575 | prependListener(event: 'NodeWorker.detachedFromWorker', listener: (message: InspectorNotification<NodeWorker.DetachedFromWorkerEventDataType>) => void): this;
|
2576 | /**
|
2577 | * Notifies about a new protocol message received from the session
|
2578 | * (session ID is provided in attachedToWorker notification).
|
2579 | */
|
2580 | prependListener(event: 'NodeWorker.receivedMessageFromWorker', listener: (message: InspectorNotification<NodeWorker.ReceivedMessageFromWorkerEventDataType>) => void): this;
|
2581 | /**
|
2582 | * This event is fired instead of `Runtime.executionContextDestroyed` when
|
2583 | * enabled.
|
2584 | * It is fired when the Node process finished all code execution and is
|
2585 | * waiting for all frontends to disconnect.
|
2586 | */
|
2587 | prependListener(event: 'NodeRuntime.waitingForDisconnect', listener: () => void): this;
|
2588 | prependOnceListener(event: string, listener: (...args: any[]) => void): this;
|
2589 | /**
|
2590 | * Emitted when any notification from the V8 Inspector is received.
|
2591 | */
|
2592 | prependOnceListener(event: 'inspectorNotification', listener: (message: InspectorNotification<{}>) => void): this;
|
2593 | /**
|
2594 | * Issued when new execution context is created.
|
2595 | */
|
2596 | prependOnceListener(event: 'Runtime.executionContextCreated', listener: (message: InspectorNotification<Runtime.ExecutionContextCreatedEventDataType>) => void): this;
|
2597 | /**
|
2598 | * Issued when execution context is destroyed.
|
2599 | */
|
2600 | prependOnceListener(event: 'Runtime.executionContextDestroyed', listener: (message: InspectorNotification<Runtime.ExecutionContextDestroyedEventDataType>) => void): this;
|
2601 | /**
|
2602 | * Issued when all executionContexts were cleared in browser
|
2603 | */
|
2604 | prependOnceListener(event: 'Runtime.executionContextsCleared', listener: () => void): this;
|
2605 | /**
|
2606 | * Issued when exception was thrown and unhandled.
|
2607 | */
|
2608 | prependOnceListener(event: 'Runtime.exceptionThrown', listener: (message: InspectorNotification<Runtime.ExceptionThrownEventDataType>) => void): this;
|
2609 | /**
|
2610 | * Issued when unhandled exception was revoked.
|
2611 | */
|
2612 | prependOnceListener(event: 'Runtime.exceptionRevoked', listener: (message: InspectorNotification<Runtime.ExceptionRevokedEventDataType>) => void): this;
|
2613 | /**
|
2614 | * Issued when console API was called.
|
2615 | */
|
2616 | prependOnceListener(event: 'Runtime.consoleAPICalled', listener: (message: InspectorNotification<Runtime.ConsoleAPICalledEventDataType>) => void): this;
|
2617 | /**
|
2618 | * Issued when object should be inspected (for example, as a result of inspect() command line API call).
|
2619 | */
|
2620 | prependOnceListener(event: 'Runtime.inspectRequested', listener: (message: InspectorNotification<Runtime.InspectRequestedEventDataType>) => void): this;
|
2621 | /**
|
2622 | * Fired when virtual machine parses script. This event is also fired for all known and uncollected scripts upon enabling debugger.
|
2623 | */
|
2624 | prependOnceListener(event: 'Debugger.scriptParsed', listener: (message: InspectorNotification<Debugger.ScriptParsedEventDataType>) => void): this;
|
2625 | /**
|
2626 | * Fired when virtual machine fails to parse the script.
|
2627 | */
|
2628 | prependOnceListener(event: 'Debugger.scriptFailedToParse', listener: (message: InspectorNotification<Debugger.ScriptFailedToParseEventDataType>) => void): this;
|
2629 | /**
|
2630 | * Fired when breakpoint is resolved to an actual script and location.
|
2631 | */
|
2632 | prependOnceListener(event: 'Debugger.breakpointResolved', listener: (message: InspectorNotification<Debugger.BreakpointResolvedEventDataType>) => void): this;
|
2633 | /**
|
2634 | * Fired when the virtual machine stopped on breakpoint or exception or any other stop criteria.
|
2635 | */
|
2636 | prependOnceListener(event: 'Debugger.paused', listener: (message: InspectorNotification<Debugger.PausedEventDataType>) => void): this;
|
2637 | /**
|
2638 | * Fired when the virtual machine resumed execution.
|
2639 | */
|
2640 | prependOnceListener(event: 'Debugger.resumed', listener: () => void): this;
|
2641 | /**
|
2642 | * Issued when new console message is added.
|
2643 | */
|
2644 | prependOnceListener(event: 'Console.messageAdded', listener: (message: InspectorNotification<Console.MessageAddedEventDataType>) => void): this;
|
2645 | /**
|
2646 | * Sent when new profile recording is started using console.profile() call.
|
2647 | */
|
2648 | prependOnceListener(event: 'Profiler.consoleProfileStarted', listener: (message: InspectorNotification<Profiler.ConsoleProfileStartedEventDataType>) => void): this;
|
2649 | prependOnceListener(event: 'Profiler.consoleProfileFinished', listener: (message: InspectorNotification<Profiler.ConsoleProfileFinishedEventDataType>) => void): this;
|
2650 | prependOnceListener(event: 'HeapProfiler.addHeapSnapshotChunk', listener: (message: InspectorNotification<HeapProfiler.AddHeapSnapshotChunkEventDataType>) => void): this;
|
2651 | prependOnceListener(event: 'HeapProfiler.resetProfiles', listener: () => void): this;
|
2652 | prependOnceListener(event: 'HeapProfiler.reportHeapSnapshotProgress', listener: (message: InspectorNotification<HeapProfiler.ReportHeapSnapshotProgressEventDataType>) => void): this;
|
2653 | /**
|
2654 | * If heap objects tracking has been started then backend regularly sends a current value for last seen object id and corresponding timestamp. If the were changes in the heap since last event then one or more heapStatsUpdate events will be sent before a new lastSeenObjectId event.
|
2655 | */
|
2656 | prependOnceListener(event: 'HeapProfiler.lastSeenObjectId', listener: (message: InspectorNotification<HeapProfiler.LastSeenObjectIdEventDataType>) => void): this;
|
2657 | /**
|
2658 | * If heap objects tracking has been started then backend may send update for one or more fragments
|
2659 | */
|
2660 | prependOnceListener(event: 'HeapProfiler.heapStatsUpdate', listener: (message: InspectorNotification<HeapProfiler.HeapStatsUpdateEventDataType>) => void): this;
|
2661 | /**
|
2662 | * Contains an bucket of collected trace events.
|
2663 | */
|
2664 | prependOnceListener(event: 'NodeTracing.dataCollected', listener: (message: InspectorNotification<NodeTracing.DataCollectedEventDataType>) => void): this;
|
2665 | /**
|
2666 | * Signals that tracing is stopped and there is no trace buffers pending flush, all data were
|
2667 | * delivered via dataCollected events.
|
2668 | */
|
2669 | prependOnceListener(event: 'NodeTracing.tracingComplete', listener: () => void): this;
|
2670 | /**
|
2671 | * Issued when attached to a worker.
|
2672 | */
|
2673 | prependOnceListener(event: 'NodeWorker.attachedToWorker', listener: (message: InspectorNotification<NodeWorker.AttachedToWorkerEventDataType>) => void): this;
|
2674 | /**
|
2675 | * Issued when detached from the worker.
|
2676 | */
|
2677 | prependOnceListener(event: 'NodeWorker.detachedFromWorker', listener: (message: InspectorNotification<NodeWorker.DetachedFromWorkerEventDataType>) => void): this;
|
2678 | /**
|
2679 | * Notifies about a new protocol message received from the session
|
2680 | * (session ID is provided in attachedToWorker notification).
|
2681 | */
|
2682 | prependOnceListener(event: 'NodeWorker.receivedMessageFromWorker', listener: (message: InspectorNotification<NodeWorker.ReceivedMessageFromWorkerEventDataType>) => void): this;
|
2683 | /**
|
2684 | * This event is fired instead of `Runtime.executionContextDestroyed` when
|
2685 | * enabled.
|
2686 | * It is fired when the Node process finished all code execution and is
|
2687 | * waiting for all frontends to disconnect.
|
2688 | */
|
2689 | prependOnceListener(event: 'NodeRuntime.waitingForDisconnect', listener: () => void): this;
|
2690 | }
|
2691 | /**
|
2692 | * Activate inspector on host and port. Equivalent to `node --inspect=[[host:]port]`, but can be done programmatically after node has
|
2693 | * started.
|
2694 | *
|
2695 | * If wait is `true`, will block until a client has connected to the inspect port
|
2696 | * and flow control has been passed to the debugger client.
|
2697 | *
|
2698 | * See the `security warning` regarding the `host`parameter usage.
|
2699 | * @param [port='what was specified on the CLI'] Port to listen on for inspector connections. Optional.
|
2700 | * @param [host='what was specified on the CLI'] Host to listen on for inspector connections. Optional.
|
2701 | * @param [wait=false] Block until a client has connected. Optional.
|
2702 | */
|
2703 | function open(port?: number, host?: string, wait?: boolean): void;
|
2704 | /**
|
2705 | * Deactivate the inspector. Blocks until there are no active connections.
|
2706 | */
|
2707 | function close(): void;
|
2708 | /**
|
2709 | * Return the URL of the active inspector, or `undefined` if there is none.
|
2710 | *
|
2711 | * ```console
|
2712 | * $ node --inspect -p 'inspector.url()'
|
2713 | * Debugger listening on ws:
|
2714 | * For help see https:
|
2715 | * ws:
|
2716 | *
|
2717 | * $ node --inspect=localhost:3000 -p 'inspector.url()'
|
2718 | * Debugger listening on ws:
|
2719 | * For help see https:
|
2720 | * ws:
|
2721 | *
|
2722 | * $ node -p 'inspector.url()'
|
2723 | * undefined
|
2724 | * ```
|
2725 | */
|
2726 | function url(): string | undefined;
|
2727 | /**
|
2728 | * Blocks until a client (existing or connected later) has sent`Runtime.runIfWaitingForDebugger` command.
|
2729 | *
|
2730 | * An exception will be thrown if there is no active inspector.
|
2731 | * @since v12.7.0
|
2732 | */
|
2733 | function waitForDebugger(): void;
|
2734 | }
|
2735 | declare module 'node:inspector' {
|
2736 | import EventEmitter = require('inspector');
|
2737 | export = EventEmitter;
|
2738 | }
|
2739 |
|
\ | No newline at end of file |