![]() |
v8 13.6.233 (node 24.1.0)
V8 is Google's open source JavaScript engine
|
#include <v8-script.h>
Public Member Functions | |
Local< String > | GetSpecifier () const |
ModuleImportPhase | GetPhase () const |
int | GetSourceOffset () const |
Local< FixedArray > | GetImportAttributes () const |
Local< FixedArray > | GetImportAssertions () const |
![]() | |
bool | IsValue () const |
bool | IsModule () const |
bool | IsModuleRequest () const |
bool | IsFixedArray () const |
bool | IsPrivate () const |
bool | IsObjectTemplate () const |
bool | IsFunctionTemplate () const |
bool | IsContext () const |
Static Public Member Functions | |
static V8_INLINE ModuleRequest * | Cast (Data *data) |
Definition at line 125 of file v8-script.h.
|
static |
Definition at line 936 of file v8-script.h.
|
inline |
Definition at line 159 of file v8-script.h.
References GetImportAssertions(), and GetImportAttributes().
Referenced by GetImportAssertions().
Local< FixedArray > GetImportAttributes | ( | ) | const |
Contains the import attributes for this request in the form: [key1, value1, source_offset1, key2, value2, source_offset2, ...]. The keys and values are of type v8::String, and the source offsets are of type Int32. Use Module::SourceOffsetToLocation to convert the source offsets to Locations with line/column numbers.
All attributes present in the module request will be supplied in this list, regardless of whether they are supported by the host. Per https://tc39.es/proposal-import-attributes/#sec-hostgetsupportedimportattributes, hosts are expected to throw for attributes that they do not support (as opposed to, for example, ignoring them).
Referenced by GetImportAssertions().
ModuleImportPhase GetPhase | ( | ) | const |
Returns the module import phase for this ModuleRequest.
int GetSourceOffset | ( | ) | const |
Returns the source code offset of this module request. Use Module::SourceOffsetToLocation to convert this to line/column numbers.
Returns the module specifier for this ModuleRequest.