OLD | NEW |
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 #include "V8TestObject.h" | 8 #include "V8TestObject.h" |
9 | 9 |
10 #include "bindings/core/v8/BindingSecurity.h" | 10 #include "bindings/core/v8/BindingSecurity.h" |
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
73 | 73 |
74 // This static member must be declared by DEFINE_WRAPPERTYPEINFO in TestObject.h
. | 74 // This static member must be declared by DEFINE_WRAPPERTYPEINFO in TestObject.h
. |
75 // For details, see the comment of DEFINE_WRAPPERTYPEINFO in | 75 // For details, see the comment of DEFINE_WRAPPERTYPEINFO in |
76 // bindings/core/v8/ScriptWrappable.h. | 76 // bindings/core/v8/ScriptWrappable.h. |
77 const WrapperTypeInfo& TestObject::s_wrapperTypeInfo = V8TestObject::wrapperType
Info; | 77 const WrapperTypeInfo& TestObject::s_wrapperTypeInfo = V8TestObject::wrapperType
Info; |
78 | 78 |
79 namespace TestObjectV8Internal { | 79 namespace TestObjectV8Internal { |
80 | 80 |
81 template <typename T> void V8_USE(T) { } | 81 template <typename T> void V8_USE(T) { } |
82 | 82 |
| 83 static void DEPRECATED_CONSTANTAttributeGetterCallback(v8::Local<v8::String>, co
nst v8::PropertyCallbackInfo<v8::Value>& info) |
| 84 { |
| 85 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMGetter"); |
| 86 UseCounter::countDeprecation(callingExecutionContext(info.GetIsolate()), Use
Counter::Constant); |
| 87 v8SetReturnValueInt(info, 1); |
| 88 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); |
| 89 } |
| 90 |
| 91 static void MEASURED_CONSTANTAttributeGetterCallback(v8::Local<v8::String>, cons
t v8::PropertyCallbackInfo<v8::Value>& info) |
| 92 { |
| 93 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMGetter"); |
| 94 UseCounter::count(callingExecutionContext(info.GetIsolate()), UseCounter::Co
nstant); |
| 95 v8SetReturnValueInt(info, 1); |
| 96 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); |
| 97 } |
| 98 |
83 static void stringifierAttributeAttributeGetter(const v8::PropertyCallbackInfo<v
8::Value>& info) | 99 static void stringifierAttributeAttributeGetter(const v8::PropertyCallbackInfo<v
8::Value>& info) |
84 { | 100 { |
85 v8::Handle<v8::Object> holder = info.Holder(); | 101 v8::Handle<v8::Object> holder = info.Holder(); |
86 TestObject* impl = V8TestObject::toImpl(holder); | 102 TestObject* impl = V8TestObject::toImpl(holder); |
87 v8SetReturnValueString(info, impl->stringifierAttribute(), info.GetIsolate()
); | 103 v8SetReturnValueString(info, impl->stringifierAttribute(), info.GetIsolate()
); |
88 } | 104 } |
89 | 105 |
90 static void stringifierAttributeAttributeGetterCallback(v8::Local<v8::String>, c
onst v8::PropertyCallbackInfo<v8::Value>& info) | 106 static void stringifierAttributeAttributeGetterCallback(v8::Local<v8::String>, c
onst v8::PropertyCallbackInfo<v8::Value>& info) |
91 { | 107 { |
92 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMGetter"); | 108 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMGetter"); |
(...skipping 10338 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
10431 {"CONST_VALUE_16", -0x1A, 0, 0, V8DOMConfiguration::ConstantTypeUnsigned
Short}, | 10447 {"CONST_VALUE_16", -0x1A, 0, 0, V8DOMConfiguration::ConstantTypeUnsigned
Short}, |
10432 {"CONST_VALUE_17", -0X1a, 0, 0, V8DOMConfiguration::ConstantTypeUnsigned
Short}, | 10448 {"CONST_VALUE_17", -0X1a, 0, 0, V8DOMConfiguration::ConstantTypeUnsigned
Short}, |
10433 {"CONST_VALUE_18", 0, 0.123, 0, V8DOMConfiguration::ConstantTypeDouble}, | 10449 {"CONST_VALUE_18", 0, 0.123, 0, V8DOMConfiguration::ConstantTypeDouble}, |
10434 {"CONST_VALUE_19", 0, 4e9, 0, V8DOMConfiguration::ConstantTypeDouble}, | 10450 {"CONST_VALUE_19", 0, 4e9, 0, V8DOMConfiguration::ConstantTypeDouble}, |
10435 {"CONST_VALUE_20", 0, 3.4e5, 0, V8DOMConfiguration::ConstantTypeDouble}, | 10451 {"CONST_VALUE_20", 0, 3.4e5, 0, V8DOMConfiguration::ConstantTypeDouble}, |
10436 {"CONST_VALUE_21", 0, -1.3, 0, V8DOMConfiguration::ConstantTypeDouble}, | 10452 {"CONST_VALUE_21", 0, -1.3, 0, V8DOMConfiguration::ConstantTypeDouble}, |
10437 {"CONST_VALUE_22", 0, -4e-9, 0, V8DOMConfiguration::ConstantTypeDouble}, | 10453 {"CONST_VALUE_22", 0, -4e-9, 0, V8DOMConfiguration::ConstantTypeDouble}, |
10438 {"CONST_VALUE_23", 0, .123, 0, V8DOMConfiguration::ConstantTypeDouble}, | 10454 {"CONST_VALUE_23", 0, .123, 0, V8DOMConfiguration::ConstantTypeDouble}, |
10439 {"CONST_VALUE_24", 0, 5E+4, 0, V8DOMConfiguration::ConstantTypeDouble}, | 10455 {"CONST_VALUE_24", 0, 5E+4, 0, V8DOMConfiguration::ConstantTypeDouble}, |
10440 {"CONST_VALUE_25", 0, 1, 0, V8DOMConfiguration::ConstantTypeFloat}, | 10456 {"CONST_VALUE_25", 0, 1, 0, V8DOMConfiguration::ConstantTypeFloat}, |
10441 {"DEPRECATED_CONSTANT", 1, 0, 0, V8DOMConfiguration::ConstantTypeShort}, | |
10442 {"CONST_JAVASCRIPT", 1, 0, 0, V8DOMConfiguration::ConstantTypeShort}, | 10457 {"CONST_JAVASCRIPT", 1, 0, 0, V8DOMConfiguration::ConstantTypeShort}, |
10443 }; | 10458 }; |
10444 V8DOMConfiguration::installConstants(functionTemplate, prototypeTemplate, V8
TestObjectConstants, WTF_ARRAY_LENGTH(V8TestObjectConstants), isolate); | 10459 V8DOMConfiguration::installConstants(functionTemplate, prototypeTemplate, V8
TestObjectConstants, WTF_ARRAY_LENGTH(V8TestObjectConstants), isolate); |
10445 if (RuntimeEnabledFeatures::featureNameEnabled()) { | 10460 if (RuntimeEnabledFeatures::featureNameEnabled()) { |
10446 static const V8DOMConfiguration::ConstantConfiguration constantConfigura
tion = {"FEATURE_ENABLED_CONST", 1, 0, 0, V8DOMConfiguration::ConstantTypeShort}
; | 10461 static const V8DOMConfiguration::ConstantConfiguration constantConfigura
tion = {"FEATURE_ENABLED_CONST", 1, 0, 0, V8DOMConfiguration::ConstantTypeShort}
; |
10447 V8DOMConfiguration::installConstants(functionTemplate, prototypeTemplate
, &constantConfiguration, 1, isolate); | 10462 V8DOMConfiguration::installConstants(functionTemplate, prototypeTemplate
, &constantConfiguration, 1, isolate); |
10448 } | 10463 } |
| 10464 V8DOMConfiguration::installConstant(functionTemplate, prototypeTemplate, "DE
PRECATED_CONSTANT", TestObjectV8Internal::DEPRECATED_CONSTANTConstantGetterCallb
ack, isolate); |
| 10465 V8DOMConfiguration::installConstant(functionTemplate, prototypeTemplate, "ME
ASURED_CONSTANT", TestObjectV8Internal::MEASURED_CONSTANTConstantGetterCallback,
isolate); |
10449 COMPILE_ASSERT(0 == TestObject::CONST_VALUE_0, TheValueOfTestObject_CONST_VA
LUE_0DoesntMatchWithImplementation); | 10466 COMPILE_ASSERT(0 == TestObject::CONST_VALUE_0, TheValueOfTestObject_CONST_VA
LUE_0DoesntMatchWithImplementation); |
10450 COMPILE_ASSERT(1 == TestObject::CONST_VALUE_1, TheValueOfTestObject_CONST_VA
LUE_1DoesntMatchWithImplementation); | 10467 COMPILE_ASSERT(1 == TestObject::CONST_VALUE_1, TheValueOfTestObject_CONST_VA
LUE_1DoesntMatchWithImplementation); |
10451 COMPILE_ASSERT(2 == TestObject::CONST_VALUE_2, TheValueOfTestObject_CONST_VA
LUE_2DoesntMatchWithImplementation); | 10468 COMPILE_ASSERT(2 == TestObject::CONST_VALUE_2, TheValueOfTestObject_CONST_VA
LUE_2DoesntMatchWithImplementation); |
10452 COMPILE_ASSERT(4 == TestObject::CONST_VALUE_4, TheValueOfTestObject_CONST_VA
LUE_4DoesntMatchWithImplementation); | 10469 COMPILE_ASSERT(4 == TestObject::CONST_VALUE_4, TheValueOfTestObject_CONST_VA
LUE_4DoesntMatchWithImplementation); |
10453 COMPILE_ASSERT(8 == TestObject::CONST_VALUE_8, TheValueOfTestObject_CONST_VA
LUE_8DoesntMatchWithImplementation); | 10470 COMPILE_ASSERT(8 == TestObject::CONST_VALUE_8, TheValueOfTestObject_CONST_VA
LUE_8DoesntMatchWithImplementation); |
10454 COMPILE_ASSERT(-1 == TestObject::CONST_VALUE_9, TheValueOfTestObject_CONST_V
ALUE_9DoesntMatchWithImplementation); | 10471 COMPILE_ASSERT(-1 == TestObject::CONST_VALUE_9, TheValueOfTestObject_CONST_V
ALUE_9DoesntMatchWithImplementation); |
10455 COMPILE_ASSERT(0xffffffff == TestObject::CONST_VALUE_11, TheValueOfTestObjec
t_CONST_VALUE_11DoesntMatchWithImplementation); | 10472 COMPILE_ASSERT(0xffffffff == TestObject::CONST_VALUE_11, TheValueOfTestObjec
t_CONST_VALUE_11DoesntMatchWithImplementation); |
10456 COMPILE_ASSERT(0x01 == TestObject::CONST_VALUE_12, TheValueOfTestObject_CONS
T_VALUE_12DoesntMatchWithImplementation); | 10473 COMPILE_ASSERT(0x01 == TestObject::CONST_VALUE_12, TheValueOfTestObject_CONS
T_VALUE_12DoesntMatchWithImplementation); |
10457 COMPILE_ASSERT(0X20 == TestObject::CONST_VALUE_13, TheValueOfTestObject_CONS
T_VALUE_13DoesntMatchWithImplementation); | 10474 COMPILE_ASSERT(0X20 == TestObject::CONST_VALUE_13, TheValueOfTestObject_CONS
T_VALUE_13DoesntMatchWithImplementation); |
10458 COMPILE_ASSERT(0x1abc == TestObject::CONST_VALUE_14, TheValueOfTestObject_CO
NST_VALUE_14DoesntMatchWithImplementation); | 10475 COMPILE_ASSERT(0x1abc == TestObject::CONST_VALUE_14, TheValueOfTestObject_CO
NST_VALUE_14DoesntMatchWithImplementation); |
10459 COMPILE_ASSERT(010 == TestObject::CONST_VALUE_15, TheValueOfTestObject_CONST
_VALUE_15DoesntMatchWithImplementation); | 10476 COMPILE_ASSERT(010 == TestObject::CONST_VALUE_15, TheValueOfTestObject_CONST
_VALUE_15DoesntMatchWithImplementation); |
10460 COMPILE_ASSERT(-010 == TestObject::CONST_VALUE_16, TheValueOfTestObject_CONS
T_VALUE_16DoesntMatchWithImplementation); | 10477 COMPILE_ASSERT(-010 == TestObject::CONST_VALUE_16, TheValueOfTestObject_CONS
T_VALUE_16DoesntMatchWithImplementation); |
10461 COMPILE_ASSERT(-0x1A == TestObject::CONST_VALUE_16, TheValueOfTestObject_CON
ST_VALUE_16DoesntMatchWithImplementation); | 10478 COMPILE_ASSERT(-0x1A == TestObject::CONST_VALUE_16, TheValueOfTestObject_CON
ST_VALUE_16DoesntMatchWithImplementation); |
10462 COMPILE_ASSERT(-0X1a == TestObject::CONST_VALUE_17, TheValueOfTestObject_CON
ST_VALUE_17DoesntMatchWithImplementation); | 10479 COMPILE_ASSERT(-0X1a == TestObject::CONST_VALUE_17, TheValueOfTestObject_CON
ST_VALUE_17DoesntMatchWithImplementation); |
10463 COMPILE_ASSERT(1 == TestObject::DEPRECATED_CONSTANT, TheValueOfTestObject_DE
PRECATED_CONSTANTDoesntMatchWithImplementation); | 10480 COMPILE_ASSERT(1 == TestObject::DEPRECATED_CONSTANT, TheValueOfTestObject_DE
PRECATED_CONSTANTDoesntMatchWithImplementation); |
| 10481 COMPILE_ASSERT(1 == TestObject::MEASURED_CONSTANT, TheValueOfTestObject_MEAS
URED_CONSTANTDoesntMatchWithImplementation); |
10464 COMPILE_ASSERT(1 == TestObject::FEATURE_ENABLED_CONST, TheValueOfTestObject_
FEATURE_ENABLED_CONSTDoesntMatchWithImplementation); | 10482 COMPILE_ASSERT(1 == TestObject::FEATURE_ENABLED_CONST, TheValueOfTestObject_
FEATURE_ENABLED_CONSTDoesntMatchWithImplementation); |
10465 COMPILE_ASSERT(1 == TestObject::CONST_IMPL, TheValueOfTestObject_CONST_IMPLD
oesntMatchWithImplementation); | 10483 COMPILE_ASSERT(1 == TestObject::CONST_IMPL, TheValueOfTestObject_CONST_IMPLD
oesntMatchWithImplementation); |
10466 static const V8DOMConfiguration::MethodConfiguration staticVoidMethodMethodC
onfiguration = { | 10484 static const V8DOMConfiguration::MethodConfiguration staticVoidMethodMethodC
onfiguration = { |
10467 "staticVoidMethod", TestObjectV8Internal::staticVoidMethodMethodCallback
, 0, 0, V8DOMConfiguration::ExposedToAllScripts, | 10485 "staticVoidMethod", TestObjectV8Internal::staticVoidMethodMethodCallback
, 0, 0, V8DOMConfiguration::ExposedToAllScripts, |
10468 }; | 10486 }; |
10469 V8DOMConfiguration::installMethod(functionTemplate, v8::Local<v8::Signature>
(), v8::None, staticVoidMethodMethodConfiguration, isolate); | 10487 V8DOMConfiguration::installMethod(functionTemplate, v8::Local<v8::Signature>
(), v8::None, staticVoidMethodMethodConfiguration, isolate); |
10470 static const V8DOMConfiguration::MethodConfiguration overloadedStaticMethodM
ethodConfiguration = { | 10488 static const V8DOMConfiguration::MethodConfiguration overloadedStaticMethodM
ethodConfiguration = { |
10471 "overloadedStaticMethod", TestObjectV8Internal::overloadedStaticMethodMe
thodCallback, 0, 1, V8DOMConfiguration::ExposedToAllScripts, | 10489 "overloadedStaticMethod", TestObjectV8Internal::overloadedStaticMethodMe
thodCallback, 0, 1, V8DOMConfiguration::ExposedToAllScripts, |
10472 }; | 10490 }; |
10473 V8DOMConfiguration::installMethod(functionTemplate, v8::Local<v8::Signature>
(), v8::None, overloadedStaticMethodMethodConfiguration, isolate); | 10491 V8DOMConfiguration::installMethod(functionTemplate, v8::Local<v8::Signature>
(), v8::None, overloadedStaticMethodMethodConfiguration, isolate); |
(...skipping 644 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
11118 PrivateScriptRunner::runDOMAttributeSetter(scriptState, "TestObject", "enumF
orPrivateScript", holder, v8String(scriptState->isolate(), cppValue)); | 11136 PrivateScriptRunner::runDOMAttributeSetter(scriptState, "TestObject", "enumF
orPrivateScript", holder, v8String(scriptState->isolate(), cppValue)); |
11119 if (block.HasCaught()) { | 11137 if (block.HasCaught()) { |
11120 PrivateScriptRunner::rethrowExceptionInPrivateScript(scriptState->isolat
e(), exceptionState, block); | 11138 PrivateScriptRunner::rethrowExceptionInPrivateScript(scriptState->isolat
e(), exceptionState, block); |
11121 block.ReThrow(); | 11139 block.ReThrow(); |
11122 return false; | 11140 return false; |
11123 } | 11141 } |
11124 return true; | 11142 return true; |
11125 } | 11143 } |
11126 | 11144 |
11127 } // namespace blink | 11145 } // namespace blink |
OLD | NEW |