LeviLamina
Loading...
Searching...
No Matches
Debugger.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/deps/scripting/runtime/IDebuggerController.h"
7
8// auto generated forward declare list
9// clang-format off
10struct JSContext;
11struct JSRuntime;
12struct JSValue;
13namespace Scripting { class IBreakpointValidator; }
14namespace Scripting { class IDebuggerTransport; }
15// clang-format on
16
17namespace Scripting::QuickJS {
18
19class Debugger : public ::Scripting::IDebuggerController {
20public:
21 // member variables
22 // NOLINTBEGIN
29 // NOLINTEND
30
31public:
32 // prevent constructor by default
33 Debugger& operator=(Debugger const&);
34 Debugger(Debugger const&);
35 Debugger();
36
37public:
38 // virtual functions
39 // NOLINTBEGIN
40 virtual ~Debugger() /*override*/;
41
42 virtual bool attach(
43 bool performHandshake,
44 ::std::optional<::std::string> targetModuleUuid,
45 ::std::function<void(::std::string_view)> handler
46 ) /*override*/;
47
48 virtual void detach() /*override*/;
49
50 virtual bool closed() const /*override*/;
51
52 virtual void pumpMessages() /*override*/;
53 // NOLINTEND
54
55public:
56 // member functions
57 // NOLINTBEGIN
58 MCNAPI Debugger(
60 ::JSRuntime* rt,
61 ::std::function<void()> resumeNotificationCb,
62 ::std::function<::std::vector<::JSContext*>()> collectContextsCb,
64 );
65 // NOLINTEND
66
67public:
68 // static functions
69 // NOLINTBEGIN
70 MCNAPI static uint ContextToId(::JSContext* ctx, void*);
71
72 MCNAPI static char const* ContextToModuleUuidLowerCase(::JSContext* ctx, void*);
73
74 MCNAPI static void MessageHandler(void* udata, char const* message, uint64 length);
75
76 MCNAPI static void NotifyResume(void* udata);
77
78 MCNAPI static char const* ToTypeName(::JSContext* ctx, ::JSValue val);
79
80 MCNAPI static void TransportClose(::JSRuntime* udata, void*);
81
82 MCNAPI static uint64 TransportPeek(void* udata);
83
84 MCNAPI static uint64 TransportRead(void* udata, char* buffer, uint64 length);
85
86 MCNAPI static uint64 TransportWrite(void* udata, char const* buffer, uint64 length);
87
88 MCNAPI static int ValidatePath(void* udata, char const* path);
89 // NOLINTEND
90
91public:
92 // constructor thunks
93 // NOLINTBEGIN
94 MCNAPI void* $ctor(
96 ::JSRuntime* rt,
97 ::std::function<void()> resumeNotificationCb,
98 ::std::function<::std::vector<::JSContext*>()> collectContextsCb,
100 );
101 // NOLINTEND
102
103public:
104 // destructor thunk
105 // NOLINTBEGIN
106 MCNAPI void $dtor();
107 // NOLINTEND
108
109public:
110 // virtual function thunks
111 // NOLINTBEGIN
112 MCNAPI bool $attach(
113 bool performHandshake,
114 ::std::optional<::std::string> targetModuleUuid,
115 ::std::function<void(::std::string_view)> handler
116 );
117
118 MCNAPI void $detach();
119
120 MCNAPI bool $closed() const;
121
122 MCNAPI void $pumpMessages();
123
124
125 // NOLINTEND
126
127public:
128 // vftables
129 // NOLINTBEGIN
130 MCNAPI static void** $vftable();
131 // NOLINTEND
132};
133
134} // namespace Scripting::QuickJS
Definition IBreakpointValidator.h:7
Definition IDebuggerController.h:7
Definition IDebuggerTransport.h:7
MCAPI void * $ctor(::Scripting::IDebuggerTransport &transport, ::JSRuntime *rt, ::std::function< void()> resumeNotificationCb, ::std::function<::std::vector<::JSContext * >()> collectContextsCb, ::Scripting::IBreakpointValidator &validator)
static MCAPI void MessageHandler(void *udata, char const *message, uint64 length)
MCAPI bool $closed() const
static MCAPI char const * ToTypeName(::JSContext *ctx, ::JSValue val)
static MCAPI int ValidatePath(void *udata, char const *path)
static MCAPI void NotifyResume(void *udata)
static MCAPI char const * ContextToModuleUuidLowerCase(::JSContext *ctx, void *)
static MCAPI uint64 TransportPeek(void *udata)
MCAPI bool $attach(bool performHandshake, ::std::optional<::std::string > targetModuleUuid, ::std::function< void(::std::string_view)> handler)
static MCAPI void TransportClose(::JSRuntime *udata, void *)
static MCAPI void ** $vftable()
static MCAPI uint ContextToId(::JSContext *ctx, void *)
static MCAPI uint64 TransportRead(void *udata, char *buffer, uint64 length)
MCAPI Debugger(::Scripting::IDebuggerTransport &transport, ::JSRuntime *rt, ::std::function< void()> resumeNotificationCb, ::std::function<::std::vector<::JSContext * >()> collectContextsCb, ::Scripting::IBreakpointValidator &validator)
static MCAPI uint64 TransportWrite(void *udata, char const *buffer, uint64 length)
Definition JSContext.h:5
Definition JSRuntime.h:8
Definition JSValue.h:5
Definition buffer.h:5
Definition ctx.h:5
Definition Alias.h:14