Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(265)

Side by Side Diff: Source/bindings/tests/results/modules/V8TestInterfacePartial.cpp

Issue 1324643005: bindings: Makes installV8FooTemplate thread-safe. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Synced. Created 5 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « Source/bindings/tests/results/modules/V8TestInterface5.cpp ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // This file has been auto-generated by code_generator_v8.py. DO NOT MODIFY! 5 // This file has been auto-generated by code_generator_v8.py. DO NOT MODIFY!
6 6
7 #include "config.h" 7 #include "config.h"
8 #if ENABLE(CONDITION) 8 #if ENABLE(CONDITION)
9 #include "V8TestInterfacePartial.h" 9 #include "V8TestInterfacePartial.h"
10 10
(...skipping 213 matching lines...) Expand 10 before | Expand all | Expand 10 after
224 setMinimumArityTypeError(exceptionState, 1, info.Length()); 224 setMinimumArityTypeError(exceptionState, 1, info.Length());
225 exceptionState.throwIfNeeded(); 225 exceptionState.throwIfNeeded();
226 return; 226 return;
227 } 227 }
228 TestInterfaceImplementation* impl = V8TestInterface::toImpl(info.Holder()); 228 TestInterfaceImplementation* impl = V8TestInterface::toImpl(info.Holder());
229 V8StringResource<> arg; 229 V8StringResource<> arg;
230 { 230 {
231 arg = info[0]; 231 arg = info[0];
232 if (!arg.prepare()) 232 if (!arg.prepare())
233 return; 233 return;
234 static const char* validValues[] = { 234 const char* validValues[] = {
235 "EnumModulesValue1", 235 "EnumModulesValue1",
236 "EnumModulesValue2", 236 "EnumModulesValue2",
237 }; 237 };
238 if (!isValidEnum(arg, validValues, WTF_ARRAY_LENGTH(validValues), "TestE numModules", exceptionState)) { 238 if (!isValidEnum(arg, validValues, WTF_ARRAY_LENGTH(validValues), "TestE numModules", exceptionState)) {
239 exceptionState.throwIfNeeded(); 239 exceptionState.throwIfNeeded();
240 return; 240 return;
241 } 241 }
242 } 242 }
243 TestPartialInterfaceImplementation3::partialVoidTestEnumModulesArgMethod(*im pl, arg); 243 TestPartialInterfaceImplementation3::partialVoidTestEnumModulesArgMethod(*im pl, arg);
244 } 244 }
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
289 289
290 static void unscopeableVoidMethodMethodCallback(const v8::FunctionCallbackInfo<v 8::Value>& info) 290 static void unscopeableVoidMethodMethodCallback(const v8::FunctionCallbackInfo<v 8::Value>& info)
291 { 291 {
292 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMMethod"); 292 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMMethod");
293 TestInterfaceImplementationPartialV8Internal::unscopeableVoidMethodMethod(in fo); 293 TestInterfaceImplementationPartialV8Internal::unscopeableVoidMethodMethod(in fo);
294 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); 294 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
295 } 295 }
296 296
297 } // namespace TestInterfaceImplementationPartialV8Internal 297 } // namespace TestInterfaceImplementationPartialV8Internal
298 298
299 static const V8DOMConfiguration::MethodConfiguration V8TestInterfaceMethods[] = { 299 const V8DOMConfiguration::MethodConfiguration V8TestInterfaceMethods[] = {
300 {"partialVoidTestEnumModulesArgMethod", TestInterfaceImplementationPartialV8 Internal::partialVoidTestEnumModulesArgMethodMethodCallback, 0, 1, V8DOMConfigur ation::ExposedToAllScripts}, 300 {"partialVoidTestEnumModulesArgMethod", TestInterfaceImplementationPartialV8 Internal::partialVoidTestEnumModulesArgMethodMethodCallback, 0, 1, V8DOMConfigur ation::ExposedToAllScripts},
301 {"unscopeableVoidMethod", TestInterfaceImplementationPartialV8Internal::unsc opeableVoidMethodMethodCallback, 0, 0, V8DOMConfiguration::ExposedToAllScripts}, 301 {"unscopeableVoidMethod", TestInterfaceImplementationPartialV8Internal::unsc opeableVoidMethodMethodCallback, 0, 0, V8DOMConfiguration::ExposedToAllScripts},
302 }; 302 };
303 303
304 void V8TestInterfacePartial::installV8TestInterfaceTemplate(v8::Local<v8::Functi onTemplate> functionTemplate, v8::Isolate* isolate) 304 void V8TestInterfacePartial::installV8TestInterfaceTemplate(v8::Local<v8::Functi onTemplate> functionTemplate, v8::Isolate* isolate)
305 { 305 {
306 V8TestInterface::installV8TestInterfaceTemplate(functionTemplate, isolate); 306 V8TestInterface::installV8TestInterfaceTemplate(functionTemplate, isolate);
307 307
308 v8::Local<v8::Signature> defaultSignature; 308 v8::Local<v8::Signature> defaultSignature;
309 if (!RuntimeEnabledFeatures::featureNameEnabled()) 309 if (!RuntimeEnabledFeatures::featureNameEnabled())
310 defaultSignature = V8DOMConfiguration::installDOMClassTemplate(isolate, functionTemplate, "TestInterface", v8::Local<v8::FunctionTemplate>(), V8TestInte rface::internalFieldCount, 0, 0, 0, 0, 0, 0); 310 defaultSignature = V8DOMConfiguration::installDOMClassTemplate(isolate, functionTemplate, "TestInterface", v8::Local<v8::FunctionTemplate>(), V8TestInte rface::internalFieldCount, 0, 0, 0, 0, 0, 0);
311 else 311 else
312 defaultSignature = V8DOMConfiguration::installDOMClassTemplate(isolate, functionTemplate, "TestInterface", v8::Local<v8::FunctionTemplate>(), V8TestInte rface::internalFieldCount, 312 defaultSignature = V8DOMConfiguration::installDOMClassTemplate(isolate, functionTemplate, "TestInterface", v8::Local<v8::FunctionTemplate>(), V8TestInte rface::internalFieldCount,
313 0, 0, 313 0, 0,
314 0, 0, 314 0, 0,
315 V8TestInterfaceMethods, WTF_ARRAY_LENGTH(V8TestInterfaceMethods)); 315 V8TestInterfaceMethods, WTF_ARRAY_LENGTH(V8TestInterfaceMethods));
316 v8::Local<v8::ObjectTemplate> instanceTemplate = functionTemplate->InstanceT emplate(); 316 v8::Local<v8::ObjectTemplate> instanceTemplate = functionTemplate->InstanceT emplate();
317 ALLOW_UNUSED_LOCAL(instanceTemplate); 317 ALLOW_UNUSED_LOCAL(instanceTemplate);
318 v8::Local<v8::ObjectTemplate> prototypeTemplate = functionTemplate->Prototyp eTemplate(); 318 v8::Local<v8::ObjectTemplate> prototypeTemplate = functionTemplate->Prototyp eTemplate();
319 ALLOW_UNUSED_LOCAL(prototypeTemplate); 319 ALLOW_UNUSED_LOCAL(prototypeTemplate);
320 static const V8DOMConfiguration::ConstantConfiguration V8TestInterfaceConsta nts[] = { 320 const V8DOMConfiguration::ConstantConfiguration V8TestInterfaceConstants[] = {
321 {"PARTIAL3_UNSIGNED_SHORT", 0, 0, V8DOMConfiguration::ConstantTypeUnsign edShort}, 321 {"PARTIAL3_UNSIGNED_SHORT", 0, 0, V8DOMConfiguration::ConstantTypeUnsign edShort},
322 }; 322 };
323 V8DOMConfiguration::installConstants(isolate, functionTemplate, prototypeTem plate, V8TestInterfaceConstants, WTF_ARRAY_LENGTH(V8TestInterfaceConstants)); 323 V8DOMConfiguration::installConstants(isolate, functionTemplate, prototypeTem plate, V8TestInterfaceConstants, WTF_ARRAY_LENGTH(V8TestInterfaceConstants));
324 functionTemplate->InstanceTemplate()->SetCallAsFunctionHandler(V8TestInterfa ce::legacyCallCustom); 324 functionTemplate->InstanceTemplate()->SetCallAsFunctionHandler(V8TestInterfa ce::legacyCallCustom);
325 } 325 }
326 326
327 void V8TestInterfacePartial::preparePrototypeObject(v8::Isolate* isolate, v8::Lo cal<v8::Object> prototypeObject, v8::Local<v8::FunctionTemplate> interfaceTempla te) 327 void V8TestInterfacePartial::preparePrototypeObject(v8::Isolate* isolate, v8::Lo cal<v8::Object> prototypeObject, v8::Local<v8::FunctionTemplate> interfaceTempla te)
328 { 328 {
329 V8TestInterface::preparePrototypeObject(isolate, prototypeObject, interfaceT emplate); 329 V8TestInterface::preparePrototypeObject(isolate, prototypeObject, interfaceT emplate);
330 v8::Local<v8::Context> v8Context(prototypeObject->CreationContext()); 330 v8::Local<v8::Context> v8Context(prototypeObject->CreationContext());
(...skipping 16 matching lines...) Expand all
347 V8TestInterface::registerVoidMethodPartialOverloadMethodForPartialInterface( &TestInterfaceImplementationPartialV8Internal::voidMethodPartialOverloadMethod); 347 V8TestInterface::registerVoidMethodPartialOverloadMethodForPartialInterface( &TestInterfaceImplementationPartialV8Internal::voidMethodPartialOverloadMethod);
348 V8TestInterface::registerStaticVoidMethodPartialOverloadMethodForPartialInte rface(&TestInterfaceImplementationPartialV8Internal::staticVoidMethodPartialOver loadMethod); 348 V8TestInterface::registerStaticVoidMethodPartialOverloadMethodForPartialInte rface(&TestInterfaceImplementationPartialV8Internal::staticVoidMethodPartialOver loadMethod);
349 V8TestInterface::registerPromiseMethodPartialOverloadMethodForPartialInterfa ce(&TestInterfaceImplementationPartialV8Internal::promiseMethodPartialOverloadMe thod); 349 V8TestInterface::registerPromiseMethodPartialOverloadMethodForPartialInterfa ce(&TestInterfaceImplementationPartialV8Internal::promiseMethodPartialOverloadMe thod);
350 V8TestInterface::registerStaticPromiseMethodPartialOverloadMethodForPartialI nterface(&TestInterfaceImplementationPartialV8Internal::staticPromiseMethodParti alOverloadMethod); 350 V8TestInterface::registerStaticPromiseMethodPartialOverloadMethodForPartialI nterface(&TestInterfaceImplementationPartialV8Internal::staticPromiseMethodParti alOverloadMethod);
351 V8TestInterface::registerPartial2VoidMethodMethodForPartialInterface(&TestIn terfaceImplementationPartialV8Internal::partial2VoidMethodMethod); 351 V8TestInterface::registerPartial2VoidMethodMethodForPartialInterface(&TestIn terfaceImplementationPartialV8Internal::partial2VoidMethodMethod);
352 V8TestInterface::registerPartial2StaticVoidMethodMethodForPartialInterface(& TestInterfaceImplementationPartialV8Internal::partial2StaticVoidMethodMethod); 352 V8TestInterface::registerPartial2StaticVoidMethodMethodForPartialInterface(& TestInterfaceImplementationPartialV8Internal::partial2StaticVoidMethodMethod);
353 } 353 }
354 354
355 } // namespace blink 355 } // namespace blink
356 #endif // ENABLE(CONDITION) 356 #endif // ENABLE(CONDITION)
OLDNEW
« no previous file with comments | « Source/bindings/tests/results/modules/V8TestInterface5.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698