3#include "mc/_HeaderOutputPredefine.h"
6#include "mc/deps/scripting/quickjs/NativeObjectOwnership.h"
7#include "mc/external/quickjs/JSTypedArrayEnum.h"
13namespace Scripting {
class LifetimeRegistry; }
14namespace Scripting {
class StrongObjectHandle; }
15namespace Scripting {
struct ClassBinding; }
16namespace Scripting {
struct FunctionBinding; }
17namespace Scripting {
struct InterfaceBinding; }
18namespace Scripting {
struct IteratorBinding; }
19namespace Scripting {
struct ObjectFactory; }
20namespace Scripting {
struct ObjectHandle; }
21namespace Scripting::QuickJS {
class ContextUserData; }
22namespace Scripting::QuickJS {
class RegisteredClass; }
23namespace Scripting::QuickJS {
class RegisteredEnum; }
24namespace Scripting::QuickJS {
class RegisteredInterface; }
25namespace Scripting::QuickJS {
class RuntimeUserData; }
26namespace Scripting::QuickJS {
struct ArrayProxy; }
27namespace Scripting::QuickJS {
struct PropertyGetSet; }
28namespace Scripting::Reflection {
class IFunction; }
31namespace Scripting::QuickJS {
34MCAPI ::JSValue ConvertJSValueArgsToNativeAnys(
39 ::std::array<::entt::meta_any, 16>& outArgsAsAnys
42MCAPI ::JSValue CopyJSValueArrayToNativeSequenceContainer(
45 ::entt::meta_sequence_container& view,
46 ::entt::meta_type
const& type
49MCAPI ::JSValue CopyJSValueObjectToNativeAssociativeContainer(
52 ::entt::meta_associative_container& view,
53 ::entt::meta_type
const& type
56MCAPI ::Scripting::QuickJS::ArrayProxy CreateArrayProxy(
::JSContext*
ctx);
60MCAPI ::std::unique_ptr<::Scripting::ClassBinding>
65MCAPI ::JSValue GenericFreeFunctionCaller(
74MCAPI ::JSValue GenericObjectFunctionCaller(
86MCAPI ::JSValue GenericReflectionPropertyGetter(
95MCAPI ::JSValue GenericReflectionPropertySetter(
108MCAPI ::Scripting::ObjectHandle GetNativeObjectHandleFromJSValue(
::JSValue jsValue);
110MCAPI ::Scripting::QuickJS::PropertyGetSet
const&
113MCAPI ::Scripting::QuickJS::RuntimeUserData* GetRuntimeUserDataFromContext(
::JSContext*
ctx);
115MCAPI
bool HasNativeObjectHandle(
::JSValue jsValue);
117MCAPI
void InitializeBakedProperties(
125MCAPI ::std::string JSAtomCStringToString(
::JSContext*
ctx, uint jsAtom);
131MCAPI
bool JSValueIsInfinite(
::JSValue const& value);
133MCAPI
bool JSValueIsNan(
::JSValue const& value);
135MCAPI ::std::variant<::entt::meta_any, ::JSValue>
138MCAPI ::std::variant<::entt::meta_any, ::JSValue> JSValueToNativeInterface(
142 ::entt::meta_type
const& type,
146MCAPI ::JSValue NativeAnyToJSProtoClass(
149 ::entt::meta_any& any,
154MCAPI ::JSValue NativeAnyToJSValue(
::JSContext*
ctx, ::entt::meta_any& any,
bool addRef,
bool allowCopy);
156MCAPI ::JSValue NativeEnumToJSValue(
::JSContext*
ctx, ::entt::meta_any& any,
bool addRef,
bool allowCopy);
158MCAPI ::JSValue NativeErrorToJSValue(
::JSContext*
ctx, ::entt::meta_any& any);
160MCAPI ::JSValue NativeErrorToJSValueInternal(
162 ::entt::meta_any& any,
167MCAPI ::JSValue NativeInterfaceToJSValue(
169 ::entt::meta_any& any,
175MCAPI ::JSValue NativeObjectHandleToJSProtoClass(
183MCAPI ::JSValue NativeObjectHandleToJSValue(
188 ::Scripting::QuickJS::NativeObjectOwnership allowCopy
191MCAPI ::JSValue NativeRegisteredEnumToJSValue(
193 ::entt::meta_any& any,
203MCAPI ::JSValue ThrowEngineErrorToJS(
::JSContext*
ctx, ::std::string
const& msg);
205MCAPI ::JSTypedArrayEnum ToJSTypedArrayEnum(::entt::meta_type
const& type);
211MCAPI
double anyToDouble(::entt::meta_any
const& any);
213MCAPI ::std::string anyToString(::entt::meta_any
const& any);
215MCAPI ::Scripting::StrongObjectHandle getHandleFromObjectFactory(
Definition LifetimeRegistry.h:16
Definition ContextUserData.h:17
Definition RegisteredClass.h:7
Definition RegisteredEnum.h:7
Definition RegisteredInterface.h:7
Definition IFunction.h:12
Definition InterfaceBinding.h:16
Definition IteratorBinding.h:15
Definition ObjectFactory.h:17
Definition ObjectHandle.h:7