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

Side by Side Diff: Source/bindings/tests/results/core/V8TestInterface.cpp

Issue 1193793003: bindings: Makes almost all attributes accessor-type properties. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Synced. Created 5 years, 5 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
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 "V8TestInterface.h" 9 #include "V8TestInterface.h"
10 10
(...skipping 333 matching lines...) Expand 10 before | Expand all | Expand 10 after
344 } 344 }
345 345
346 static void stringOrDoubleAttributeAttributeSetterCallback(const v8::FunctionCal lbackInfo<v8::Value>& info) 346 static void stringOrDoubleAttributeAttributeSetterCallback(const v8::FunctionCal lbackInfo<v8::Value>& info)
347 { 347 {
348 v8::Local<v8::Value> v8Value = info[0]; 348 v8::Local<v8::Value> v8Value = info[0];
349 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMSetter"); 349 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMSetter");
350 TestInterfaceImplementationV8Internal::stringOrDoubleAttributeAttributeSette r(v8Value, info); 350 TestInterfaceImplementationV8Internal::stringOrDoubleAttributeAttributeSette r(v8Value, info);
351 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); 351 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
352 } 352 }
353 353
354 static void staticStringAttributeAttributeGetter(const v8::PropertyCallbackInfo< v8::Value>& info) 354 static void staticStringAttributeAttributeGetter(const v8::FunctionCallbackInfo< v8::Value>& info)
355 { 355 {
356 v8SetReturnValueString(info, TestInterfaceImplementation::staticStringAttrib ute(), info.GetIsolate()); 356 v8SetReturnValueString(info, TestInterfaceImplementation::staticStringAttrib ute(), info.GetIsolate());
357 } 357 }
358 358
359 static void staticStringAttributeAttributeGetterCallback(v8::Local<v8::Name>, co nst v8::PropertyCallbackInfo<v8::Value>& info) 359 static void staticStringAttributeAttributeGetterCallback(const v8::FunctionCallb ackInfo<v8::Value>& info)
360 { 360 {
361 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMGetter"); 361 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMGetter");
362 TestInterfaceImplementationV8Internal::staticStringAttributeAttributeGetter( info); 362 TestInterfaceImplementationV8Internal::staticStringAttributeAttributeGetter( info);
363 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); 363 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
364 } 364 }
365 365
366 static void staticStringAttributeAttributeSetter(v8::Local<v8::Value> v8Value, c onst v8::PropertyCallbackInfo<void>& info) 366 static void staticStringAttributeAttributeSetter(v8::Local<v8::Value> v8Value, c onst v8::FunctionCallbackInfo<v8::Value>& info)
367 { 367 {
368 V8StringResource<> cppValue = v8Value; 368 V8StringResource<> cppValue = v8Value;
369 if (!cppValue.prepare()) 369 if (!cppValue.prepare())
370 return; 370 return;
371 TestInterfaceImplementation::setStaticStringAttribute(cppValue); 371 TestInterfaceImplementation::setStaticStringAttribute(cppValue);
372 } 372 }
373 373
374 static void staticStringAttributeAttributeSetterCallback(v8::Local<v8::Name>, v8 ::Local<v8::Value> v8Value, const v8::PropertyCallbackInfo<void>& info) 374 static void staticStringAttributeAttributeSetterCallback(const v8::FunctionCallb ackInfo<v8::Value>& info)
375 { 375 {
376 v8::Local<v8::Value> v8Value = info[0];
376 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMSetter"); 377 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMSetter");
377 TestInterfaceImplementationV8Internal::staticStringAttributeAttributeSetter( v8Value, info); 378 TestInterfaceImplementationV8Internal::staticStringAttributeAttributeSetter( v8Value, info);
378 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); 379 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
379 } 380 }
380 381
381 static void staticReturnDOMWrapperAttributeAttributeGetter(const v8::PropertyCal lbackInfo<v8::Value>& info) 382 static void staticReturnDOMWrapperAttributeAttributeGetter(const v8::FunctionCal lbackInfo<v8::Value>& info)
382 { 383 {
383 v8SetReturnValue(info, TestInterfaceImplementation::staticReturnDOMWrapperAt tribute(), info.GetIsolate()->GetCurrentContext()->Global()); 384 v8SetReturnValue(info, TestInterfaceImplementation::staticReturnDOMWrapperAt tribute(), info.GetIsolate()->GetCurrentContext()->Global());
384 } 385 }
385 386
386 static void staticReturnDOMWrapperAttributeAttributeGetterCallback(v8::Local<v8: :Name>, const v8::PropertyCallbackInfo<v8::Value>& info) 387 static void staticReturnDOMWrapperAttributeAttributeGetterCallback(const v8::Fun ctionCallbackInfo<v8::Value>& info)
387 { 388 {
388 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMGetter"); 389 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMGetter");
389 TestInterfaceImplementationV8Internal::staticReturnDOMWrapperAttributeAttrib uteGetter(info); 390 TestInterfaceImplementationV8Internal::staticReturnDOMWrapperAttributeAttrib uteGetter(info);
390 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); 391 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
391 } 392 }
392 393
393 static void staticReturnDOMWrapperAttributeAttributeSetter(v8::Local<v8::Value> v8Value, const v8::PropertyCallbackInfo<void>& info) 394 static void staticReturnDOMWrapperAttributeAttributeSetter(v8::Local<v8::Value> v8Value, const v8::FunctionCallbackInfo<v8::Value>& info)
394 { 395 {
395 v8::Local<v8::Object> holder = info.Holder(); 396 v8::Local<v8::Object> holder = info.Holder();
396 ExceptionState exceptionState(ExceptionState::SetterContext, "staticReturnDO MWrapperAttribute", "TestInterface", holder, info.GetIsolate()); 397 ExceptionState exceptionState(ExceptionState::SetterContext, "staticReturnDO MWrapperAttribute", "TestInterface", holder, info.GetIsolate());
397 TestInterfaceImplementation* cppValue = V8TestInterface::toImplWithTypeCheck (info.GetIsolate(), v8Value); 398 TestInterfaceImplementation* cppValue = V8TestInterface::toImplWithTypeCheck (info.GetIsolate(), v8Value);
398 if (!cppValue) { 399 if (!cppValue) {
399 exceptionState.throwTypeError("The provided value is not of type 'TestIn terface'."); 400 exceptionState.throwTypeError("The provided value is not of type 'TestIn terface'.");
400 exceptionState.throwIfNeeded(); 401 exceptionState.throwIfNeeded();
401 return; 402 return;
402 } 403 }
403 TestInterfaceImplementation::setStaticReturnDOMWrapperAttribute(WTF::getPtr( cppValue)); 404 TestInterfaceImplementation::setStaticReturnDOMWrapperAttribute(WTF::getPtr( cppValue));
404 } 405 }
405 406
406 static void staticReturnDOMWrapperAttributeAttributeSetterCallback(v8::Local<v8: :Name>, v8::Local<v8::Value> v8Value, const v8::PropertyCallbackInfo<void>& info ) 407 static void staticReturnDOMWrapperAttributeAttributeSetterCallback(const v8::Fun ctionCallbackInfo<v8::Value>& info)
407 { 408 {
409 v8::Local<v8::Value> v8Value = info[0];
408 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMSetter"); 410 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMSetter");
409 TestInterfaceImplementationV8Internal::staticReturnDOMWrapperAttributeAttrib uteSetter(v8Value, info); 411 TestInterfaceImplementationV8Internal::staticReturnDOMWrapperAttributeAttrib uteSetter(v8Value, info);
410 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); 412 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
411 } 413 }
412 414
413 static void legacyInterfaceTypeCheckingAttributeAttributeGetter(const v8::Functi onCallbackInfo<v8::Value>& info) 415 static void legacyInterfaceTypeCheckingAttributeAttributeGetter(const v8::Functi onCallbackInfo<v8::Value>& info)
414 { 416 {
415 v8::Local<v8::Object> holder = info.Holder(); 417 v8::Local<v8::Object> holder = info.Holder();
416 TestInterfaceImplementation* impl = V8TestInterface::toImpl(holder); 418 TestInterfaceImplementation* impl = V8TestInterface::toImpl(holder);
417 v8SetReturnValueFast(info, WTF::getPtr(impl->legacyInterfaceTypeCheckingAttr ibute()), impl); 419 v8SetReturnValueFast(info, WTF::getPtr(impl->legacyInterfaceTypeCheckingAttr ibute()), impl);
(...skipping 152 matching lines...) Expand 10 before | Expand all | Expand 10 after
570 } 572 }
571 573
572 static void lenientThisAttributeAttributeSetterCallback(const v8::FunctionCallba ckInfo<v8::Value>& info) 574 static void lenientThisAttributeAttributeSetterCallback(const v8::FunctionCallba ckInfo<v8::Value>& info)
573 { 575 {
574 v8::Local<v8::Value> v8Value = info[0]; 576 v8::Local<v8::Value> v8Value = info[0];
575 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMSetter"); 577 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMSetter");
576 TestInterfaceImplementationV8Internal::lenientThisAttributeAttributeSetter(v 8Value, info); 578 TestInterfaceImplementationV8Internal::lenientThisAttributeAttributeSetter(v 8Value, info);
577 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); 579 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
578 } 580 }
579 581
580 static void implementsStaticReadOnlyLongAttributeAttributeGetter(const v8::Prope rtyCallbackInfo<v8::Value>& info) 582 static void implementsStaticReadOnlyLongAttributeAttributeGetter(const v8::Funct ionCallbackInfo<v8::Value>& info)
581 { 583 {
582 v8SetReturnValueInt(info, TestInterfaceImplementation::implementsStaticReadO nlyLongAttribute()); 584 v8SetReturnValueInt(info, TestInterfaceImplementation::implementsStaticReadO nlyLongAttribute());
583 } 585 }
584 586
585 static void implementsStaticReadOnlyLongAttributeAttributeGetterCallback(v8::Loc al<v8::Name>, const v8::PropertyCallbackInfo<v8::Value>& info) 587 static void implementsStaticReadOnlyLongAttributeAttributeGetterCallback(const v 8::FunctionCallbackInfo<v8::Value>& info)
586 { 588 {
587 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMGetter"); 589 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMGetter");
588 TestInterfaceImplementationV8Internal::implementsStaticReadOnlyLongAttribute AttributeGetter(info); 590 TestInterfaceImplementationV8Internal::implementsStaticReadOnlyLongAttribute AttributeGetter(info);
589 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); 591 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
590 } 592 }
591 593
592 static void implementsStaticStringAttributeAttributeGetter(const v8::PropertyCal lbackInfo<v8::Value>& info) 594 static void implementsStaticStringAttributeAttributeGetter(const v8::FunctionCal lbackInfo<v8::Value>& info)
593 { 595 {
594 v8SetReturnValueString(info, TestInterfaceImplementation::implementsStaticSt ringAttribute(), info.GetIsolate()); 596 v8SetReturnValueString(info, TestInterfaceImplementation::implementsStaticSt ringAttribute(), info.GetIsolate());
595 } 597 }
596 598
597 static void implementsStaticStringAttributeAttributeGetterCallback(v8::Local<v8: :Name>, const v8::PropertyCallbackInfo<v8::Value>& info) 599 static void implementsStaticStringAttributeAttributeGetterCallback(const v8::Fun ctionCallbackInfo<v8::Value>& info)
598 { 600 {
599 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMGetter"); 601 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMGetter");
600 TestInterfaceImplementationV8Internal::implementsStaticStringAttributeAttrib uteGetter(info); 602 TestInterfaceImplementationV8Internal::implementsStaticStringAttributeAttrib uteGetter(info);
601 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); 603 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
602 } 604 }
603 605
604 static void implementsStaticStringAttributeAttributeSetter(v8::Local<v8::Value> v8Value, const v8::PropertyCallbackInfo<void>& info) 606 static void implementsStaticStringAttributeAttributeSetter(v8::Local<v8::Value> v8Value, const v8::FunctionCallbackInfo<v8::Value>& info)
605 { 607 {
606 V8StringResource<> cppValue = v8Value; 608 V8StringResource<> cppValue = v8Value;
607 if (!cppValue.prepare()) 609 if (!cppValue.prepare())
608 return; 610 return;
609 TestInterfaceImplementation::setImplementsStaticStringAttribute(cppValue); 611 TestInterfaceImplementation::setImplementsStaticStringAttribute(cppValue);
610 } 612 }
611 613
612 static void implementsStaticStringAttributeAttributeSetterCallback(v8::Local<v8: :Name>, v8::Local<v8::Value> v8Value, const v8::PropertyCallbackInfo<void>& info ) 614 static void implementsStaticStringAttributeAttributeSetterCallback(const v8::Fun ctionCallbackInfo<v8::Value>& info)
613 { 615 {
616 v8::Local<v8::Value> v8Value = info[0];
614 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMSetter"); 617 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMSetter");
615 TestInterfaceImplementationV8Internal::implementsStaticStringAttributeAttrib uteSetter(v8Value, info); 618 TestInterfaceImplementationV8Internal::implementsStaticStringAttributeAttrib uteSetter(v8Value, info);
616 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); 619 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
617 } 620 }
618 621
619 static void implementsReadonlyStringAttributeAttributeGetter(const v8::FunctionC allbackInfo<v8::Value>& info) 622 static void implementsReadonlyStringAttributeAttributeGetter(const v8::FunctionC allbackInfo<v8::Value>& info)
620 { 623 {
621 v8::Local<v8::Object> holder = info.Holder(); 624 v8::Local<v8::Object> holder = info.Holder();
622 TestInterfaceImplementation* impl = V8TestInterface::toImpl(holder); 625 TestInterfaceImplementation* impl = V8TestInterface::toImpl(holder);
623 v8SetReturnValueString(info, impl->implementsReadonlyStringAttribute(), info .GetIsolate()); 626 v8SetReturnValueString(info, impl->implementsReadonlyStringAttribute(), info .GetIsolate());
(...skipping 134 matching lines...) Expand 10 before | Expand all | Expand 10 after
758 } 761 }
759 762
760 static void implementsRuntimeEnabledNodeAttributeAttributeSetterCallback(const v 8::FunctionCallbackInfo<v8::Value>& info) 763 static void implementsRuntimeEnabledNodeAttributeAttributeSetterCallback(const v 8::FunctionCallbackInfo<v8::Value>& info)
761 { 764 {
762 v8::Local<v8::Value> v8Value = info[0]; 765 v8::Local<v8::Value> v8Value = info[0];
763 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMSetter"); 766 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMSetter");
764 TestInterfaceImplementationV8Internal::implementsRuntimeEnabledNodeAttribute AttributeSetter(v8Value, info); 767 TestInterfaceImplementationV8Internal::implementsRuntimeEnabledNodeAttribute AttributeSetter(v8Value, info);
765 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); 768 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
766 } 769 }
767 770
768 static void implements2StaticStringAttributeAttributeGetter(const v8::PropertyCa llbackInfo<v8::Value>& info) 771 static void implements2StaticStringAttributeAttributeGetter(const v8::FunctionCa llbackInfo<v8::Value>& info)
769 { 772 {
770 v8SetReturnValueString(info, TestImplements2::implements2StaticStringAttribu te(), info.GetIsolate()); 773 v8SetReturnValueString(info, TestImplements2::implements2StaticStringAttribu te(), info.GetIsolate());
771 } 774 }
772 775
773 static void implements2StaticStringAttributeAttributeGetterCallback(v8::Local<v8 ::Name>, const v8::PropertyCallbackInfo<v8::Value>& info) 776 static void implements2StaticStringAttributeAttributeGetterCallback(const v8::Fu nctionCallbackInfo<v8::Value>& info)
774 { 777 {
775 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMGetter"); 778 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMGetter");
776 TestInterfaceImplementationV8Internal::implements2StaticStringAttributeAttri buteGetter(info); 779 TestInterfaceImplementationV8Internal::implements2StaticStringAttributeAttri buteGetter(info);
777 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); 780 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
778 } 781 }
779 782
780 static void implements2StaticStringAttributeAttributeSetter(v8::Local<v8::Value> v8Value, const v8::PropertyCallbackInfo<void>& info) 783 static void implements2StaticStringAttributeAttributeSetter(v8::Local<v8::Value> v8Value, const v8::FunctionCallbackInfo<v8::Value>& info)
781 { 784 {
782 V8StringResource<> cppValue = v8Value; 785 V8StringResource<> cppValue = v8Value;
783 if (!cppValue.prepare()) 786 if (!cppValue.prepare())
784 return; 787 return;
785 TestImplements2::setImplements2StaticStringAttribute(cppValue); 788 TestImplements2::setImplements2StaticStringAttribute(cppValue);
786 } 789 }
787 790
788 static void implements2StaticStringAttributeAttributeSetterCallback(v8::Local<v8 ::Name>, v8::Local<v8::Value> v8Value, const v8::PropertyCallbackInfo<void>& inf o) 791 static void implements2StaticStringAttributeAttributeSetterCallback(const v8::Fu nctionCallbackInfo<v8::Value>& info)
789 { 792 {
793 v8::Local<v8::Value> v8Value = info[0];
790 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMSetter"); 794 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMSetter");
791 TestInterfaceImplementationV8Internal::implements2StaticStringAttributeAttri buteSetter(v8Value, info); 795 TestInterfaceImplementationV8Internal::implements2StaticStringAttributeAttri buteSetter(v8Value, info);
792 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); 796 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
793 } 797 }
794 798
795 static void implements2StringAttributeAttributeGetter(const v8::FunctionCallback Info<v8::Value>& info) 799 static void implements2StringAttributeAttributeGetter(const v8::FunctionCallback Info<v8::Value>& info)
796 { 800 {
797 v8::Local<v8::Object> holder = info.Holder(); 801 v8::Local<v8::Object> holder = info.Holder();
798 TestInterfaceImplementation* impl = V8TestInterface::toImpl(holder); 802 TestInterfaceImplementation* impl = V8TestInterface::toImpl(holder);
799 v8SetReturnValueString(info, TestImplements2::implements2StringAttribute(*im pl), info.GetIsolate()); 803 v8SetReturnValueString(info, TestImplements2::implements2StringAttribute(*im pl), info.GetIsolate());
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after
849 } 853 }
850 854
851 static void implements3StringAttributeAttributeSetterCallback(const v8::Function CallbackInfo<v8::Value>& info) 855 static void implements3StringAttributeAttributeSetterCallback(const v8::Function CallbackInfo<v8::Value>& info)
852 { 856 {
853 v8::Local<v8::Value> v8Value = info[0]; 857 v8::Local<v8::Value> v8Value = info[0];
854 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMSetter"); 858 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMSetter");
855 TestInterfaceImplementationV8Internal::implements3StringAttributeAttributeSe tter(v8Value, info); 859 TestInterfaceImplementationV8Internal::implements3StringAttributeAttributeSe tter(v8Value, info);
856 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); 860 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
857 } 861 }
858 862
859 static void implements3StaticStringAttributeAttributeGetter(const v8::PropertyCa llbackInfo<v8::Value>& info) 863 static void implements3StaticStringAttributeAttributeGetter(const v8::FunctionCa llbackInfo<v8::Value>& info)
860 { 864 {
861 v8SetReturnValueString(info, TestImplements3Implementation::implements3Stati cStringAttribute(), info.GetIsolate()); 865 v8SetReturnValueString(info, TestImplements3Implementation::implements3Stati cStringAttribute(), info.GetIsolate());
862 } 866 }
863 867
864 static void implements3StaticStringAttributeAttributeGetterCallback(v8::Local<v8 ::Name>, const v8::PropertyCallbackInfo<v8::Value>& info) 868 static void implements3StaticStringAttributeAttributeGetterCallback(const v8::Fu nctionCallbackInfo<v8::Value>& info)
865 { 869 {
866 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMGetter"); 870 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMGetter");
867 TestInterfaceImplementationV8Internal::implements3StaticStringAttributeAttri buteGetter(info); 871 TestInterfaceImplementationV8Internal::implements3StaticStringAttributeAttri buteGetter(info);
868 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); 872 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
869 } 873 }
870 874
871 static void implements3StaticStringAttributeAttributeSetter(v8::Local<v8::Value> v8Value, const v8::PropertyCallbackInfo<void>& info) 875 static void implements3StaticStringAttributeAttributeSetter(v8::Local<v8::Value> v8Value, const v8::FunctionCallbackInfo<v8::Value>& info)
872 { 876 {
873 V8StringResource<> cppValue = v8Value; 877 V8StringResource<> cppValue = v8Value;
874 if (!cppValue.prepare()) 878 if (!cppValue.prepare())
875 return; 879 return;
876 TestImplements3Implementation::setImplements3StaticStringAttribute(cppValue) ; 880 TestImplements3Implementation::setImplements3StaticStringAttribute(cppValue) ;
877 } 881 }
878 882
879 static void implements3StaticStringAttributeAttributeSetterCallback(v8::Local<v8 ::Name>, v8::Local<v8::Value> v8Value, const v8::PropertyCallbackInfo<void>& inf o) 883 static void implements3StaticStringAttributeAttributeSetterCallback(const v8::Fu nctionCallbackInfo<v8::Value>& info)
880 { 884 {
885 v8::Local<v8::Value> v8Value = info[0];
881 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMSetter"); 886 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMSetter");
882 TestInterfaceImplementationV8Internal::implements3StaticStringAttributeAttri buteSetter(v8Value, info); 887 TestInterfaceImplementationV8Internal::implements3StaticStringAttributeAttri buteSetter(v8Value, info);
883 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); 888 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
884 } 889 }
885 890
886 #if ENABLE(PARTIAL_CONDITION) 891 #if ENABLE(PARTIAL_CONDITION)
887 static void partialLongAttributeAttributeGetter(const v8::FunctionCallbackInfo<v 8::Value>& info) 892 static void partialLongAttributeAttributeGetter(const v8::FunctionCallbackInfo<v 8::Value>& info)
888 { 893 {
889 v8::Local<v8::Object> holder = info.Holder(); 894 v8::Local<v8::Object> holder = info.Holder();
890 TestInterfaceImplementation* impl = V8TestInterface::toImpl(holder); 895 TestInterfaceImplementation* impl = V8TestInterface::toImpl(holder);
(...skipping 27 matching lines...) Expand all
918 static void partialLongAttributeAttributeSetterCallback(const v8::FunctionCallba ckInfo<v8::Value>& info) 923 static void partialLongAttributeAttributeSetterCallback(const v8::FunctionCallba ckInfo<v8::Value>& info)
919 { 924 {
920 v8::Local<v8::Value> v8Value = info[0]; 925 v8::Local<v8::Value> v8Value = info[0];
921 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMSetter"); 926 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMSetter");
922 TestInterfaceImplementationV8Internal::partialLongAttributeAttributeSetter(v 8Value, info); 927 TestInterfaceImplementationV8Internal::partialLongAttributeAttributeSetter(v 8Value, info);
923 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); 928 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
924 } 929 }
925 #endif // ENABLE(PARTIAL_CONDITION) 930 #endif // ENABLE(PARTIAL_CONDITION)
926 931
927 #if ENABLE(PARTIAL_CONDITION) 932 #if ENABLE(PARTIAL_CONDITION)
928 static void partialStaticLongAttributeAttributeGetter(const v8::PropertyCallback Info<v8::Value>& info) 933 static void partialStaticLongAttributeAttributeGetter(const v8::FunctionCallback Info<v8::Value>& info)
929 { 934 {
930 v8SetReturnValueInt(info, TestPartialInterface::partialStaticLongAttribute() ); 935 v8SetReturnValueInt(info, TestPartialInterface::partialStaticLongAttribute() );
931 } 936 }
932 #endif // ENABLE(PARTIAL_CONDITION) 937 #endif // ENABLE(PARTIAL_CONDITION)
933 938
934 #if ENABLE(PARTIAL_CONDITION) 939 #if ENABLE(PARTIAL_CONDITION)
935 static void partialStaticLongAttributeAttributeGetterCallback(v8::Local<v8::Name >, const v8::PropertyCallbackInfo<v8::Value>& info) 940 static void partialStaticLongAttributeAttributeGetterCallback(const v8::Function CallbackInfo<v8::Value>& info)
936 { 941 {
937 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMGetter"); 942 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMGetter");
938 TestInterfaceImplementationV8Internal::partialStaticLongAttributeAttributeGe tter(info); 943 TestInterfaceImplementationV8Internal::partialStaticLongAttributeAttributeGe tter(info);
939 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); 944 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
940 } 945 }
941 #endif // ENABLE(PARTIAL_CONDITION) 946 #endif // ENABLE(PARTIAL_CONDITION)
942 947
943 #if ENABLE(PARTIAL_CONDITION) 948 #if ENABLE(PARTIAL_CONDITION)
944 static void partialStaticLongAttributeAttributeSetter(v8::Local<v8::Value> v8Val ue, const v8::PropertyCallbackInfo<void>& info) 949 static void partialStaticLongAttributeAttributeSetter(v8::Local<v8::Value> v8Val ue, const v8::FunctionCallbackInfo<v8::Value>& info)
945 { 950 {
946 v8::Local<v8::Object> holder = info.Holder(); 951 v8::Local<v8::Object> holder = info.Holder();
947 ExceptionState exceptionState(ExceptionState::SetterContext, "partialStaticL ongAttribute", "TestInterface", holder, info.GetIsolate()); 952 ExceptionState exceptionState(ExceptionState::SetterContext, "partialStaticL ongAttribute", "TestInterface", holder, info.GetIsolate());
948 int cppValue = toInt32(info.GetIsolate(), v8Value, NormalConversion, excepti onState); 953 int cppValue = toInt32(info.GetIsolate(), v8Value, NormalConversion, excepti onState);
949 if (exceptionState.throwIfNeeded()) 954 if (exceptionState.throwIfNeeded())
950 return; 955 return;
951 TestPartialInterface::setPartialStaticLongAttribute(cppValue); 956 TestPartialInterface::setPartialStaticLongAttribute(cppValue);
952 } 957 }
953 #endif // ENABLE(PARTIAL_CONDITION) 958 #endif // ENABLE(PARTIAL_CONDITION)
954 959
955 #if ENABLE(PARTIAL_CONDITION) 960 #if ENABLE(PARTIAL_CONDITION)
956 static void partialStaticLongAttributeAttributeSetterCallback(v8::Local<v8::Name >, v8::Local<v8::Value> v8Value, const v8::PropertyCallbackInfo<void>& info) 961 static void partialStaticLongAttributeAttributeSetterCallback(const v8::Function CallbackInfo<v8::Value>& info)
957 { 962 {
963 v8::Local<v8::Value> v8Value = info[0];
958 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMSetter"); 964 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMSetter");
959 TestInterfaceImplementationV8Internal::partialStaticLongAttributeAttributeSe tter(v8Value, info); 965 TestInterfaceImplementationV8Internal::partialStaticLongAttributeAttributeSe tter(v8Value, info);
960 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); 966 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
961 } 967 }
962 #endif // ENABLE(PARTIAL_CONDITION) 968 #endif // ENABLE(PARTIAL_CONDITION)
963 969
964 #if ENABLE(PARTIAL_CONDITION) 970 #if ENABLE(PARTIAL_CONDITION)
965 static void partialCallWithExecutionContextLongAttributeAttributeGetter(const v8 ::FunctionCallbackInfo<v8::Value>& info) 971 static void partialCallWithExecutionContextLongAttributeAttributeGetter(const v8 ::FunctionCallbackInfo<v8::Value>& info)
966 { 972 {
967 v8::Local<v8::Object> holder = info.Holder(); 973 v8::Local<v8::Object> holder = info.Holder();
(...skipping 154 matching lines...) Expand 10 before | Expand all | Expand 10 after
1122 } 1128 }
1123 1129
1124 static void partial2LongAttributeAttributeSetterCallback(const v8::FunctionCallb ackInfo<v8::Value>& info) 1130 static void partial2LongAttributeAttributeSetterCallback(const v8::FunctionCallb ackInfo<v8::Value>& info)
1125 { 1131 {
1126 v8::Local<v8::Value> v8Value = info[0]; 1132 v8::Local<v8::Value> v8Value = info[0];
1127 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMSetter"); 1133 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMSetter");
1128 TestInterfaceImplementationV8Internal::partial2LongAttributeAttributeSetter( v8Value, info); 1134 TestInterfaceImplementationV8Internal::partial2LongAttributeAttributeSetter( v8Value, info);
1129 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); 1135 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
1130 } 1136 }
1131 1137
1132 static void partial2StaticLongAttributeAttributeGetter(const v8::PropertyCallbac kInfo<v8::Value>& info) 1138 static void partial2StaticLongAttributeAttributeGetter(const v8::FunctionCallbac kInfo<v8::Value>& info)
1133 { 1139 {
1134 v8SetReturnValueInt(info, TestPartialInterfaceImplementation::partial2Static LongAttribute()); 1140 v8SetReturnValueInt(info, TestPartialInterfaceImplementation::partial2Static LongAttribute());
1135 } 1141 }
1136 1142
1137 static void partial2StaticLongAttributeAttributeGetterCallback(v8::Local<v8::Nam e>, const v8::PropertyCallbackInfo<v8::Value>& info) 1143 static void partial2StaticLongAttributeAttributeGetterCallback(const v8::Functio nCallbackInfo<v8::Value>& info)
1138 { 1144 {
1139 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMGetter"); 1145 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMGetter");
1140 TestInterfaceImplementationV8Internal::partial2StaticLongAttributeAttributeG etter(info); 1146 TestInterfaceImplementationV8Internal::partial2StaticLongAttributeAttributeG etter(info);
1141 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); 1147 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
1142 } 1148 }
1143 1149
1144 static void partial2StaticLongAttributeAttributeSetter(v8::Local<v8::Value> v8Va lue, const v8::PropertyCallbackInfo<void>& info) 1150 static void partial2StaticLongAttributeAttributeSetter(v8::Local<v8::Value> v8Va lue, const v8::FunctionCallbackInfo<v8::Value>& info)
1145 { 1151 {
1146 v8::Local<v8::Object> holder = info.Holder(); 1152 v8::Local<v8::Object> holder = info.Holder();
1147 ExceptionState exceptionState(ExceptionState::SetterContext, "partial2Static LongAttribute", "TestInterface", holder, info.GetIsolate()); 1153 ExceptionState exceptionState(ExceptionState::SetterContext, "partial2Static LongAttribute", "TestInterface", holder, info.GetIsolate());
1148 int cppValue = toInt32(info.GetIsolate(), v8Value, NormalConversion, excepti onState); 1154 int cppValue = toInt32(info.GetIsolate(), v8Value, NormalConversion, excepti onState);
1149 if (exceptionState.throwIfNeeded()) 1155 if (exceptionState.throwIfNeeded())
1150 return; 1156 return;
1151 TestPartialInterfaceImplementation::setPartial2StaticLongAttribute(cppValue) ; 1157 TestPartialInterfaceImplementation::setPartial2StaticLongAttribute(cppValue) ;
1152 } 1158 }
1153 1159
1154 static void partial2StaticLongAttributeAttributeSetterCallback(v8::Local<v8::Nam e>, v8::Local<v8::Value> v8Value, const v8::PropertyCallbackInfo<void>& info) 1160 static void partial2StaticLongAttributeAttributeSetterCallback(const v8::Functio nCallbackInfo<v8::Value>& info)
1155 { 1161 {
1162 v8::Local<v8::Value> v8Value = info[0];
1156 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMSetter"); 1163 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMSetter");
1157 TestInterfaceImplementationV8Internal::partial2StaticLongAttributeAttributeS etter(v8Value, info); 1164 TestInterfaceImplementationV8Internal::partial2StaticLongAttributeAttributeS etter(v8Value, info);
1158 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); 1165 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
1159 } 1166 }
1160 1167
1161 static void voidMethodTestInterfaceEmptyArgMethod(const v8::FunctionCallbackInfo <v8::Value>& info) 1168 static void voidMethodTestInterfaceEmptyArgMethod(const v8::FunctionCallbackInfo <v8::Value>& info)
1162 { 1169 {
1163 if (UNLIKELY(info.Length() < 1)) { 1170 if (UNLIKELY(info.Length() < 1)) {
1164 V8ThrowException::throwException(createMinimumArityTypeErrorForMethod(in fo.GetIsolate(), "voidMethodTestInterfaceEmptyArg", "TestInterface", 1, info.Len gth()), info.GetIsolate()); 1171 V8ThrowException::throwException(createMinimumArityTypeErrorForMethod(in fo.GetIsolate(), "voidMethodTestInterfaceEmptyArg", "TestInterface", 1, info.Len gth()), info.GetIsolate());
1165 return; 1172 return;
(...skipping 1065 matching lines...) Expand 10 before | Expand all | Expand 10 after
2231 static const V8DOMConfiguration::AttributeConfiguration V8TestInterfaceAttribute s[] = { 2238 static const V8DOMConfiguration::AttributeConfiguration V8TestInterfaceAttribute s[] = {
2232 {"testInterfaceConstructorAttribute", v8ConstructorAttributeGetter, TestInte rfaceImplementationV8Internal::testInterfaceConstructorAttributeAttributeSetterC allback, 0, 0, const_cast<WrapperTypeInfo*>(&V8TestInterface::wrapperTypeInfo), static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribute>( v8::DontEnum), V8DOMConfiguration::ExposedToAllScripts, V8DOMConfiguration::OnIn stance, V8DOMConfiguration::CheckHolder}, 2239 {"testInterfaceConstructorAttribute", v8ConstructorAttributeGetter, TestInte rfaceImplementationV8Internal::testInterfaceConstructorAttributeAttributeSetterC allback, 0, 0, const_cast<WrapperTypeInfo*>(&V8TestInterface::wrapperTypeInfo), static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribute>( v8::DontEnum), V8DOMConfiguration::ExposedToAllScripts, V8DOMConfiguration::OnIn stance, V8DOMConfiguration::CheckHolder},
2233 {"TestInterface", v8ConstructorAttributeGetter, TestInterfaceImplementationV 8Internal::TestInterfaceImplementationConstructorAttributeSetterCallback, 0, 0, const_cast<WrapperTypeInfo*>(&V8TestInterface::wrapperTypeInfo), static_cast<v8: :AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::DontEnum), V8DOMConfiguration::ExposedToAllScripts, V8DOMConfiguration::OnInstance, V8DOMCo nfiguration::CheckHolder}, 2240 {"TestInterface", v8ConstructorAttributeGetter, TestInterfaceImplementationV 8Internal::TestInterfaceImplementationConstructorAttributeSetterCallback, 0, 0, const_cast<WrapperTypeInfo*>(&V8TestInterface::wrapperTypeInfo), static_cast<v8: :AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::DontEnum), V8DOMConfiguration::ExposedToAllScripts, V8DOMConfiguration::OnInstance, V8DOMCo nfiguration::CheckHolder},
2234 {"TestInterface2", v8ConstructorAttributeGetter, TestInterfaceImplementation V8Internal::TestInterfaceImplementationConstructorAttributeSetterCallback, 0, 0, const_cast<WrapperTypeInfo*>(&V8TestInterface2::wrapperTypeInfo), static_cast<v 8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::DontEnum) , V8DOMConfiguration::ExposedToAllScripts, V8DOMConfiguration::OnInstance, V8DOM Configuration::CheckHolder}, 2241 {"TestInterface2", v8ConstructorAttributeGetter, TestInterfaceImplementation V8Internal::TestInterfaceImplementationConstructorAttributeSetterCallback, 0, 0, const_cast<WrapperTypeInfo*>(&V8TestInterface2::wrapperTypeInfo), static_cast<v 8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::DontEnum) , V8DOMConfiguration::ExposedToAllScripts, V8DOMConfiguration::OnInstance, V8DOM Configuration::CheckHolder},
2235 }; 2242 };
2236 #if defined(COMPONENT_BUILD) && defined(WIN32) && COMPILER(CLANG) 2243 #if defined(COMPONENT_BUILD) && defined(WIN32) && COMPILER(CLANG)
2237 #pragma clang diagnostic pop 2244 #pragma clang diagnostic pop
2238 #endif 2245 #endif
2239 2246
2240 static const V8DOMConfiguration::AccessorConfiguration V8TestInterfaceAccessors[ ] = { 2247 static const V8DOMConfiguration::AccessorConfiguration V8TestInterfaceAccessors[ ] = {
2241 {"testInterfaceAttribute", TestInterfaceImplementationV8Internal::testInterf aceAttributeAttributeGetterCallback, TestInterfaceImplementationV8Internal::test InterfaceAttributeAttributeSetterCallback, 0, 0, 0, static_cast<v8::AccessContro l>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguratio n::ExposedToAllScripts, V8DOMConfiguration::OnPrototype, V8DOMConfiguration::Che ckHolder}, 2248 {"testInterfaceAttribute", TestInterfaceImplementationV8Internal::testInterf aceAttributeAttributeGetterCallback, TestInterfaceImplementationV8Internal::test InterfaceAttributeAttributeSetterCallback, 0, 0, 0, v8::DEFAULT, static_cast<v8: :PropertyAttribute>(v8::None), V8DOMConfiguration::ExposedToAllScripts, V8DOMCon figuration::OnPrototype, V8DOMConfiguration::CheckHolder},
2242 {"doubleAttribute", TestInterfaceImplementationV8Internal::doubleAttributeAt tributeGetterCallback, TestInterfaceImplementationV8Internal::doubleAttributeAtt ributeSetterCallback, 0, 0, 0, static_cast<v8::AccessControl>(v8::DEFAULT), stat ic_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::ExposedToAllScript s, V8DOMConfiguration::OnPrototype, V8DOMConfiguration::CheckHolder}, 2249 {"doubleAttribute", TestInterfaceImplementationV8Internal::doubleAttributeAt tributeGetterCallback, TestInterfaceImplementationV8Internal::doubleAttributeAtt ributeSetterCallback, 0, 0, 0, v8::DEFAULT, static_cast<v8::PropertyAttribute>(v 8::None), V8DOMConfiguration::ExposedToAllScripts, V8DOMConfiguration::OnPrototy pe, V8DOMConfiguration::CheckHolder},
2243 {"floatAttribute", TestInterfaceImplementationV8Internal::floatAttributeAttr ibuteGetterCallback, TestInterfaceImplementationV8Internal::floatAttributeAttrib uteSetterCallback, 0, 0, 0, static_cast<v8::AccessControl>(v8::DEFAULT), static_ cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::ExposedToAllScripts, V8DOMConfiguration::OnPrototype, V8DOMConfiguration::CheckHolder}, 2250 {"floatAttribute", TestInterfaceImplementationV8Internal::floatAttributeAttr ibuteGetterCallback, TestInterfaceImplementationV8Internal::floatAttributeAttrib uteSetterCallback, 0, 0, 0, v8::DEFAULT, static_cast<v8::PropertyAttribute>(v8:: None), V8DOMConfiguration::ExposedToAllScripts, V8DOMConfiguration::OnPrototype, V8DOMConfiguration::CheckHolder},
2244 {"unrestrictedDoubleAttribute", TestInterfaceImplementationV8Internal::unres trictedDoubleAttributeAttributeGetterCallback, TestInterfaceImplementationV8Inte rnal::unrestrictedDoubleAttributeAttributeSetterCallback, 0, 0, 0, static_cast<v 8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::None), V8 DOMConfiguration::ExposedToAllScripts, V8DOMConfiguration::OnPrototype, V8DOMCon figuration::CheckHolder}, 2251 {"unrestrictedDoubleAttribute", TestInterfaceImplementationV8Internal::unres trictedDoubleAttributeAttributeGetterCallback, TestInterfaceImplementationV8Inte rnal::unrestrictedDoubleAttributeAttributeSetterCallback, 0, 0, 0, v8::DEFAULT, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::ExposedToAllSc ripts, V8DOMConfiguration::OnPrototype, V8DOMConfiguration::CheckHolder},
2245 {"unrestrictedFloatAttribute", TestInterfaceImplementationV8Internal::unrest rictedFloatAttributeAttributeGetterCallback, TestInterfaceImplementationV8Intern al::unrestrictedFloatAttributeAttributeSetterCallback, 0, 0, 0, static_cast<v8:: AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::None), V8DOM Configuration::ExposedToAllScripts, V8DOMConfiguration::OnPrototype, V8DOMConfig uration::CheckHolder}, 2252 {"unrestrictedFloatAttribute", TestInterfaceImplementationV8Internal::unrest rictedFloatAttributeAttributeGetterCallback, TestInterfaceImplementationV8Intern al::unrestrictedFloatAttributeAttributeSetterCallback, 0, 0, 0, v8::DEFAULT, sta tic_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::ExposedToAllScrip ts, V8DOMConfiguration::OnPrototype, V8DOMConfiguration::CheckHolder},
2246 {"testEnumAttribute", TestInterfaceImplementationV8Internal::testEnumAttribu teAttributeGetterCallback, TestInterfaceImplementationV8Internal::testEnumAttrib uteAttributeSetterCallback, 0, 0, 0, static_cast<v8::AccessControl>(v8::DEFAULT) , static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::ExposedToAll Scripts, V8DOMConfiguration::OnPrototype, V8DOMConfiguration::CheckHolder}, 2253 {"testEnumAttribute", TestInterfaceImplementationV8Internal::testEnumAttribu teAttributeGetterCallback, TestInterfaceImplementationV8Internal::testEnumAttrib uteAttributeSetterCallback, 0, 0, 0, v8::DEFAULT, static_cast<v8::PropertyAttrib ute>(v8::None), V8DOMConfiguration::ExposedToAllScripts, V8DOMConfiguration::OnP rototype, V8DOMConfiguration::CheckHolder},
2247 {"stringOrDoubleAttribute", TestInterfaceImplementationV8Internal::stringOrD oubleAttributeAttributeGetterCallback, TestInterfaceImplementationV8Internal::st ringOrDoubleAttributeAttributeSetterCallback, 0, 0, 0, static_cast<v8::AccessCon trol>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfigura tion::ExposedToAllScripts, V8DOMConfiguration::OnPrototype, V8DOMConfiguration:: CheckHolder}, 2254 {"stringOrDoubleAttribute", TestInterfaceImplementationV8Internal::stringOrD oubleAttributeAttributeGetterCallback, TestInterfaceImplementationV8Internal::st ringOrDoubleAttributeAttributeSetterCallback, 0, 0, 0, v8::DEFAULT, static_cast< v8::PropertyAttribute>(v8::None), V8DOMConfiguration::ExposedToAllScripts, V8DOM Configuration::OnPrototype, V8DOMConfiguration::CheckHolder},
2248 {"legacyInterfaceTypeCheckingAttribute", TestInterfaceImplementationV8Intern al::legacyInterfaceTypeCheckingAttributeAttributeGetterCallback, TestInterfaceIm plementationV8Internal::legacyInterfaceTypeCheckingAttributeAttributeSetterCallb ack, 0, 0, 0, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::Prope rtyAttribute>(v8::None), V8DOMConfiguration::ExposedToAllScripts, V8DOMConfigura tion::OnPrototype, V8DOMConfiguration::CheckHolder}, 2255 {"staticStringAttribute", TestInterfaceImplementationV8Internal::staticStrin gAttributeAttributeGetterCallback, TestInterfaceImplementationV8Internal::static StringAttributeAttributeSetterCallback, 0, 0, 0, v8::DEFAULT, static_cast<v8::Pr opertyAttribute>(v8::None), V8DOMConfiguration::ExposedToAllScripts, V8DOMConfig uration::OnInterface, V8DOMConfiguration::CheckHolder},
2249 {"alwaysExposedAttribute", TestInterfaceImplementationV8Internal::alwaysExpo sedAttributeAttributeGetterCallback, TestInterfaceImplementationV8Internal::alwa ysExposedAttributeAttributeSetterCallback, 0, 0, 0, static_cast<v8::AccessContro l>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguratio n::ExposedToAllScripts, V8DOMConfiguration::OnPrototype, V8DOMConfiguration::Che ckHolder}, 2256 {"staticReturnDOMWrapperAttribute", TestInterfaceImplementationV8Internal::s taticReturnDOMWrapperAttributeAttributeGetterCallback, TestInterfaceImplementati onV8Internal::staticReturnDOMWrapperAttributeAttributeSetterCallback, 0, 0, 0, v 8::DEFAULT, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::Ex posedToAllScripts, V8DOMConfiguration::OnInterface, V8DOMConfiguration::CheckHol der},
2250 {"lenientThisAttribute", TestInterfaceImplementationV8Internal::lenientThisA ttributeAttributeGetterCallback, TestInterfaceImplementationV8Internal::lenientT hisAttributeAttributeSetterCallback, 0, 0, 0, static_cast<v8::AccessControl>(v8: :DEFAULT), static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::Exp osedToAllScripts, V8DOMConfiguration::OnPrototype, V8DOMConfiguration::DoNotChec kHolder}, 2257 {"legacyInterfaceTypeCheckingAttribute", TestInterfaceImplementationV8Intern al::legacyInterfaceTypeCheckingAttributeAttributeGetterCallback, TestInterfaceIm plementationV8Internal::legacyInterfaceTypeCheckingAttributeAttributeSetterCallb ack, 0, 0, 0, v8::DEFAULT, static_cast<v8::PropertyAttribute>(v8::None), V8DOMCo nfiguration::ExposedToAllScripts, V8DOMConfiguration::OnPrototype, V8DOMConfigur ation::CheckHolder},
2251 {"implementsReadonlyStringAttribute", TestInterfaceImplementationV8Internal: :implementsReadonlyStringAttributeAttributeGetterCallback, 0, 0, 0, 0, static_ca st<v8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::None) , V8DOMConfiguration::ExposedToAllScripts, V8DOMConfiguration::OnPrototype, V8DO MConfiguration::CheckHolder}, 2258 {"alwaysExposedAttribute", TestInterfaceImplementationV8Internal::alwaysExpo sedAttributeAttributeGetterCallback, TestInterfaceImplementationV8Internal::alwa ysExposedAttributeAttributeSetterCallback, 0, 0, 0, v8::DEFAULT, static_cast<v8: :PropertyAttribute>(v8::None), V8DOMConfiguration::ExposedToAllScripts, V8DOMCon figuration::OnPrototype, V8DOMConfiguration::CheckHolder},
2252 {"implementsStringAttribute", TestInterfaceImplementationV8Internal::impleme ntsStringAttributeAttributeGetterCallback, TestInterfaceImplementationV8Internal ::implementsStringAttributeAttributeSetterCallback, 0, 0, 0, static_cast<v8::Acc essControl>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::None), V8DOMCon figuration::ExposedToAllScripts, V8DOMConfiguration::OnPrototype, V8DOMConfigura tion::CheckHolder}, 2259 {"lenientThisAttribute", TestInterfaceImplementationV8Internal::lenientThisA ttributeAttributeGetterCallback, TestInterfaceImplementationV8Internal::lenientT hisAttributeAttributeSetterCallback, 0, 0, 0, v8::DEFAULT, static_cast<v8::Prope rtyAttribute>(v8::None), V8DOMConfiguration::ExposedToAllScripts, V8DOMConfigura tion::OnPrototype, V8DOMConfiguration::DoNotCheckHolder},
2253 {"implementsNodeAttribute", TestInterfaceImplementationV8Internal::implement sNodeAttributeAttributeGetterCallback, TestInterfaceImplementationV8Internal::im plementsNodeAttributeAttributeSetterCallback, 0, 0, 0, static_cast<v8::AccessCon trol>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfigura tion::ExposedToAllScripts, V8DOMConfiguration::OnPrototype, V8DOMConfiguration:: CheckHolder}, 2260 {"implementsStaticReadOnlyLongAttribute", TestInterfaceImplementationV8Inter nal::implementsStaticReadOnlyLongAttributeAttributeGetterCallback, 0, 0, 0, 0, v 8::DEFAULT, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::Ex posedToAllScripts, V8DOMConfiguration::OnInterface, V8DOMConfiguration::CheckHol der},
2254 {"implementsEventHandlerAttribute", TestInterfaceImplementationV8Internal::i mplementsEventHandlerAttributeAttributeGetterCallback, TestInterfaceImplementati onV8Internal::implementsEventHandlerAttributeAttributeSetterCallback, 0, 0, 0, s tatic_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v 8::None), V8DOMConfiguration::ExposedToAllScripts, V8DOMConfiguration::OnPrototy pe, V8DOMConfiguration::CheckHolder}, 2261 {"implementsStaticStringAttribute", TestInterfaceImplementationV8Internal::i mplementsStaticStringAttributeAttributeGetterCallback, TestInterfaceImplementati onV8Internal::implementsStaticStringAttributeAttributeSetterCallback, 0, 0, 0, v 8::DEFAULT, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::Ex posedToAllScripts, V8DOMConfiguration::OnInterface, V8DOMConfiguration::CheckHol der},
2255 {"implements3StringAttribute", TestInterfaceImplementationV8Internal::implem ents3StringAttributeAttributeGetterCallback, TestInterfaceImplementationV8Intern al::implements3StringAttributeAttributeSetterCallback, 0, 0, 0, static_cast<v8:: AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::None), V8DOM Configuration::ExposedToAllScripts, V8DOMConfiguration::OnPrototype, V8DOMConfig uration::CheckHolder}, 2262 {"implementsReadonlyStringAttribute", TestInterfaceImplementationV8Internal: :implementsReadonlyStringAttributeAttributeGetterCallback, 0, 0, 0, 0, v8::DEFAU LT, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::ExposedToA llScripts, V8DOMConfiguration::OnPrototype, V8DOMConfiguration::CheckHolder},
2256 {"partial2LongAttribute", TestInterfaceImplementationV8Internal::partial2Lon gAttributeAttributeGetterCallback, TestInterfaceImplementationV8Internal::partia l2LongAttributeAttributeSetterCallback, 0, 0, 0, static_cast<v8::AccessControl>( v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration:: ExposedToAllScripts, V8DOMConfiguration::OnPrototype, V8DOMConfiguration::CheckH older}, 2263 {"implementsStringAttribute", TestInterfaceImplementationV8Internal::impleme ntsStringAttributeAttributeGetterCallback, TestInterfaceImplementationV8Internal ::implementsStringAttributeAttributeSetterCallback, 0, 0, 0, v8::DEFAULT, static _cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::ExposedToAllScripts, V8DOMConfiguration::OnPrototype, V8DOMConfiguration::CheckHolder},
2264 {"implementsNodeAttribute", TestInterfaceImplementationV8Internal::implement sNodeAttributeAttributeGetterCallback, TestInterfaceImplementationV8Internal::im plementsNodeAttributeAttributeSetterCallback, 0, 0, 0, v8::DEFAULT, static_cast< v8::PropertyAttribute>(v8::None), V8DOMConfiguration::ExposedToAllScripts, V8DOM Configuration::OnPrototype, V8DOMConfiguration::CheckHolder},
2265 {"implementsEventHandlerAttribute", TestInterfaceImplementationV8Internal::i mplementsEventHandlerAttributeAttributeGetterCallback, TestInterfaceImplementati onV8Internal::implementsEventHandlerAttributeAttributeSetterCallback, 0, 0, 0, v 8::DEFAULT, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::Ex posedToAllScripts, V8DOMConfiguration::OnPrototype, V8DOMConfiguration::CheckHol der},
2266 {"implements3StringAttribute", TestInterfaceImplementationV8Internal::implem ents3StringAttributeAttributeGetterCallback, TestInterfaceImplementationV8Intern al::implements3StringAttributeAttributeSetterCallback, 0, 0, 0, v8::DEFAULT, sta tic_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::ExposedToAllScrip ts, V8DOMConfiguration::OnPrototype, V8DOMConfiguration::CheckHolder},
2267 {"implements3StaticStringAttribute", TestInterfaceImplementationV8Internal:: implements3StaticStringAttributeAttributeGetterCallback, TestInterfaceImplementa tionV8Internal::implements3StaticStringAttributeAttributeSetterCallback, 0, 0, 0 , v8::DEFAULT, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration: :ExposedToAllScripts, V8DOMConfiguration::OnInterface, V8DOMConfiguration::Check Holder},
2268 {"partial2LongAttribute", TestInterfaceImplementationV8Internal::partial2Lon gAttributeAttributeGetterCallback, TestInterfaceImplementationV8Internal::partia l2LongAttributeAttributeSetterCallback, 0, 0, 0, v8::DEFAULT, static_cast<v8::Pr opertyAttribute>(v8::None), V8DOMConfiguration::ExposedToAllScripts, V8DOMConfig uration::OnPrototype, V8DOMConfiguration::CheckHolder},
2269 {"partial2StaticLongAttribute", TestInterfaceImplementationV8Internal::parti al2StaticLongAttributeAttributeGetterCallback, TestInterfaceImplementationV8Inte rnal::partial2StaticLongAttributeAttributeSetterCallback, 0, 0, 0, v8::DEFAULT, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::ExposedToAllSc ripts, V8DOMConfiguration::OnInterface, V8DOMConfiguration::CheckHolder},
2257 }; 2270 };
2258 2271
2259 static const V8DOMConfiguration::MethodConfiguration V8TestInterfaceMethods[] = { 2272 static const V8DOMConfiguration::MethodConfiguration V8TestInterfaceMethods[] = {
2260 {"voidMethodTestInterfaceEmptyArg", TestInterfaceImplementationV8Internal::v oidMethodTestInterfaceEmptyArgMethodCallback, 0, 1, V8DOMConfiguration::ExposedT oAllScripts}, 2273 {"voidMethodTestInterfaceEmptyArg", TestInterfaceImplementationV8Internal::v oidMethodTestInterfaceEmptyArgMethodCallback, 0, 1, V8DOMConfiguration::ExposedT oAllScripts},
2261 {"voidMethodDoubleArgFloatArg", TestInterfaceImplementationV8Internal::voidM ethodDoubleArgFloatArgMethodCallback, 0, 2, V8DOMConfiguration::ExposedToAllScri pts}, 2274 {"voidMethodDoubleArgFloatArg", TestInterfaceImplementationV8Internal::voidM ethodDoubleArgFloatArgMethodCallback, 0, 2, V8DOMConfiguration::ExposedToAllScri pts},
2262 {"voidMethodUnrestrictedDoubleArgUnrestrictedFloatArg", TestInterfaceImpleme ntationV8Internal::voidMethodUnrestrictedDoubleArgUnrestrictedFloatArgMethodCall back, 0, 2, V8DOMConfiguration::ExposedToAllScripts}, 2275 {"voidMethodUnrestrictedDoubleArgUnrestrictedFloatArg", TestInterfaceImpleme ntationV8Internal::voidMethodUnrestrictedDoubleArgUnrestrictedFloatArgMethodCall back, 0, 2, V8DOMConfiguration::ExposedToAllScripts},
2263 {"voidMethodTestEnumArg", TestInterfaceImplementationV8Internal::voidMethodT estEnumArgMethodCallback, 0, 1, V8DOMConfiguration::ExposedToAllScripts}, 2276 {"voidMethodTestEnumArg", TestInterfaceImplementationV8Internal::voidMethodT estEnumArgMethodCallback, 0, 1, V8DOMConfiguration::ExposedToAllScripts},
2264 {"voidMethod", TestInterfaceImplementationV8Internal::voidMethodMethodCallba ck, TestInterfaceImplementationV8Internal::voidMethodMethodCallbackForMainWorld, 0, V8DOMConfiguration::ExposedToAllScripts}, 2277 {"voidMethod", TestInterfaceImplementationV8Internal::voidMethodMethodCallba ck, TestInterfaceImplementationV8Internal::voidMethodMethodCallbackForMainWorld, 0, V8DOMConfiguration::ExposedToAllScripts},
2265 {"alwaysExposedMethod", TestInterfaceImplementationV8Internal::alwaysExposed MethodMethodCallback, 0, 0, V8DOMConfiguration::ExposedToAllScripts}, 2278 {"alwaysExposedMethod", TestInterfaceImplementationV8Internal::alwaysExposed MethodMethodCallback, 0, 0, V8DOMConfiguration::ExposedToAllScripts},
2266 {"legacyInterfaceTypeCheckingMethod", TestInterfaceImplementationV8Internal: :legacyInterfaceTypeCheckingMethodMethodCallback, 0, 1, V8DOMConfiguration::Expo sedToAllScripts}, 2279 {"legacyInterfaceTypeCheckingMethod", TestInterfaceImplementationV8Internal: :legacyInterfaceTypeCheckingMethodMethodCallback, 0, 1, V8DOMConfiguration::Expo sedToAllScripts},
(...skipping 16 matching lines...) Expand all
2283 else 2296 else
2284 defaultSignature = V8DOMConfiguration::installDOMClassTemplate(isolate, functionTemplate, "TestInterface", V8TestInterfaceEmpty::domTemplate(isolate), V 8TestInterface::internalFieldCount, 2297 defaultSignature = V8DOMConfiguration::installDOMClassTemplate(isolate, functionTemplate, "TestInterface", V8TestInterfaceEmpty::domTemplate(isolate), V 8TestInterface::internalFieldCount,
2285 V8TestInterfaceAttributes, WTF_ARRAY_LENGTH(V8TestInterfaceAttribute s), 2298 V8TestInterfaceAttributes, WTF_ARRAY_LENGTH(V8TestInterfaceAttribute s),
2286 V8TestInterfaceAccessors, WTF_ARRAY_LENGTH(V8TestInterfaceAccessors) , 2299 V8TestInterfaceAccessors, WTF_ARRAY_LENGTH(V8TestInterfaceAccessors) ,
2287 V8TestInterfaceMethods, WTF_ARRAY_LENGTH(V8TestInterfaceMethods)); 2300 V8TestInterfaceMethods, WTF_ARRAY_LENGTH(V8TestInterfaceMethods));
2288 v8::Local<v8::ObjectTemplate> instanceTemplate = functionTemplate->InstanceT emplate(); 2301 v8::Local<v8::ObjectTemplate> instanceTemplate = functionTemplate->InstanceT emplate();
2289 ALLOW_UNUSED_LOCAL(instanceTemplate); 2302 ALLOW_UNUSED_LOCAL(instanceTemplate);
2290 v8::Local<v8::ObjectTemplate> prototypeTemplate = functionTemplate->Prototyp eTemplate(); 2303 v8::Local<v8::ObjectTemplate> prototypeTemplate = functionTemplate->Prototyp eTemplate();
2291 ALLOW_UNUSED_LOCAL(prototypeTemplate); 2304 ALLOW_UNUSED_LOCAL(prototypeTemplate);
2292 if (RuntimeEnabledFeatures::implementsFeatureNameEnabled()) { 2305 if (RuntimeEnabledFeatures::implementsFeatureNameEnabled()) {
2293 static const V8DOMConfiguration::AccessorConfiguration accessorConfigura tion =\ 2306 static const V8DOMConfiguration::AccessorConfiguration accessorConfigura tion = \
2294 {"implementsRuntimeEnabledNodeAttribute", TestInterfaceImplementationV8I nternal::implementsRuntimeEnabledNodeAttributeAttributeGetterCallback, TestInter faceImplementationV8Internal::implementsRuntimeEnabledNodeAttributeAttributeSett erCallback, 0, 0, 0, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8 ::PropertyAttribute>(v8::None), V8DOMConfiguration::ExposedToAllScripts, V8DOMCo nfiguration::OnPrototype, V8DOMConfiguration::CheckHolder}; 2307 {"implementsRuntimeEnabledNodeAttribute", TestInterfaceImplementationV8I nternal::implementsRuntimeEnabledNodeAttributeAttributeGetterCallback, TestInter faceImplementationV8Internal::implementsRuntimeEnabledNodeAttributeAttributeSett erCallback, 0, 0, 0, v8::DEFAULT, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::ExposedToAllScripts, V8DOMConfiguration::OnPrototype, V8DOMC onfiguration::CheckHolder};
2295 V8DOMConfiguration::installAccessor(isolate, instanceTemplate, prototype Template, functionTemplate, defaultSignature, accessorConfiguration); 2308 V8DOMConfiguration::installAccessor(isolate, instanceTemplate, prototype Template, functionTemplate, defaultSignature, accessorConfiguration);
2296 } 2309 }
2297 if (RuntimeEnabledFeatures::implements2FeatureNameEnabled()) { 2310 if (RuntimeEnabledFeatures::implements2FeatureNameEnabled()) {
2298 static const V8DOMConfiguration::AccessorConfiguration accessorConfigura tion =\ 2311 static const V8DOMConfiguration::AccessorConfiguration accessorConfigura tion = \
2299 {"implements2StringAttribute", TestInterfaceImplementationV8Internal::im plements2StringAttributeAttributeGetterCallback, TestInterfaceImplementationV8In ternal::implements2StringAttributeAttributeSetterCallback, 0, 0, 0, static_cast< v8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::None), V 8DOMConfiguration::ExposedToAllScripts, V8DOMConfiguration::OnPrototype, V8DOMCo nfiguration::CheckHolder}; 2312 {"implements2StringAttribute", TestInterfaceImplementationV8Internal::im plements2StringAttributeAttributeGetterCallback, TestInterfaceImplementationV8In ternal::implements2StringAttributeAttributeSetterCallback, 0, 0, 0, v8::DEFAULT, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::ExposedToAllS cripts, V8DOMConfiguration::OnPrototype, V8DOMConfiguration::CheckHolder};
2300 V8DOMConfiguration::installAccessor(isolate, instanceTemplate, prototype Template, functionTemplate, defaultSignature, accessorConfiguration); 2313 V8DOMConfiguration::installAccessor(isolate, instanceTemplate, prototype Template, functionTemplate, defaultSignature, accessorConfiguration);
2301 } 2314 }
2302 #if ENABLE(PARTIAL_CONDITION) 2315 #if ENABLE(PARTIAL_CONDITION)
2303 if (RuntimeEnabledFeatures::partialFeatureNameEnabled()) { 2316 if (RuntimeEnabledFeatures::partialFeatureNameEnabled()) {
2304 static const V8DOMConfiguration::AccessorConfiguration accessorConfigura tion =\ 2317 static const V8DOMConfiguration::AccessorConfiguration accessorConfigura tion = \
2305 {"partialLongAttribute", TestInterfaceImplementationV8Internal::partialL ongAttributeAttributeGetterCallback, TestInterfaceImplementationV8Internal::part ialLongAttributeAttributeSetterCallback, 0, 0, 0, static_cast<v8::AccessControl> (v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration: :ExposedToAllScripts, V8DOMConfiguration::OnPrototype, V8DOMConfiguration::Check Holder}; 2318 {"partialLongAttribute", TestInterfaceImplementationV8Internal::partialL ongAttributeAttributeGetterCallback, TestInterfaceImplementationV8Internal::part ialLongAttributeAttributeSetterCallback, 0, 0, 0, v8::DEFAULT, static_cast<v8::P ropertyAttribute>(v8::None), V8DOMConfiguration::ExposedToAllScripts, V8DOMConfi guration::OnPrototype, V8DOMConfiguration::CheckHolder};
2306 V8DOMConfiguration::installAccessor(isolate, instanceTemplate, prototype Template, functionTemplate, defaultSignature, accessorConfiguration); 2319 V8DOMConfiguration::installAccessor(isolate, instanceTemplate, prototype Template, functionTemplate, defaultSignature, accessorConfiguration);
2307 } 2320 }
2308 #endif // ENABLE(PARTIAL_CONDITION) 2321 #endif // ENABLE(PARTIAL_CONDITION)
2309 #if ENABLE(PARTIAL_CONDITION) 2322 #if ENABLE(PARTIAL_CONDITION)
2310 if (RuntimeEnabledFeatures::partialFeatureNameEnabled()) { 2323 if (RuntimeEnabledFeatures::partialFeatureNameEnabled()) {
2311 static const V8DOMConfiguration::AccessorConfiguration accessorConfigura tion =\ 2324 static const V8DOMConfiguration::AccessorConfiguration accessorConfigura tion = \
2312 {"partialCallWithExecutionContextLongAttribute", TestInterfaceImplementa tionV8Internal::partialCallWithExecutionContextLongAttributeAttributeGetterCallb ack, TestInterfaceImplementationV8Internal::partialCallWithExecutionContextLongA ttributeAttributeSetterCallback, 0, 0, 0, static_cast<v8::AccessControl>(v8::DEF AULT), static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::Exposed ToAllScripts, V8DOMConfiguration::OnPrototype, V8DOMConfiguration::CheckHolder}; 2325 {"partialCallWithExecutionContextLongAttribute", TestInterfaceImplementa tionV8Internal::partialCallWithExecutionContextLongAttributeAttributeGetterCallb ack, TestInterfaceImplementationV8Internal::partialCallWithExecutionContextLongA ttributeAttributeSetterCallback, 0, 0, 0, v8::DEFAULT, static_cast<v8::PropertyA ttribute>(v8::None), V8DOMConfiguration::ExposedToAllScripts, V8DOMConfiguration ::OnPrototype, V8DOMConfiguration::CheckHolder};
2313 V8DOMConfiguration::installAccessor(isolate, instanceTemplate, prototype Template, functionTemplate, defaultSignature, accessorConfiguration); 2326 V8DOMConfiguration::installAccessor(isolate, instanceTemplate, prototype Template, functionTemplate, defaultSignature, accessorConfiguration);
2314 } 2327 }
2315 #endif // ENABLE(PARTIAL_CONDITION) 2328 #endif // ENABLE(PARTIAL_CONDITION)
2316 #if ENABLE(PARTIAL_CONDITION) 2329 #if ENABLE(PARTIAL_CONDITION)
2317 if (RuntimeEnabledFeatures::partialFeatureNameEnabled()) { 2330 if (RuntimeEnabledFeatures::partialFeatureNameEnabled()) {
2318 static const V8DOMConfiguration::AccessorConfiguration accessorConfigura tion =\ 2331 static const V8DOMConfiguration::AccessorConfiguration accessorConfigura tion = \
2319 {"partialPartialEnumTypeAttribute", TestInterfaceImplementationV8Interna l::partialPartialEnumTypeAttributeAttributeGetterCallback, TestInterfaceImplemen tationV8Internal::partialPartialEnumTypeAttributeAttributeSetterCallback, 0, 0, 0, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribut e>(v8::None), V8DOMConfiguration::ExposedToAllScripts, V8DOMConfiguration::OnPro totype, V8DOMConfiguration::CheckHolder}; 2332 {"partialPartialEnumTypeAttribute", TestInterfaceImplementationV8Interna l::partialPartialEnumTypeAttributeAttributeGetterCallback, TestInterfaceImplemen tationV8Internal::partialPartialEnumTypeAttributeAttributeSetterCallback, 0, 0, 0, v8::DEFAULT, static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration ::ExposedToAllScripts, V8DOMConfiguration::OnPrototype, V8DOMConfiguration::Chec kHolder};
2320 V8DOMConfiguration::installAccessor(isolate, instanceTemplate, prototype Template, functionTemplate, defaultSignature, accessorConfiguration); 2333 V8DOMConfiguration::installAccessor(isolate, instanceTemplate, prototype Template, functionTemplate, defaultSignature, accessorConfiguration);
2321 } 2334 }
2322 #endif // ENABLE(PARTIAL_CONDITION) 2335 #endif // ENABLE(PARTIAL_CONDITION)
2323 #if ENABLE(PARTIAL_CONDITION) 2336 #if ENABLE(PARTIAL_CONDITION)
2324 if (RuntimeEnabledFeatures::partialFeatureNameEnabled()) { 2337 if (RuntimeEnabledFeatures::partialFeatureNameEnabled()) {
2325 static const V8DOMConfiguration::AccessorConfiguration accessorConfigura tion =\ 2338 static const V8DOMConfiguration::AccessorConfiguration accessorConfigura tion = \
2326 {"stringAttribute", TestInterfaceImplementationV8Internal::stringAttribu teAttributeGetterCallback, TestInterfaceImplementationV8Internal::stringAttribut eAttributeSetterCallback, 0, 0, 0, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfiguration::ExposedToAllSc ripts, V8DOMConfiguration::OnPrototype, V8DOMConfiguration::CheckHolder}; 2339 {"stringAttribute", TestInterfaceImplementationV8Internal::stringAttribu teAttributeGetterCallback, TestInterfaceImplementationV8Internal::stringAttribut eAttributeSetterCallback, 0, 0, 0, v8::DEFAULT, static_cast<v8::PropertyAttribut e>(v8::None), V8DOMConfiguration::ExposedToAllScripts, V8DOMConfiguration::OnPro totype, V8DOMConfiguration::CheckHolder};
2327 V8DOMConfiguration::installAccessor(isolate, instanceTemplate, prototype Template, functionTemplate, defaultSignature, accessorConfiguration); 2340 V8DOMConfiguration::installAccessor(isolate, instanceTemplate, prototype Template, functionTemplate, defaultSignature, accessorConfiguration);
2328 } 2341 }
2329 #endif // ENABLE(PARTIAL_CONDITION) 2342 #endif // ENABLE(PARTIAL_CONDITION)
2330 static const V8DOMConfiguration::ConstantConfiguration V8TestInterfaceConsta nts[] = { 2343 static const V8DOMConfiguration::ConstantConfiguration V8TestInterfaceConsta nts[] = {
2331 {"UNSIGNED_LONG", 0, 0, 0, V8DOMConfiguration::ConstantTypeUnsignedLong} , 2344 {"UNSIGNED_LONG", 0, 0, 0, V8DOMConfiguration::ConstantTypeUnsignedLong} ,
2332 {"CONST_JAVASCRIPT", 1, 0, 0, V8DOMConfiguration::ConstantTypeShort}, 2345 {"CONST_JAVASCRIPT", 1, 0, 0, V8DOMConfiguration::ConstantTypeShort},
2333 {"IMPLEMENTS_CONSTANT_1", 1, 0, 0, V8DOMConfiguration::ConstantTypeUnsig nedShort}, 2346 {"IMPLEMENTS_CONSTANT_1", 1, 0, 0, V8DOMConfiguration::ConstantTypeUnsig nedShort},
2334 {"IMPLEMENTS_CONSTANT_2", 2, 0, 0, V8DOMConfiguration::ConstantTypeUnsig nedShort}, 2347 {"IMPLEMENTS_CONSTANT_2", 2, 0, 0, V8DOMConfiguration::ConstantTypeUnsig nedShort},
2335 {"PARTIAL2_UNSIGNED_SHORT", 0, 0, 0, V8DOMConfiguration::ConstantTypeUns ignedShort}, 2348 {"PARTIAL2_UNSIGNED_SHORT", 0, 0, 0, V8DOMConfiguration::ConstantTypeUns ignedShort},
2336 }; 2349 };
(...skipping 112 matching lines...) Expand 10 before | Expand all | Expand 10 after
2449 }; 2462 };
2450 V8DOMConfiguration::installMethod(isolate, functionTemplate, v8::Local<v8::S ignature>(), v8::None, partial2StaticVoidMethodMethodConfiguration); 2463 V8DOMConfiguration::installMethod(isolate, functionTemplate, v8::Local<v8::S ignature>(), v8::None, partial2StaticVoidMethodMethodConfiguration);
2451 const V8DOMConfiguration::MethodConfiguration toJSONMethodConfiguration = { 2464 const V8DOMConfiguration::MethodConfiguration toJSONMethodConfiguration = {
2452 "toJSON", TestInterfaceImplementationV8Internal::toJSONMethodCallback, 0 , 0, V8DOMConfiguration::ExposedToAllScripts, 2465 "toJSON", TestInterfaceImplementationV8Internal::toJSONMethodCallback, 0 , 0, V8DOMConfiguration::ExposedToAllScripts,
2453 }; 2466 };
2454 V8DOMConfiguration::installMethod(isolate, prototypeTemplate, defaultSignatu re, static_cast<v8::PropertyAttribute>(v8::DontDelete | v8::DontEnum), toJSONMet hodConfiguration); 2467 V8DOMConfiguration::installMethod(isolate, prototypeTemplate, defaultSignatu re, static_cast<v8::PropertyAttribute>(v8::DontDelete | v8::DontEnum), toJSONMet hodConfiguration);
2455 const V8DOMConfiguration::MethodConfiguration toStringMethodConfiguration = { 2468 const V8DOMConfiguration::MethodConfiguration toStringMethodConfiguration = {
2456 "toString", TestInterfaceImplementationV8Internal::toStringMethodCallbac k, 0, 0, V8DOMConfiguration::ExposedToAllScripts, 2469 "toString", TestInterfaceImplementationV8Internal::toStringMethodCallbac k, 0, 0, V8DOMConfiguration::ExposedToAllScripts,
2457 }; 2470 };
2458 V8DOMConfiguration::installMethod(isolate, prototypeTemplate, defaultSignatu re, static_cast<v8::PropertyAttribute>(v8::DontDelete | v8::DontEnum), toStringM ethodConfiguration); 2471 V8DOMConfiguration::installMethod(isolate, prototypeTemplate, defaultSignatu re, static_cast<v8::PropertyAttribute>(v8::DontDelete | v8::DontEnum), toStringM ethodConfiguration);
2459 functionTemplate->SetNativeDataProperty(v8AtomicString(isolate, "staticStrin gAttribute"), TestInterfaceImplementationV8Internal::staticStringAttributeAttrib uteGetterCallback, TestInterfaceImplementationV8Internal::staticStringAttributeA ttributeSetterCallback, v8::External::New(isolate, 0), static_cast<v8::PropertyA ttribute>(v8::None), v8::Local<v8::AccessorSignature>(), static_cast<v8::AccessC ontrol>(v8::DEFAULT));
2460 functionTemplate->SetNativeDataProperty(v8AtomicString(isolate, "staticRetur nDOMWrapperAttribute"), TestInterfaceImplementationV8Internal::staticReturnDOMWr apperAttributeAttributeGetterCallback, TestInterfaceImplementationV8Internal::st aticReturnDOMWrapperAttributeAttributeSetterCallback, v8::External::New(isolate, 0), static_cast<v8::PropertyAttribute>(v8::None), v8::Local<v8::AccessorSignatu re>(), static_cast<v8::AccessControl>(v8::DEFAULT));
2461 functionTemplate->SetNativeDataProperty(v8AtomicString(isolate, "implementsS taticReadOnlyLongAttribute"), TestInterfaceImplementationV8Internal::implementsS taticReadOnlyLongAttributeAttributeGetterCallback, 0, v8::External::New(isolate, 0), static_cast<v8::PropertyAttribute>(v8::None), v8::Local<v8::AccessorSignatu re>(), static_cast<v8::AccessControl>(v8::DEFAULT));
2462 functionTemplate->SetNativeDataProperty(v8AtomicString(isolate, "implementsS taticStringAttribute"), TestInterfaceImplementationV8Internal::implementsStaticS tringAttributeAttributeGetterCallback, TestInterfaceImplementationV8Internal::im plementsStaticStringAttributeAttributeSetterCallback, v8::External::New(isolate, 0), static_cast<v8::PropertyAttribute>(v8::None), v8::Local<v8::AccessorSignatu re>(), static_cast<v8::AccessControl>(v8::DEFAULT));
2463 functionTemplate->SetNativeDataProperty(v8AtomicString(isolate, "implements2 StaticStringAttribute"), TestInterfaceImplementationV8Internal::implements2Stati cStringAttributeAttributeGetterCallback, TestInterfaceImplementationV8Internal:: implements2StaticStringAttributeAttributeSetterCallback, v8::External::New(isola te, 0), static_cast<v8::PropertyAttribute>(v8::None), v8::Local<v8::AccessorSign ature>(), static_cast<v8::AccessControl>(v8::DEFAULT));
2464 functionTemplate->SetNativeDataProperty(v8AtomicString(isolate, "implements3 StaticStringAttribute"), TestInterfaceImplementationV8Internal::implements3Stati cStringAttributeAttributeGetterCallback, TestInterfaceImplementationV8Internal:: implements3StaticStringAttributeAttributeSetterCallback, v8::External::New(isola te, 0), static_cast<v8::PropertyAttribute>(v8::None), v8::Local<v8::AccessorSign ature>(), static_cast<v8::AccessControl>(v8::DEFAULT));
2465 #if ENABLE(PARTIAL_CONDITION)
2466 functionTemplate->SetNativeDataProperty(v8AtomicString(isolate, "partialStat icLongAttribute"), TestInterfaceImplementationV8Internal::partialStaticLongAttri buteAttributeGetterCallback, TestInterfaceImplementationV8Internal::partialStati cLongAttributeAttributeSetterCallback, v8::External::New(isolate, 0), static_cas t<v8::PropertyAttribute>(v8::None), v8::Local<v8::AccessorSignature>(), static_c ast<v8::AccessControl>(v8::DEFAULT));
2467 #endif // ENABLE(PARTIAL_CONDITION)
2468 functionTemplate->SetNativeDataProperty(v8AtomicString(isolate, "partial2Sta ticLongAttribute"), TestInterfaceImplementationV8Internal::partial2StaticLongAtt ributeAttributeGetterCallback, TestInterfaceImplementationV8Internal::partial2St aticLongAttributeAttributeSetterCallback, v8::External::New(isolate, 0), static_ cast<v8::PropertyAttribute>(v8::None), v8::Local<v8::AccessorSignature>(), stati c_cast<v8::AccessControl>(v8::DEFAULT));
2469 2472
2470 // Custom toString template 2473 // Custom toString template
2471 functionTemplate->Set(v8AtomicString(isolate, "toString"), V8PerIsolateData: :from(isolate)->toStringTemplate()); 2474 functionTemplate->Set(v8AtomicString(isolate, "toString"), V8PerIsolateData: :from(isolate)->toStringTemplate());
2472 } 2475 }
2473 2476
2474 v8::Local<v8::FunctionTemplate> V8TestInterface::domTemplate(v8::Isolate* isolat e) 2477 v8::Local<v8::FunctionTemplate> V8TestInterface::domTemplate(v8::Isolate* isolat e)
2475 { 2478 {
2476 ASSERT(V8TestInterface::installV8TestInterfaceTemplateFunction != V8TestInte rface::installV8TestInterfaceTemplate); 2479 ASSERT(V8TestInterface::installV8TestInterfaceTemplateFunction != V8TestInte rface::installV8TestInterfaceTemplate);
2477 return V8DOMConfiguration::domClassTemplate(isolate, const_cast<WrapperTypeI nfo*>(&wrapperTypeInfo), V8TestInterface::installV8TestInterfaceTemplateFunction ); 2480 return V8DOMConfiguration::domClassTemplate(isolate, const_cast<WrapperTypeI nfo*>(&wrapperTypeInfo), V8TestInterface::installV8TestInterfaceTemplateFunction );
2478 } 2481 }
(...skipping 11 matching lines...) Expand all
2490 TestInterfaceImplementation* V8TestInterface::toImplWithTypeCheck(v8::Isolate* i solate, v8::Local<v8::Value> value) 2493 TestInterfaceImplementation* V8TestInterface::toImplWithTypeCheck(v8::Isolate* i solate, v8::Local<v8::Value> value)
2491 { 2494 {
2492 return hasInstance(value, isolate) ? toImpl(v8::Local<v8::Object>::Cast(valu e)) : 0; 2495 return hasInstance(value, isolate) ? toImpl(v8::Local<v8::Object>::Cast(valu e)) : 0;
2493 } 2496 }
2494 2497
2495 void V8TestInterface::preparePrototypeObject(v8::Isolate* isolate, v8::Local<v8: :Object> prototypeObject, v8::Local<v8::FunctionTemplate> interfaceTemplate) 2498 void V8TestInterface::preparePrototypeObject(v8::Isolate* isolate, v8::Local<v8: :Object> prototypeObject, v8::Local<v8::FunctionTemplate> interfaceTemplate)
2496 { 2499 {
2497 ExecutionContext* context = toExecutionContext(prototypeObject->CreationCont ext()); 2500 ExecutionContext* context = toExecutionContext(prototypeObject->CreationCont ext());
2498 v8::Local<v8::Signature> signature = v8::Signature::New(isolate, interfaceTe mplate); 2501 v8::Local<v8::Signature> signature = v8::Signature::New(isolate, interfaceTe mplate);
2499 if (context && (context->isWorkerGlobalScope())) { 2502 if (context && (context->isWorkerGlobalScope())) {
2500 static const V8DOMConfiguration::AccessorConfiguration accessorConfigura tion = {"workerExposedAttribute", TestInterfaceImplementationV8Internal::workerE xposedAttributeAttributeGetterCallback, TestInterfaceImplementationV8Internal::w orkerExposedAttributeAttributeSetterCallback, 0, 0, 0, static_cast<v8::AccessCon trol>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfigura tion::ExposedToAllScripts, V8DOMConfiguration::OnPrototype, V8DOMConfiguration:: CheckHolder}; 2503 static const V8DOMConfiguration::AccessorConfiguration accessorConfigura tion = {"workerExposedAttribute", TestInterfaceImplementationV8Internal::workerE xposedAttributeAttributeGetterCallback, TestInterfaceImplementationV8Internal::w orkerExposedAttributeAttributeSetterCallback, 0, 0, 0, v8::DEFAULT, static_cast< v8::PropertyAttribute>(v8::None), V8DOMConfiguration::ExposedToAllScripts, V8DOM Configuration::OnPrototype, V8DOMConfiguration::CheckHolder};
2501 V8DOMConfiguration::installAccessor(isolate, v8::Local<v8::Object>(), pr ototypeObject, v8::Local<v8::Function>(), signature, accessorConfiguration); 2504 V8DOMConfiguration::installAccessor(isolate, v8::Local<v8::Object>(), pr ototypeObject, v8::Local<v8::Function>(), signature, accessorConfiguration);
2502 } 2505 }
2503 if (context && (context->isDocument())) { 2506 if (context && (context->isDocument())) {
2504 static const V8DOMConfiguration::AccessorConfiguration accessorConfigura tion = {"windowExposedAttribute", TestInterfaceImplementationV8Internal::windowE xposedAttributeAttributeGetterCallback, TestInterfaceImplementationV8Internal::w indowExposedAttributeAttributeSetterCallback, 0, 0, 0, static_cast<v8::AccessCon trol>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::None), V8DOMConfigura tion::ExposedToAllScripts, V8DOMConfiguration::OnPrototype, V8DOMConfiguration:: CheckHolder}; 2507 static const V8DOMConfiguration::AccessorConfiguration accessorConfigura tion = {"windowExposedAttribute", TestInterfaceImplementationV8Internal::windowE xposedAttributeAttributeGetterCallback, TestInterfaceImplementationV8Internal::w indowExposedAttributeAttributeSetterCallback, 0, 0, 0, v8::DEFAULT, static_cast< v8::PropertyAttribute>(v8::None), V8DOMConfiguration::ExposedToAllScripts, V8DOM Configuration::OnPrototype, V8DOMConfiguration::CheckHolder};
2505 V8DOMConfiguration::installAccessor(isolate, v8::Local<v8::Object>(), pr ototypeObject, v8::Local<v8::Function>(), signature, accessorConfiguration); 2508 V8DOMConfiguration::installAccessor(isolate, v8::Local<v8::Object>(), pr ototypeObject, v8::Local<v8::Function>(), signature, accessorConfiguration);
2506 } 2509 }
2507 v8::Local<v8::Signature> defaultSignature = v8::Signature::New(isolate, domT emplate(isolate)); 2510 v8::Local<v8::Signature> defaultSignature = v8::Signature::New(isolate, domT emplate(isolate));
2508 ExecutionContext* context = toExecutionContext(prototypeObject->CreationCont ext()); 2511 ExecutionContext* context = toExecutionContext(prototypeObject->CreationCont ext());
2509 ASSERT(context); 2512 ASSERT(context);
2510 if (context && (context->isWorkerGlobalScope())) { 2513 if (context && (context->isWorkerGlobalScope())) {
2511 v8::Local<v8::FunctionTemplate> functionTemplate = v8::FunctionTemplate: :New(isolate, TestInterfaceImplementationV8Internal::workerExposedMethodMethodCa llback, v8Undefined(), defaultSignature, 0); 2514 v8::Local<v8::FunctionTemplate> functionTemplate = v8::FunctionTemplate: :New(isolate, TestInterfaceImplementationV8Internal::workerExposedMethodMethodCa llback, v8Undefined(), defaultSignature, 0);
2512 v8::Local<v8::Function> function = ->GetFunction(isolate->GetCurrentCont ext())).ToLocalChecked(); 2515 v8::Local<v8::Function> function = ->GetFunction(isolate->GetCurrentCont ext())).ToLocalChecked();
2513 v8CallOrCrash(prototypeObject->Set(isolate->GetCurrentContext(), v8Atomi cString(isolate, "workerExposedMethod"), function)); 2516 v8CallOrCrash(prototypeObject->Set(isolate->GetCurrentContext(), v8Atomi cString(isolate, "workerExposedMethod"), function));
2514 } 2517 }
(...skipping 153 matching lines...) Expand 10 before | Expand all | Expand 10 after
2668 void V8TestInterface::registerPartial2VoidMethodMethodForPartialInterface(void ( *method)(const v8::FunctionCallbackInfo<v8::Value>&)) 2671 void V8TestInterface::registerPartial2VoidMethodMethodForPartialInterface(void ( *method)(const v8::FunctionCallbackInfo<v8::Value>&))
2669 { 2672 {
2670 TestInterfaceImplementationV8Internal::partial2VoidMethodMethodForPartialInt erface = method; 2673 TestInterfaceImplementationV8Internal::partial2VoidMethodMethodForPartialInt erface = method;
2671 } 2674 }
2672 void V8TestInterface::registerPartial2StaticVoidMethodMethodForPartialInterface( void (*method)(const v8::FunctionCallbackInfo<v8::Value>&)) 2675 void V8TestInterface::registerPartial2StaticVoidMethodMethodForPartialInterface( void (*method)(const v8::FunctionCallbackInfo<v8::Value>&))
2673 { 2676 {
2674 TestInterfaceImplementationV8Internal::partial2StaticVoidMethodMethodForPart ialInterface = method; 2677 TestInterfaceImplementationV8Internal::partial2StaticVoidMethodMethodForPart ialInterface = method;
2675 } 2678 }
2676 } // namespace blink 2679 } // namespace blink
2677 #endif // ENABLE(CONDITION) 2680 #endif // ENABLE(CONDITION)
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698