![]() |
v8
V8 is Google’s open source high-performance JavaScript and WebAssembly engine, written in C++.
|
#include <v8-console.h>
Public Member Functions | |
TaskInfo (v8::Isolate *isolate, V8Console *console, v8::Local< v8::Object > task) | |
void * | Id () const |
void | Cancel () |
Private Attributes | |
v8::Global< v8::Object > | m_task |
V8Console * | m_console = nullptr |
Each JS task object created via console.createTask
has a corresponding TaskInfo
object on the C++ side (in a 1:1 relationship).
The TaskInfo
holds on weakly to the JS task object. The JS task objects uses a private symbol to store a pointer to the TaskInfo
object (via v8::External).
The TaskInfo
objects holds all the necessary information we need to properly cancel the corresponding async task then the JS task object gets GC'ed.
Definition at line 240 of file v8-console.h.
v8_inspector::TaskInfo::TaskInfo | ( | v8::Isolate * | isolate, |
V8Console * | console, | ||
v8::Local< v8::Object > | task ) |
|
inline |
|
inline |
|
private |
Definition at line 257 of file v8-console.h.
|
private |
Definition at line 256 of file v8-console.h.