Lines Matching full:vm
123 using TimerTaskCallback = void* (*)(EcmaVM *vm, void *data, TimerCallbackFunc func, uint64_t timeou…
263 Local(const EcmaVM *vm, const Global<T> ¤t);
265 Local(const EcmaVM *vm, const CopyableGlobal<T> ¤t);
355 CopyableGlobal(const EcmaVM *vm, const Local<S> ¤t);
357 CopyableGlobal(const EcmaVM *vm, const Local<T> ¤t);
453 Global(const EcmaVM *vm, const Local<S> ¤t);
455 Global(const EcmaVM *vm, const Global<S> ¤t);
467 Local<T> ToLocal(const EcmaVM *vm) const in ToLocal() argument
469 return Local<T>(vm, *this); in ToLocal()
520 static Local<PrimitiveRef> Undefined(const EcmaVM *vm);
521 static Local<PrimitiveRef> Null(const EcmaVM *vm);
522 static Local<PrimitiveRef> Hole(const EcmaVM *vm);
523 static Local<PrimitiveRef> True(const EcmaVM *vm);
524 static Local<PrimitiveRef> False(const EcmaVM *vm);
526 bool BooleaValue(const EcmaVM *vm);
527 int64_t IntegerValue(const EcmaVM *vm);
528 uint32_t Uint32Value(const EcmaVM *vm);
529 int32_t Int32Value(const EcmaVM *vm);
536 Local<NumberRef> ToNumber(const EcmaVM *vm);
537 Local<BooleanRef> ToBoolean(const EcmaVM *vm);
538 Local<BigIntRef> ToBigInt(const EcmaVM *vm);
539 Local<StringRef> ToString(const EcmaVM *vm);
540 Local<ObjectRef> ToObject(const EcmaVM *vm);
541 Local<ObjectRef> ToEcmaObject(const EcmaVM *vm);
542 Local<ObjectRef> ToEcmaObjectWithoutSwitchState(const EcmaVM *vm);
543 Local<NativePointerRef> ToNativePointer(const EcmaVM *vm);
551 bool IsBigInt(const EcmaVM *vm);
555 bool IsString(const EcmaVM *vm);
556 bool IsStringWithoutSwitchState(const EcmaVM *vm);
557 bool IsSymbol(const EcmaVM *vm);
558 bool IsObject(const EcmaVM *vm);
559 bool IsObjectWithoutSwitchState(const EcmaVM *vm);
560 bool IsNativeBindingObject(const EcmaVM *vm);
561 bool IsArray(const EcmaVM *vm);
562 bool IsJSArray(const EcmaVM *vm);
563 bool IsConstructor(const EcmaVM *vm);
564 bool IsFunction(const EcmaVM *vm);
566 bool IsJSFunction(const EcmaVM *vm);
567 bool IsProxy(const EcmaVM *vm);
568 bool IsPromise(const EcmaVM *vm);
569 bool IsDataView(const EcmaVM *vm);
570 bool IsTypedArray(const EcmaVM *vm);
571 bool IsNativePointer(const EcmaVM *vm);
572 bool IsDate(const EcmaVM *vm);
573 bool IsError(const EcmaVM *vm);
574 bool IsMap(const EcmaVM *vm);
575 bool IsSet(const EcmaVM *vm);
576 bool IsWeakRef(const EcmaVM *vm);
577 bool IsWeakMap(const EcmaVM *vm);
578 bool IsWeakSet(const EcmaVM *vm);
579 bool IsRegExp(const EcmaVM *vm);
580 bool IsArrayIterator(const EcmaVM *vm);
581 bool IsStringIterator(const EcmaVM *vm);
582 bool IsSetIterator(const EcmaVM *vm);
583 bool IsMapIterator(const EcmaVM *vm);
584 bool IsArrayBuffer(const EcmaVM *vm);
585 bool IsBuffer(const EcmaVM *vm);
586 bool IsUint8Array(const EcmaVM *vm);
587 bool IsInt8Array(const EcmaVM *vm);
588 bool IsUint8ClampedArray(const EcmaVM *vm);
589 bool IsInt16Array(const EcmaVM *vm);
590 bool IsUint16Array(const EcmaVM *vm);
591 bool IsInt32Array(const EcmaVM *vm);
592 bool IsUint32Array(const EcmaVM *vm);
593 bool IsFloat32Array(const EcmaVM *vm);
594 bool IsFloat64Array(const EcmaVM *vm);
595 bool IsBigInt64Array(const EcmaVM *vm);
596 bool IsBigUint64Array(const EcmaVM *vm);
597 bool IsJSPrimitiveRef(const EcmaVM *vm);
598 bool IsJSPrimitiveNumber(const EcmaVM *vm);
599 bool IsJSPrimitiveInt(const EcmaVM *vm);
600 bool IsJSPrimitiveBoolean(const EcmaVM *vm);
601 bool IsJSPrimitiveString(const EcmaVM *vm);
603 bool IsJSSharedInt8Array(const EcmaVM *vm);
604 bool IsJSSharedUint8Array(const EcmaVM *vm);
605 bool IsJSSharedUint8ClampedArray(const EcmaVM *vm);
606 bool IsJSSharedInt16Array(const EcmaVM *vm);
607 bool IsJSSharedUint16Array(const EcmaVM *vm);
608 bool IsJSSharedInt32Array(const EcmaVM *vm);
609 bool IsJSSharedUint32Array(const EcmaVM *vm);
610 bool IsJSSharedFloat32Array(const EcmaVM *vm);
612 bool IsGeneratorObject(const EcmaVM *vm);
613 bool IsJSPrimitiveSymbol(const EcmaVM *vm);
615 bool IsArgumentsObject(const EcmaVM *vm);
616 bool IsGeneratorFunction(const EcmaVM *vm);
617 bool IsAsyncFunction(const EcmaVM *vm);
618 bool IsConcurrentFunction(const EcmaVM *vm);
619 bool IsJSLocale(const EcmaVM *vm);
620 bool IsJSDateTimeFormat(const EcmaVM *vm);
621 bool IsJSRelativeTimeFormat(const EcmaVM *vm);
622 bool IsJSIntl(const EcmaVM *vm);
623 bool IsJSNumberFormat(const EcmaVM *vm);
624 bool IsJSCollator(const EcmaVM *vm);
625 bool IsJSPluralRules(const EcmaVM *vm);
626 bool IsJSListFormat(const EcmaVM *vm);
627 bool IsAsyncGeneratorFunction(const EcmaVM *vm);
628 bool IsAsyncGeneratorObject(const EcmaVM *vm);
630 bool IsModuleNamespaceObject(const EcmaVM *vm);
631 bool IsNativeModuleFailureInfoObject(const EcmaVM *vm);
632 bool IsSharedArrayBuffer(const EcmaVM *vm);
633 bool IsSendableArrayBuffer(const EcmaVM *vm);
635 bool IsStrictEquals(const EcmaVM *vm, Local<JSValueRef> value);
636 Local<StringRef> Typeof(const EcmaVM *vm);
637 bool InstanceOf(const EcmaVM *vm, Local<JSValueRef> value);
639 bool IsArrayList(const EcmaVM *vm);
640 bool IsDeque(const EcmaVM *vm);
641 bool IsHashMap(const EcmaVM *vm);
642 bool IsHashSet(const EcmaVM *vm);
643 bool IsLightWeightMap(const EcmaVM *vm);
644 bool IsLightWeightSet(const EcmaVM *vm);
645 bool IsLinkedList(const EcmaVM *vm);
646 bool IsLinkedListIterator(const EcmaVM *vm);
647 bool IsList(const EcmaVM *vm);
648 bool IsPlainArray(const EcmaVM *vm);
649 bool IsQueue(const EcmaVM *vm);
650 bool IsStack(const EcmaVM *vm);
651 bool IsTreeMap(const EcmaVM *vm);
652 bool IsTreeSet(const EcmaVM *vm);
653 bool IsVector(const EcmaVM *vm);
654 bool IsBitVector(const EcmaVM *vm);
655 bool IsSendableObject(const EcmaVM *vm);
656 bool IsJSShared(const EcmaVM *vm);
657 bool IsSharedArray(const EcmaVM *vm);
658 bool IsSharedTypedArray(const EcmaVM *vm);
659 bool IsSharedSet(const EcmaVM *vm);
660 bool IsSharedMap(const EcmaVM *vm);
661 bool IsSharedMapIterator(const EcmaVM *vm);
663 void *GetNativePointerValue(const EcmaVM *vm, bool &isNativePointer);
664 bool IsDetachedArraybuffer(const EcmaVM *vm, bool &isArrayBuffer);
665 void DetachedArraybuffer(const EcmaVM *vm, bool &isArrayBuffer);
666 void GetDataViewInfo(const EcmaVM *vm,
672 void TryGetArrayLength(const EcmaVM *vm, bool *isPendingException,
674 bool IsJsGlobalEnv(const EcmaVM *vm);
683 void *GetNativePointerValueImpl(const EcmaVM *vm, bool &isNativePointer);
744 Local<JSValueRef> GetValue(const EcmaVM *vm) const in GetValue() argument
747 return JSValueRef::Undefined(vm); in GetValue()
759 Local<JSValueRef> GetGetter(const EcmaVM *vm) const in GetGetter() argument
762 return JSValueRef::Undefined(vm); in GetGetter()
774 Local<JSValueRef> GetSetter(const EcmaVM *vm) const in GetSetter() argument
777 return JSValueRef::Undefined(vm); in GetSetter()
804 …static Local<NativePointerRef> New(const EcmaVM *vm, void *nativePointer, size_t nativeBindingsize…
805 …static Local<NativePointerRef> New(const EcmaVM *vm, void *nativePointer, NativePointerCallback ca…
807 static Local<NativePointerRef> NewConcurrent(const EcmaVM *vm, void *nativePointer,
810 static Local<NativePointerRef> NewSendable(const EcmaVM *vm,
835 static Local<ObjectRef> New(const EcmaVM *vm);
836 static uintptr_t NewObject(const EcmaVM *vm);
837 static Local<ObjectRef> NewS(const EcmaVM *vm);
838 …static Local<ObjectRef> NewWithProperties(const EcmaVM *vm, size_t propertyCount, const Local<JSVa…
840 static Local<ObjectRef> NewSWithProperties(const EcmaVM *vm, SendablePropertiesInfo &info);
841 …static Local<ObjectRef> NewWithNamedProperties(const EcmaVM *vm, size_t propertyCount, const char …
843 …static Local<ObjectRef> CreateNativeModuleFailureInfo(const EcmaVM *vm, const std::string &failure…
844 …static Local<ObjectRef> CreateAccessorData(const EcmaVM *vm, Local<FunctionRef> getter, Local<Func…
845 static Local<ObjectRef> CreateSendableAccessorData(const EcmaVM *vm,
848 bool ConvertToNativeBindingObject(const EcmaVM *vm, Local<NativePointerRef> value);
849 Local<NativePointerRef> GetNativeBindingPointer(const EcmaVM *vm);
850 bool Set(const EcmaVM *vm, Local<JSValueRef> key, Local<JSValueRef> value);
851 bool Set(const EcmaVM *vm, const char *utf8, Local<JSValueRef> value);
852 bool Set(const EcmaVM *vm, uint32_t key, Local<JSValueRef> value);
853 bool SetWithoutSwitchState(const EcmaVM *vm, const char *utf8, Local<JSValueRef> value);
854 bool SetAccessorProperty(const EcmaVM *vm, Local<JSValueRef> key, Local<FunctionRef> getter,
856 Local<JSValueRef> Get(const EcmaVM *vm, Local<JSValueRef> key);
857 Local<JSValueRef> Get(const EcmaVM *vm, const char *utf8);
858 Local<JSValueRef> Get(const EcmaVM *vm, int32_t key);
860 bool GetOwnProperty(const EcmaVM *vm, Local<JSValueRef> key, PropertyAttribute &property);
861 Local<ArrayRef> GetOwnPropertyNames(const EcmaVM *vm);
862 Local<ArrayRef> GetAllPropertyNames(const EcmaVM *vm, uint32_t filter);
863 Local<ArrayRef> GetOwnEnumerablePropertyNames(const EcmaVM *vm);
864 Local<JSValueRef> GetPrototype(const EcmaVM *vm);
865 bool SetPrototype(const EcmaVM *vm, Local<ObjectRef> prototype);
867 bool DefineProperty(const EcmaVM *vm, Local<JSValueRef> key, PropertyAttribute attribute);
869 bool Has(const EcmaVM *vm, Local<JSValueRef> key);
870 bool Has(const EcmaVM *vm, uint32_t key);
872 bool HasOwnProperty(const EcmaVM *vm, Local<JSValueRef> key);
874 bool Delete(const EcmaVM *vm, Local<JSValueRef> key);
875 bool Delete(const EcmaVM *vm, uint32_t key);
877 Local<JSValueRef> Freeze(const EcmaVM *vm);
878 Local<JSValueRef> Seal(const EcmaVM *vm);
879 void SetNativePointerFieldCount(const EcmaVM *vm, int32_t count);
880 int32_t GetNativePointerFieldCount(const EcmaVM *vm);
881 void *GetNativePointerField(const EcmaVM *vm, int32_t index);
882 void SetNativePointerField(const EcmaVM *vm,
887 void SetConcurrentNativePointerField(const EcmaVM *vm,
904 …static Local<FunctionRef> New(EcmaVM *vm, FunctionCallback nativeFunc, NativePointerCallback delet…
906 …static Local<FunctionRef> New(EcmaVM *vm, const Local<JSValueRef> &context, FunctionCallback nativ…
909 static Local<FunctionRef> NewConcurrent(EcmaVM *vm,
915 static Local<FunctionRef> NewConcurrent(EcmaVM *vm,
922 …static Local<FunctionRef> New(EcmaVM *vm, InternalFunctionCallback nativeFunc, NativePointerCallba…
924 …static Local<FunctionRef> New(EcmaVM *vm, const Local<JSValueRef> &context, InternalFunctionCallba…
926 static Local<FunctionRef> NewConcurrent(EcmaVM *vm,
933 static Local<FunctionRef> NewConcurrent(EcmaVM *vm,
939 static Local<FunctionRef> NewConcurrentWithName(EcmaVM *vm, const Local<JSValueRef> &context,
943 static Local<FunctionRef> NewSendable(EcmaVM *vm,
949 …static Local<FunctionRef> NewClassFunction(EcmaVM *vm, FunctionCallback nativeFunc, NativePointerC…
951 static Local<FunctionRef> NewClassFunction(EcmaVM *vm, const Local<JSValueRef> &context,
954 static Local<FunctionRef> NewConcurrentClassFunction(EcmaVM *vm,
960 static Local<FunctionRef> NewConcurrentClassFunction(EcmaVM *vm,
967 …static Local<FunctionRef> NewConcurrentClassFunctionWithName(const EcmaVM *vm, const Local<JSValue…
977 static Local<FunctionRef> NewClassFunction(EcmaVM *vm,
983 static Local<FunctionRef> NewClassFunction(EcmaVM *vm,
990 static Local<FunctionRef> NewSendableClassFunction(const EcmaVM *vm,
999 JSValueRef* CallForNapi(const EcmaVM *vm, JSValueRef *thisObj, JSValueRef *const argv[],
1001 …Local<JSValueRef> Call(const EcmaVM *vm, Local<JSValueRef> thisObj, const Local<JSValueRef> argv[],
1003 Local<JSValueRef> Constructor(const EcmaVM *vm, const Local<JSValueRef> argv[], int32_t length);
1004 JSValueRef* ConstructorOptimize(const EcmaVM *vm, JSValueRef* argv[], int32_t length);
1006 Local<JSValueRef> GetFunctionPrototype(const EcmaVM *vm);
1007 bool Inherit(const EcmaVM *vm, Local<FunctionRef> parent);
1008 void SetName(const EcmaVM *vm, Local<StringRef> name);
1009 Local<StringRef> GetName(const EcmaVM *vm);
1010 Local<StringRef> GetSourceCode(const EcmaVM *vm, int lineNumber);
1011 bool IsNative(const EcmaVM *vm);
1012 …void SetData(const EcmaVM *vm, void *data, NativePointerCallback deleter = nullptr, bool callNapi …
1013 void* GetData(const EcmaVM *vm);
1018 Local<JSValueRef> GetValue(const EcmaVM *vm);
1023 … static Local<SymbolRef> New(const EcmaVM *vm, Local<StringRef> description = Local<StringRef>());
1024 Local<StringRef> GetDescription(const EcmaVM *vm);
1029 static Local<BooleanRef> New(const EcmaVM *vm, bool input);
1040 …static Local<StringRef> NewFromUtf8WithoutStringTable(const EcmaVM *vm, const char *utf8, int leng…
1041 static Local<StringRef> NewFromUtf8(const EcmaVM *vm, const char *utf8, int length = -1);
1042 …static Local<StringRef> NewFromUtf16WithoutStringTable(const EcmaVM *vm, const char16_t *utf16, in…
1043 static Local<StringRef> NewFromUtf16(const EcmaVM *vm, const char16_t *utf16, int length = -1);
1044 std::string ToString(const EcmaVM *vm);
1045 std::string DebuggerToString(const EcmaVM *vm);
1046 uint32_t Length(const EcmaVM *vm);
1047 bool IsCompressed(const EcmaVM *vm);
1048 size_t Utf8Length(const EcmaVM *vm, bool isGetBufferSize = false);
1049 uint32_t WriteUtf8(const EcmaVM *vm, char *buffer, uint32_t length, bool isWriteBuffer = false);
1050 uint32_t WriteUtf16(const EcmaVM *vm, char16_t *buffer, uint32_t length);
1051 uint32_t WriteLatin1(const EcmaVM *vm, char *buffer, uint32_t length);
1052 uint32_t WriteLatin1WithoutSwitchState(const EcmaVM *vm, char *buffer, uint32_t length);
1053 static Local<StringRef> GetNapiWrapperString(const EcmaVM *vm);
1054 Local<TypedArrayRef> EncodeIntoUint8Array(const EcmaVM *vm);
1115 static Local<BigIntRef> New(const EcmaVM *vm, uint64_t input);
1116 static Local<BigIntRef> New(const EcmaVM *vm, int64_t input);
1117 …static Local<JSValueRef> CreateBigWords(const EcmaVM *vm, bool sign, uint32_t size, const uint64_t…
1118 void BigIntToInt64(const EcmaVM *vm, int64_t *value, bool *lossless);
1119 void BigIntToUint64(const EcmaVM *vm, uint64_t *value, bool *lossless);
1120 void GetWordsArray(const EcmaVM *vm, bool* signBit, size_t wordCount, uint64_t* words);
1121 uint32_t GetWordsArraySize(const EcmaVM *vm);
1127 explicit LocalScope(const EcmaVM *vm);
1131 inline LocalScope(const EcmaVM *vm, JSTaggedType value);
1145 explicit EscapeLocalScope(const EcmaVM *vm);
1167 static Local<IntegerRef> New(const EcmaVM *vm, int input);
1168 static Local<IntegerRef> NewFromUnsigned(const EcmaVM *vm, unsigned int input);
1174 static Local<ArrayBufferRef> New(const EcmaVM *vm, int32_t length);
1175 static Local<ArrayBufferRef> New(const EcmaVM *vm, void *buffer, int32_t length,
1178 int32_t ByteLength(const EcmaVM *vm);
1179 void *GetBuffer(const EcmaVM *vm);
1180 void *GetBufferAndLength(const EcmaVM *vm, int32_t *length);
1181 void Detach(const EcmaVM *vm);
1182 bool IsDetach(const EcmaVM *vm);
1187 static Local<SendableArrayBufferRef> New(const EcmaVM *vm, int32_t length);
1188 static Local<SendableArrayBufferRef> New(const EcmaVM *vm, void *buffer, int32_t length,
1191 int32_t ByteLength(const EcmaVM *vm);
1192 void *GetBuffer(const EcmaVM *vm);
1194 void Detach(const EcmaVM *vm);
1195 bool IsDetach(const EcmaVM *vm);
1200 static Local<DateRef> New(const EcmaVM *vm, double time);
1201 Local<StringRef> ToString(const EcmaVM *vm);
1202 double GetTime(const EcmaVM *vm);
1207 uint32_t ByteLength(const EcmaVM *vm);
1208 uint32_t ByteOffset(const EcmaVM *vm);
1209 uint32_t ArrayLength(const EcmaVM *vm);
1210 Local<ArrayBufferRef> GetArrayBuffer(const EcmaVM *vm);
1215 uint32_t ByteLength(const EcmaVM *vm);
1216 uint32_t ByteOffset(const EcmaVM *vm);
1217 uint32_t ArrayLength(const EcmaVM *vm);
1218 Local<SendableArrayBufferRef> GetArrayBuffer(const EcmaVM *vm);
1223 static Local<ArrayRef> New(const EcmaVM *vm, uint32_t length = 0);
1224 uint32_t Length(const EcmaVM *vm);
1225 …static bool SetValueAt(const EcmaVM *vm, Local<JSValueRef> obj, uint32_t index, Local<JSValueRef> …
1226 static Local<JSValueRef> GetValueAt(const EcmaVM *vm, Local<JSValueRef> obj, uint32_t index);
1231 static Local<SendableArrayRef> New(const EcmaVM *vm, uint32_t length = 0);
1232 uint32_t Length(const EcmaVM *vm);
1233 static Local<JSValueRef> GetValueAt(const EcmaVM *vm, Local<JSValueRef> obj, uint32_t index);
1234 …static bool SetProperty(const EcmaVM *vm, Local<JSValueRef> obj, uint32_t index, Local<JSValueRef>…
1239 …static Local<Int8ArrayRef> New(const EcmaVM *vm, Local<ArrayBufferRef> buffer, int32_t byteOffset,…
1244 static Local<SharedInt8ArrayRef> New(const EcmaVM *vm, Local<SendableArrayBufferRef> buffer,
1250 …static Local<Uint8ArrayRef> New(const EcmaVM *vm, Local<ArrayBufferRef> buffer, int32_t byteOffset…
1255 static Local<SharedUint8ArrayRef> New(const EcmaVM *vm, Local<SendableArrayBufferRef> buffer,
1261 …static Local<Uint8ClampedArrayRef> New(const EcmaVM *vm, Local<ArrayBufferRef> buffer, int32_t byt…
1267 …static Local<Int16ArrayRef> New(const EcmaVM *vm, Local<ArrayBufferRef> buffer, int32_t byteOffset…
1272 static Local<SharedInt16ArrayRef> New(const EcmaVM *vm, Local<SendableArrayBufferRef> buffer,
1278 …static Local<Uint16ArrayRef> New(const EcmaVM *vm, Local<ArrayBufferRef> buffer, int32_t byteOffse…
1284 static Local<SharedUint16ArrayRef> New(const EcmaVM *vm, Local<SendableArrayBufferRef> buffer,
1290 …static Local<Int32ArrayRef> New(const EcmaVM *vm, Local<ArrayBufferRef> buffer, int32_t byteOffset…
1295 static Local<SharedInt32ArrayRef> New(const EcmaVM *vm, Local<SendableArrayBufferRef> buffer,
1301 static Local<SharedFloat32ArrayRef> New(const EcmaVM *vm, Local<SendableArrayBufferRef> buffer,
1307 …static Local<SharedUint8ClampedArrayRef> New(const EcmaVM *vm, Local<SendableArrayBufferRef> buffe…
1313 …static Local<Uint32ArrayRef> New(const EcmaVM *vm, Local<ArrayBufferRef> buffer, int32_t byteOffse…
1319 static Local<SharedUint32ArrayRef> New(const EcmaVM *vm, Local<SendableArrayBufferRef> buffer,
1325 …static Local<Float32ArrayRef> New(const EcmaVM *vm, Local<ArrayBufferRef> buffer, int32_t byteOffs…
1331 …static Local<Float64ArrayRef> New(const EcmaVM *vm, Local<ArrayBufferRef> buffer, int32_t byteOffs…
1337 …static Local<BigInt64ArrayRef> New(const EcmaVM *vm, Local<ArrayBufferRef> buffer, int32_t byteOff…
1343 …static Local<BigUint64ArrayRef> New(const EcmaVM *vm, Local<ArrayBufferRef> buffer, int32_t byteOf…
1349 static Local<JSValueRef> Error(const EcmaVM *vm, Local<StringRef> message);
1350 static Local<JSValueRef> RangeError(const EcmaVM *vm, Local<StringRef> message);
1351 static Local<JSValueRef> ReferenceError(const EcmaVM *vm, Local<StringRef> message);
1352 static Local<JSValueRef> SyntaxError(const EcmaVM *vm, Local<StringRef> message);
1353 static Local<JSValueRef> TypeError(const EcmaVM *vm, Local<StringRef> message);
1354 static Local<JSValueRef> AggregateError(const EcmaVM *vm, Local<StringRef> message);
1355 static Local<JSValueRef> EvalError(const EcmaVM *vm, Local<StringRef> message);
1356 static Local<JSValueRef> OOMError(const EcmaVM *vm, Local<StringRef> message);
1357 static Local<JSValueRef> TerminationError(const EcmaVM *vm, Local<StringRef> message);
1362 FunctionCallScope(EcmaVM *vm);
1371 explicit JSExecutionScope(const EcmaVM *vm);
1383 explicit JsiNativeScope(const EcmaVM *vm);
1397 explicit JsiFastNativeScope(const EcmaVM *vm);
1487 int32_t GetSize(const EcmaVM *vm);
1488 int32_t GetTotalElements(const EcmaVM *vm);
1489 Local<JSValueRef> Get(const EcmaVM *vm, Local<JSValueRef> key);
1490 Local<JSValueRef> Get(const EcmaVM *vm, const char *utf8);
1491 Local<JSValueRef> GetKey(const EcmaVM *vm, int entry);
1492 Local<JSValueRef> GetValue(const EcmaVM *vm, int entry);
1493 static Local<MapRef> New(const EcmaVM *vm);
1494 void Set(const EcmaVM *vm, Local<JSValueRef> key, Local<JSValueRef> value);
1495 void Set(const EcmaVM *vm, const char *utf8, Local<JSValueRef> value);
1496 bool Has(const EcmaVM *vm, Local<JSValueRef> key);
1497 bool Has(const EcmaVM *vm, const char *utf8);
1498 void Delete(const EcmaVM *vm, Local<JSValueRef> key);
1499 void Clear(const EcmaVM *vm);
1500 Local<MapIteratorRef> GetEntries(const EcmaVM *vm);
1501 Local<MapIteratorRef> GetKeys(const EcmaVM *vm);
1502 Local<MapIteratorRef> GetValues(const EcmaVM *vm);
1507 static Local<SendableMapRef> New(const EcmaVM *vm);
1508 uint32_t GetSize(const EcmaVM *vm);
1509 uint32_t GetTotalElements(const EcmaVM *vm);
1510 Local<JSValueRef> Get(const EcmaVM *vm, Local<JSValueRef> key);
1511 Local<JSValueRef> Get(const EcmaVM *vm, const char *utf8);
1512 Local<JSValueRef> GetKey(const EcmaVM *vm, int entry);
1513 Local<JSValueRef> GetValue(const EcmaVM *vm, int entry);
1514 void Set(const EcmaVM *vm, Local<JSValueRef> key, Local<JSValueRef> value);
1515 void Set(const EcmaVM *vm, const char *utf8, Local<JSValueRef> value);
1516 bool Has(const EcmaVM *vm, Local<JSValueRef> key);
1517 bool Has(const EcmaVM *vm, const char *utf8);
1518 void Delete(const EcmaVM *vm, Local<JSValueRef> key);
1519 void Clear(const EcmaVM *vm);
1520 Local<SendableMapIteratorRef> GetEntries(const EcmaVM *vm);
1521 Local<SendableMapIteratorRef> GetKeys(const EcmaVM *vm);
1522 Local<SendableMapIteratorRef> GetValues(const EcmaVM *vm);
1527 static Local<SendableSetRef> New(const EcmaVM *vm);
1528 uint32_t GetSize(const EcmaVM *vm);
1529 uint32_t GetTotalElements(const EcmaVM *vm);
1530 Local<JSValueRef> GetValue(const EcmaVM *vm, int entry);
1531 void Add(const EcmaVM *vm, Local<JSValueRef> value);
1536 static Local<BufferRef> New(const EcmaVM *vm, int32_t length);
1537 static Local<BufferRef> New(const EcmaVM *vm, const Local<JSValueRef> &context, int32_t length);
1538 …static Local<BufferRef> New(const EcmaVM *vm, void *buffer, int32_t length, const NativePointerCal…
1540 …static Local<BufferRef> New(const EcmaVM *vm, const Local<JSValueRef> &context, void *buffer, int3…
1543 int32_t ByteLength(const EcmaVM *vm);
1544 void *GetBuffer(const EcmaVM *vm);
1550 Local<PromiseRef> Catch(const EcmaVM *vm, Local<FunctionRef> handler);
1551 Local<PromiseRef> Then(const EcmaVM *vm, Local<FunctionRef> handler);
1552 Local<PromiseRef> Finally(const EcmaVM *vm, Local<FunctionRef> handler);
1553 …Local<PromiseRef> Then(const EcmaVM *vm, Local<FunctionRef> onFulfilled, Local<FunctionRef> onReje…
1555 Local<JSValueRef> GetPromiseState(const EcmaVM *vm);
1556 Local<JSValueRef> GetPromiseResult(const EcmaVM *vm);
1561 static Local<PromiseCapabilityRef> New(const EcmaVM *vm);
1562 bool Resolve(const EcmaVM *vm, uintptr_t value);
1563 bool Resolve(const EcmaVM *vm, Local<JSValueRef> value);
1564 bool Reject(const EcmaVM *vm, uintptr_t reason);
1565 bool Reject(const EcmaVM *vm, Local<JSValueRef> reason);
1566 Local<PromiseRef> GetPromise(const EcmaVM *vm);
1571 static Local<NumberRef> New(const EcmaVM *vm, double input);
1572 static Local<NumberRef> New(const EcmaVM *vm, int32_t input);
1573 static Local<NumberRef> New(const EcmaVM *vm, uint32_t input);
1574 static Local<NumberRef> New(const EcmaVM *vm, int64_t input);
1581 …static Local<DataViewRef> New(const EcmaVM *vm, Local<ArrayBufferRef> arrayBuffer, uint32_t byteOf…
1583 …static Local<DataViewRef> NewWithoutSwitchState(const EcmaVM *vm, Local<ArrayBufferRef> arrayBuffe…
1587 Local<ArrayBufferRef> GetArrayBuffer(const EcmaVM *vm);
1593 Local<JSValueRef> GetKind(const EcmaVM *vm);
1594 static Local<MapIteratorRef> New(const EcmaVM *vm, Local<MapRef> map);
1595 ecmascript::EcmaRuntimeCallInfo* GetEcmaRuntimeCallInfo(const EcmaVM *vm);
1596 …static Local<ArrayRef> Next(const EcmaVM *vm, ecmascript::EcmaRuntimeCallInfo* ecmaRuntimeCallInfo…
1597 Local<JSValueRef> Next(const EcmaVM *vm);
1602 Local<JSValueRef> Next(const EcmaVM *vm);
1674 static void LoadAotFile(EcmaVM *vm, const std::string &moduleName);
1676 static void LoadAotFile(EcmaVM *vm, [[maybe_unused]] const std::string &bundleName,
1681 static bool ExecuteForAbsolutePath(const EcmaVM *vm, const std::string &fileName,
1684 static bool Execute(const EcmaVM *vm, const std::string &fileName,
1687 static bool Execute(EcmaVM *vm, const uint8_t *data, int32_t size, const std::string &entry,
1690 static int ExecuteWithSingletonPatternFlag(EcmaVM *vm, const std::string &bundleName,
1692 static bool IsExecuteModuleInAbcFile(EcmaVM *vm, const std::string &bundleName,
1695 …static bool ExecuteModuleBuffer(EcmaVM *vm, const uint8_t *data, int32_t size, const std::string &…
1697 …static bool ExecuteModuleFromBuffer(EcmaVM *vm, const void *data, int32_t size, const std::string …
1707 …static Local<ObjectRef> GetExportObject(EcmaVM *vm, const std::string &file, const std::string &ke…
1708 …static Local<ObjectRef> GetExportObjectFromBuffer(EcmaVM *vm, const std::string &file, const std::…
1709 …static Local<ObjectRef> GetExportObjectFromOhmUrl(EcmaVM *vm, const std::string &ohmUrl, const std…
1710 static Local<ObjectRef> ExecuteNativeModule(EcmaVM *vm, const std::string &key);
1711 static Local<ObjectRef> GetModuleNameSpaceFromFile(EcmaVM *vm, const std::string &file);
1713 static Local<ObjectRef> GetModuleNameSpaceWithModuleInfo(EcmaVM *vm, const std::string &file,
1715 …static Local<ObjectRef> GetModuleNameSpaceWithModuleInfoForNormalApp(EcmaVM *vm, const std::string…
1717 …static Local<ObjectRef> GetModuleNameSpaceWithModuleInfoForHybridApp(EcmaVM *vm, const std::string…
1727 static bool ExecuteSecure(EcmaVM *vm, uint8_t *data, int32_t size, const std::string &entry,
1735 …static bool ExecuteModuleBufferSecure(EcmaVM *vm, uint8_t *data, int32_t size, const std::string &…
1738 …static bool ExecuteSecureWithOhmUrl(EcmaVM *vm, uint8_t *data, int32_t size, const std::string &sr…
1742 static Local<ObjectRef> GetGlobalObject(const EcmaVM *vm);
1743 static Local<ObjectRef> GetGlobalObject(const EcmaVM *vm, const Local<JSValueRef> &context);
1744 static void ExecutePendingJob(const EcmaVM *vm);
1748 static void TriggerGC(const EcmaVM *vm, TRIGGER_GC_TYPE gcType = TRIGGER_GC_TYPE::SEMI_GC);
1749 static void TriggerGC(const EcmaVM *vm, ecmascript::GCReason reason,
1751 static void HintGC(const EcmaVM *vm, MemoryReduceDegree degree, ecmascript::GCReason reason);
1752 static void TriggerIdleGC(const EcmaVM *vm, TRIGGER_IDLE_GC_TYPE gcType);
1756 static void ThrowException(const EcmaVM *vm, Local<JSValueRef> error);
1757 static void PrintExceptionInfo(const EcmaVM *vm);
1758 static void SetOnErrorCallback(EcmaVM *vm, OnErrorCallback cb, void* data);
1759 static Local<ObjectRef> GetAndClearUncaughtException(const EcmaVM *vm);
1760 static Local<ObjectRef> GetUncaughtException(const EcmaVM *vm);
1761 static bool IsExecutingPendingJob(const EcmaVM *vm);
1762 static bool HasPendingException(const EcmaVM *vm);
1763 static bool HasPendingJob(const EcmaVM *vm);
1764 static void EnableUserUncaughtErrorHandler(EcmaVM *vm);
1766 …static bool StartDebuggerCheckParameters(EcmaVM *vm, const DebugOption &option, int32_t instanceId,
1768 static bool StartDebugger(EcmaVM *vm, const DebugOption &option, int32_t instanceId = 0,
1771 …static bool StartDebuggerForOldProcess(EcmaVM *vm, const DebugOption &option, int32_t instanceId =…
1776 …static bool NotifyDebugMode(int tid, EcmaVM *vm, const DebugOption &option, int32_t instanceId = 0,
1779 …int tid, EcmaVM *vm, const DebugOption &option, const DebuggerPostTask &debuggerPostTask, bool deb…
1780 static bool StopDebugger(EcmaVM *vm);
1781 static bool IsMixedDebugEnabled(const EcmaVM *vm);
1782 static bool IsDebugModeEnabled(const EcmaVM *vm);
1783 static void NotifyNativeCalling(const EcmaVM *vm, const void *nativeAddress);
1784 static void NotifyNativeReturn(const EcmaVM *vm, const void *nativeAddress);
1785 static void NotifyLoadModule(const EcmaVM *vm);
1786 static void NotifyUIIdle(const EcmaVM *vm, int idleTime);
1787 static bool NotifyLooperIdleStart(const EcmaVM *vm, int64_t timestamp, int idleTime);
1788 static void NotifyLooperIdleEnd(const EcmaVM *vm, int64_t timestamp);
1789 static bool IsJSMainThreadOfEcmaVM(const EcmaVM *vm);
1790 static void SetDeviceDisconnectCallback(EcmaVM *vm, DeviceDisconnectCallback cb);
1792 … static void* SerializeValue(const EcmaVM *vm, Local<JSValueRef> data, Local<JSValueRef> transfer,
1796 …static void* SerializeValueWithError(const EcmaVM *vm, Local<JSValueRef> data, Local<JSValueRef> t…
1799 static Local<JSValueRef> DeserializeValue(const EcmaVM *vm, void *recoder, void *hint);
1801 …static void* InterOpSerializeValue(const EcmaVM *vm, Local<JSValueRef> data, Local<JSValueRef> tra…
1803 static Local<JSValueRef> InterOpDeserializeValue(const EcmaVM *vm, void *recoder, void *hint);
1805 static void SetHostPromiseRejectionTracker(EcmaVM *vm, void *cb, void* data);
1806 static void SetTimerTaskCallback(EcmaVM *vm, TimerTaskCallback callback);
1807 static void SetCancelTimerCallback(EcmaVM *vm, CancelTimerCallback callback);
1808 static void NotifyEnvInitialized(EcmaVM *vm);
1810 static void PandaFileSerialize(const EcmaVM *vm);
1811 static void ModuleSerialize(const EcmaVM *vm);
1812 static void ModuleDeserialize(EcmaVM *vm, const uint32_t appVersion);
1813 …static void SetHostResolveBufferTrackerForHybridApp(EcmaVM *vm, std::function<bool(std::string dir…
1815 …static void SetUnloadNativeModuleCallback(EcmaVM *vm, const std::function<bool(const std::string &…
1816 static void SetNativePtrGetter(EcmaVM *vm, void* cb);
1817 static void SetSourceMapCallback(EcmaVM *vm, SourceMapCallback cb);
1818 static void SetSourceMapTranslateCallback(EcmaVM *vm, SourceMapTranslateCallback cb);
1819 static void SetHostEnqueueJob(const EcmaVM* vm, Local<JSValueRef> cb,
1822 static void PreFork(EcmaVM *vm);
1823 static void PostFork(EcmaVM *vm, const RuntimeOption &option);
1826 static void GetStackBeforeCallNapiSuccess(EcmaVM *vm, bool &getStackBeforeCallNapiSuccess);
1827 static void GetStackAfterCallNapi(EcmaVM *vm);
1828 …static PatchErrorCode LoadPatch(EcmaVM *vm, const std::string &patchFileName, const std::string &b…
1829 static PatchErrorCode LoadPatch(EcmaVM *vm,
1832 static PatchErrorCode UnloadPatch(EcmaVM *vm, const std::string &patchFileName);
1834 …static bool IsQuickFixCausedException(EcmaVM *vm, Local<ObjectRef> exception, const std::string &p…
1836 static void RegisterQuickFixQueryFunc(EcmaVM *vm, std::function<bool(std::string baseFileName,
1840 static bool IsBundle(EcmaVM *vm);
1841 static void SetBundle(EcmaVM *vm, bool value);
1842 static bool IsNormalizedOhmUrlPack(EcmaVM *vm);
1844 static void SetAssetPath(EcmaVM *vm, const std::string &assetPath);
1845 static void SetMockModuleList(EcmaVM *vm, const std::map<std::string, std::string> &list);
1846 static void SetPkgNameList(EcmaVM *vm, const std::map<std::string, std::string> &list);
1847 static void UpdatePkgNameList(EcmaVM *vm, const std::map<std::string, std::string> &list);
1848 static std::string GetPkgName(EcmaVM *vm, const std::string &moduleName);
1849 static void SetPkgAliasList(EcmaVM *vm, const std::map<std::string, std::string> &list);
1850 static void UpdatePkgAliasList(EcmaVM *vm, const std::map<std::string, std::string> &list);
1851 static void SetHmsModuleList(EcmaVM *vm, const std::vector<panda::HmsMap> &list);
1852 …static void SetModuleInfo(EcmaVM *vm, const std::string &assetPath, const std::string &entryPoint);
1853 static void SetpkgContextInfoList(EcmaVM *vm, const std::map<std::string,
1855 static void UpdatePkgContextInfoList(EcmaVM *vm,
1857 static void SetExecuteBufferMode(const EcmaVM *vm);
1859 static void SetStopPreLoadSoCallback(EcmaVM *vm, const StopPreLoadSoCallback &callback);
1860 static void SetLoop(EcmaVM *vm, void *loop);
1861 static void SetWeakFinalizeTaskCallback(EcmaVM *vm, const WeakFinalizeTaskCallback &callback);
1862 static void SetAsyncCleanTaskCallback(EcmaVM *vm, const NativePointerTaskCallback &callback);
1863 static void SetTriggerGCTaskCallback(EcmaVM *vm, const TriggerGCTaskCallback& callback);
1864 static void SetStartIdleMonitorCallback(EcmaVM *vm, const StartIdleMonitorCallback& callback);
1865 static std::string GetAssetPath(EcmaVM *vm);
1866 static bool InitForConcurrentThread(EcmaVM *vm, ConcurrentCallback cb, void *data);
1867 static bool InitForConcurrentFunction(EcmaVM *vm, Local<JSValueRef> func, void *taskInfo);
1868 static void* GetCurrentTaskInfo(const EcmaVM *vm);
1869 static void ClearCurrentTaskInfo(const EcmaVM *vm);
1870 static void SetBundleName(EcmaVM *vm, const std::string &bundleName);
1871 static std::string GetBundleName(EcmaVM *vm);
1872 static void SetModuleName(EcmaVM *vm, const std::string &moduleName);
1873 static std::string GetModuleName(EcmaVM *vm);
1875 …static std::pair<std::string, std::string> GetCurrentModuleInfo(EcmaVM *vm, bool needRecordName = …
1877 static void AllowCrossThreadExecution(EcmaVM *vm);
1878 static bool CheckAndSetAllowCrossThreadExecution(EcmaVM *vm);
1879 static void SynchronizVMInfo(EcmaVM *vm, const EcmaVM *hostVM);
1880 static bool IsProfiling(EcmaVM *vm);
1881 static void SetProfilerState(const EcmaVM *vm, bool value);
1882 …static void SetRequestAotCallback(EcmaVM *vm, const std::function<int32_t(const std::string &bundl…
1885 static void SetSearchHapPathTracker(EcmaVM *vm, std::function<bool(const std::string moduleName,
1887 static void *GetEnv(EcmaVM *vm);
1888 static void SetEnv(EcmaVM *vm, void *env);
1893 static Local<JSValueRef> NapiHasProperty(const EcmaVM *vm, uintptr_t nativeObj, uintptr_t key);
1894 … static Local<JSValueRef> NapiHasOwnProperty(const EcmaVM *vm, uintptr_t nativeObj, uintptr_t key);
1895 static Local<JSValueRef> NapiGetProperty(const EcmaVM *vm, uintptr_t nativeObj, uintptr_t key);
1896 … static Local<JSValueRef> NapiDeleteProperty(const EcmaVM *vm, uintptr_t nativeObj, uintptr_t key);
1897 …static Local<JSValueRef> NapiGetNamedProperty(const EcmaVM *vm, uintptr_t nativeObj, const char* u…
1898 static Local<JSValueRef> CreateLocal(const EcmaVM *vm, JSValueRef src);
1902 static int GetStartRealTime(const EcmaVM *vm);
1903 static void NotifyTaskBegin(const EcmaVM *vm);
1904 static void NotifyTaskFinished(const EcmaVM *vm);
1905 static bool IsMultiThreadCheckEnabled(const EcmaVM *vm);
1908 //set VM apiVersion
1909 static void SetVMAPIVersion(EcmaVM *vm, const int32_t apiVersion);
1912 static void UpdateStackInfo(EcmaVM *vm, void *currentStackInfo, uint32_t opKind);
1914 static Local<JSValueRef> CreateContext(const EcmaVM *vm);
1916 static Local<JSValueRef> GetCurrentContext(const EcmaVM *vm);
1918 static void SwitchContext(const EcmaVM *vm, const Local<JSValueRef> &context);
1920 static Local<JSValueRef> GetImplements(const EcmaVM *vm, Local<JSValueRef> instance);
1929 static uintptr_t GetHandleAddr(const EcmaVM *vm, uintptr_t localAddress);
1930 static uintptr_t GetGlobalHandleAddr(const EcmaVM *vm, uintptr_t localAddress);
1931 static uintptr_t SetWeak(const EcmaVM *vm, uintptr_t localAddress);
1932 static uintptr_t SetWeakCallback(const EcmaVM *vm, uintptr_t localAddress, void *ref,
1935 static uintptr_t ClearWeak(const EcmaVM *vm, uintptr_t localAddress);
1936 static bool IsWeak(const EcmaVM *vm, uintptr_t localAddress);
1937 static void DisposeGlobalHandleAddr(const EcmaVM *vm, uintptr_t addr);
1939 static bool IsSerializationTimeoutCheckEnabled(const EcmaVM *vm);
1940 …static void GenerateTimeoutTraceIfNeeded(const EcmaVM *vm, std::chrono::system_clock::time_point &…
1958 Local<JSValueRef> GetHandler(const EcmaVM *vm);
1959 Local<JSValueRef> GetTarget(const EcmaVM *vm);
1965 int32_t GetSize(const EcmaVM *vm);
1966 int32_t GetTotalElements(const EcmaVM *vm);
1967 Local<JSValueRef> GetKey(const EcmaVM *vm, int entry);
1968 Local<JSValueRef> GetValue(const EcmaVM *vm, int entry);
1969 static Local<WeakMapRef> New(const EcmaVM *vm);
1970 void Set(const EcmaVM *vm, const Local<JSValueRef> &key, const Local<JSValueRef> &value);
1971 bool Has(const EcmaVM *vm, Local<JSValueRef> key);
1976 int32_t GetSize(const EcmaVM *vm);
1977 int32_t GetTotalElements(const EcmaVM *vm);
1978 Local<JSValueRef> GetValue(const EcmaVM *vm, int entry);
1979 static Local<SetRef> New(const EcmaVM *vm);
1980 void Add(const EcmaVM *vm, Local<JSValueRef> value);
1985 int32_t GetSize(const EcmaVM *vm);
1986 int32_t GetTotalElements(const EcmaVM *vm);
1987 Local<JSValueRef> GetValue(const EcmaVM *vm, int entry);
1988 static Local<WeakSetRef> New(const EcmaVM *vm);
1989 void Add(const EcmaVM *vm, Local<JSValueRef> value);
1995 Local<JSValueRef> GetKind(const EcmaVM *vm);
1996 static Local<SetIteratorRef> New(const EcmaVM *vm, Local<SetRef> set);
1997 ecmascript::EcmaRuntimeCallInfo *GetEcmaRuntimeCallInfo(const EcmaVM *vm);
1998 …static Local<ArrayRef> Next(const EcmaVM *vm, ecmascript::EcmaRuntimeCallInfo *ecmaRuntimeCallInfo…
2006 static bool RegisterStringCacheTable(const EcmaVM *vm, uint32_t size);
2007 static bool SetCachedString(const EcmaVM *vm, const char *name, uint32_t propertyIndex);
2008 static bool HasCachedString(const EcmaVM *vm, uint32_t propertyIndex);
2009 static Local<StringRef> GetCachedString(const EcmaVM *vm, uint32_t propertyIndex);
2014 Global<T>::Global(const EcmaVM *vm, const Local<S> ¤t) : vm_(vm) in Global() argument
2023 Global<T>::Global(const EcmaVM *vm, const Global<S> ¤t) : vm_(vm) in Global() argument
2031 CopyableGlobal<T>::CopyableGlobal(const EcmaVM *vm, const Local<T> ¤t) : vm_(vm) in CopyableGlobal() argument
2040 CopyableGlobal<T>::CopyableGlobal(const EcmaVM *vm, const Local<S> ¤t) : vm_(vm) in CopyableGlobal() argument
2161 Local<T>::Local(const EcmaVM *vm, const CopyableGlobal<T> ¤t) in Local() argument
2163 address_ = JSNApi::GetHandleAddr(vm, reinterpret_cast<uintptr_t>(*current)); in Local()
2167 Local<T>::Local(const EcmaVM *vm, const Global<T> ¤t) in Local() argument
2169 address_ = JSNApi::GetHandleAddr(vm, reinterpret_cast<uintptr_t>(*current)); in Local()