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

Method createPropNameIDFromString

src/v8runtime/V8Runtime.cpp:607–620  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

605}
606
607jsi::PropNameID V8Runtime::createPropNameIDFromString(const jsi::String &str) {
608 v8::Locker locker(isolate_);
609 v8::Isolate::Scope scopedIsolate(isolate_);
610 v8::HandleScope scopedHandle(isolate_);
611 v8::Context::Scope scopedContext(context_.Get(isolate_));
612
613 const V8PointerValue *v8PointerValue =
614 static_cast<const V8PointerValue *>(getPointerValue(str));
615 assert(v8PointerValue->Get(isolate_)->IsString());
616
617 v8::String::Utf8Value utf8(isolate_, v8PointerValue->Get(isolate_));
618 return createPropNameIDFromUtf8(
619 reinterpret_cast<const uint8_t *>(*utf8), utf8.length());
620}
621
622#if REACT_NATIVE_MINOR_VERSION >= 69
623jsi::PropNameID V8Runtime::createPropNameIDFromSymbol(

Callers

nothing calls this directly

Calls 1

GetMethod · 0.80

Tested by

no test coverage detected