JSEvaluateScript top-level property

JSValueRef Function(JSContextRef ctx, JSStringRef script, JSObjectRef thisObject, JSStringRef sourceURL, int startingLineNumber, Pointer<JSValueRef> exception) JSEvaluateScript
final

Evaluates a string of JavaScript. ctx The execution context to use. script A JSString containing the script to evaluate. thisObject The object to use as "this," or NULL to use the global object as "this." sourceURL A JSString containing a URL for the script's source file. This is used by debuggers and when reporting exceptions. Pass NULL if you do not care to include source file information. startingLineNumber An integer value specifying the script's starting line number in the file located at sourceURL. This is only used when reporting exceptions. The value is one-based, so the first line is line 1 and invalid values are clamped to 1. exception A pointer to a JSValueRef in which to store an exception, if any. Pass NULL if you do not care to store an exception. @result The JSValue that results from evaluating script, or NULL if an exception is thrown.

Implementation

final JSValueRef Function(JSContextRef ctx, JSStringRef script, JSObjectRef thisObject, JSStringRef sourceURL, int startingLineNumber, Pointer<JSValueRef> exception) JSEvaluateScript = jscLib
    .lookup<NativeFunction<JSValueRef Function(JSContextRef ctx, JSStringRef script, JSObjectRef thisObject, JSStringRef sourceURL, Int32 startingLineNumber, Pointer<JSValueRef> exception)>>(
        'JSEvaluateScript')
    .asFunction();