MCPcopy Create free account
hub / github.com/Kudo/react-native-v8 / createArray

Method createArray

src/v8runtime/V8Runtime.cpp:1295–1305  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1293}
1294
1295jsi::Array V8Runtime::createArray(size_t length) {
1296 v8::Locker locker(isolate_);
1297 v8::Isolate::Scope scopedIsolate(isolate_);
1298 v8::HandleScope scopedHandle(isolate_);
1299 v8::Context::Scope scopedContext(context_.Get(isolate_));
1300
1301 v8::Local<v8::Array> v8Array =
1302 v8::Array::New(isolate_, static_cast<int>(length));
1303 return make<jsi::Object>(new V8PointerValue(isolate_, v8Array))
1304 .getArray(*this);
1305}
1306
1307jsi::ArrayBuffer V8Runtime::createArrayBuffer(
1308 std::shared_ptr<jsi::MutableBuffer> buffer) {

Callers

nothing calls this directly

Calls 1

GetMethod · 0.80

Tested by

no test coverage detected