v8::Handle<v8::Object> V8TestCustomNamedGetter::createWrapper(PassRefPtr<TestCustomNamedGetter> impl, v8::Handle<v8::Object> creationContext, v8::Isolate* isolate) { ASSERT(impl.get()); ASSERT(DOMDataStore::getWrapper(impl.get(), isolate).IsEmpty()); #if ENABLE(BINDING_INTEGRITY) checkTypeOrDieTrying(impl.get()); #endif v8::Handle<v8::Object> wrapper = V8DOMWrapper::createWrapper(creationContext, &info, impl.get(), isolate); if (UNLIKELY(wrapper.IsEmpty())) return wrapper; installPerContextProperties(wrapper, impl.get(), isolate); V8DOMWrapper::associateObjectWithWrapper(impl, &info, wrapper, isolate, hasDependentLifetime ? WrapperConfiguration::Dependent : WrapperConfiguration::Independent); return wrapper; }
v8::Handle<v8::Object> V8TestException::createWrapper(PassRefPtr<TestException> impl, v8::Handle<v8::Object> creationContext, v8::Isolate* isolate) { ASSERT(impl.get()); ASSERT(DOMDataStore::getWrapper(impl.get(), isolate).IsEmpty()); #if ENABLE(BINDING_INTEGRITY) checkTypeOrDieTrying(impl.get()); #endif v8::Handle<v8::Object> wrapper = V8DOMWrapper::createWrapper(creationContext, &info, impl.get(), isolate); if (UNLIKELY(wrapper.IsEmpty())) return wrapper; installPerContextProperties(wrapper, impl.get(), isolate); v8::Persistent<v8::Object> wrapperHandle = V8DOMWrapper::associateObjectWithWrapper(impl, &info, wrapper, isolate); if (!hasDependentLifetime) wrapperHandle.MarkIndependent(); return wrapper; }