| 582 | } |
| 583 | |
| 584 | V8_EXPORT void PushArrayBufferForJSFunction(JSFunction *Function, unsigned char * Bytes, int Length) |
| 585 | { |
| 586 | auto Isolate = Function->ResultInfo.Isolate; |
| 587 | v8::Isolate::Scope IsolateScope(Isolate); |
| 588 | v8::HandleScope HandleScope(Isolate); |
| 589 | v8::Local<v8::Context> Context = Function->ResultInfo.Context.Get(Isolate); |
| 590 | v8::Context::Scope ContextScope(Context); |
| 591 | FValue Value; |
| 592 | Value.Type = puerts::ArrayBuffer; |
| 593 | Value.ArrayBuffer.Reset(Isolate, puerts::NewArrayBuffer(Isolate, Bytes, Length)); |
| 594 | Function->Arguments.push_back(std::move(Value)); |
| 595 | } |
| 596 | |
| 597 | V8_EXPORT void PushStringForJSFunction(JSFunction *Function, const char* S) |
| 598 | { |
nothing calls this directly
no test coverage detected