| 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 #if ENABLE(CONDITION) | 8 #if ENABLE(CONDITION) |
| 9 #include "V8TestInterface.h" | 9 #include "V8TestInterface.h" |
| 10 | 10 |
| (...skipping 969 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 980 V8ThrowException::throwException(createMinimumArityTypeErrorForMethod("v
oidMethodTestInterfaceEmptyArg", "TestInterface", 1, info.Length(), info.GetIsol
ate()), info.GetIsolate()); | 980 V8ThrowException::throwException(createMinimumArityTypeErrorForMethod("v
oidMethodTestInterfaceEmptyArg", "TestInterface", 1, info.Length(), info.GetIsol
ate()), info.GetIsolate()); |
| 981 return; | 981 return; |
| 982 } | 982 } |
| 983 TestInterfaceImplementation* impl = V8TestInterface::toImpl(info.Holder()); | 983 TestInterfaceImplementation* impl = V8TestInterface::toImpl(info.Holder()); |
| 984 TestInterfaceEmpty* testInterfaceEmptyArg; | 984 TestInterfaceEmpty* testInterfaceEmptyArg; |
| 985 { | 985 { |
| 986 if (info.Length() > 0 && !V8TestInterfaceEmpty::hasInstance(info[0], inf
o.GetIsolate())) { | 986 if (info.Length() > 0 && !V8TestInterfaceEmpty::hasInstance(info[0], inf
o.GetIsolate())) { |
| 987 V8ThrowException::throwTypeError(ExceptionMessages::failedToExecute(
"voidMethodTestInterfaceEmptyArg", "TestInterface", "parameter 1 is not of type
'TestInterfaceEmpty'."), info.GetIsolate()); | 987 V8ThrowException::throwTypeError(ExceptionMessages::failedToExecute(
"voidMethodTestInterfaceEmptyArg", "TestInterface", "parameter 1 is not of type
'TestInterfaceEmpty'."), info.GetIsolate()); |
| 988 return; | 988 return; |
| 989 } | 989 } |
| 990 testInterfaceEmptyArg = V8TestInterfaceEmpty::toImplWithTypeCheck(info.G
etIsolate(), info[0]); | 990 testInterfaceEmptyArg = V8TestInterfaceEmpty::toImpl(v8::Handle<v8::Obje
ct>::Cast(info[0])); |
| 991 } | 991 } |
| 992 impl->voidMethodTestInterfaceEmptyArg(testInterfaceEmptyArg); | 992 impl->voidMethodTestInterfaceEmptyArg(testInterfaceEmptyArg); |
| 993 } | 993 } |
| 994 | 994 |
| 995 static void voidMethodTestInterfaceEmptyArgMethodCallback(const v8::FunctionCall
backInfo<v8::Value>& info) | 995 static void voidMethodTestInterfaceEmptyArgMethodCallback(const v8::FunctionCall
backInfo<v8::Value>& info) |
| 996 { | 996 { |
| 997 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMMethod"); | 997 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMMethod"); |
| 998 TestInterfaceImplementationV8Internal::voidMethodTestInterfaceEmptyArgMethod
(info); | 998 TestInterfaceImplementationV8Internal::voidMethodTestInterfaceEmptyArgMethod
(info); |
| 999 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); | 999 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); |
| 1000 } | 1000 } |
| (...skipping 221 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1222 TestInterfaceImplementation* impl = V8TestInterface::toImpl(info.Holder()); | 1222 TestInterfaceImplementation* impl = V8TestInterface::toImpl(info.Holder()); |
| 1223 V8StringResource<> strArg; | 1223 V8StringResource<> strArg; |
| 1224 TestInterfaceEmpty* testInterfaceEmptyArg; | 1224 TestInterfaceEmpty* testInterfaceEmptyArg; |
| 1225 { | 1225 { |
| 1226 TOSTRING_VOID_INTERNAL(strArg, info[0]); | 1226 TOSTRING_VOID_INTERNAL(strArg, info[0]); |
| 1227 if (info.Length() > 1 && !V8TestInterfaceEmpty::hasInstance(info[1], inf
o.GetIsolate())) { | 1227 if (info.Length() > 1 && !V8TestInterfaceEmpty::hasInstance(info[1], inf
o.GetIsolate())) { |
| 1228 exceptionState.throwTypeError("parameter 2 is not of type 'TestInter
faceEmpty'."); | 1228 exceptionState.throwTypeError("parameter 2 is not of type 'TestInter
faceEmpty'."); |
| 1229 exceptionState.throwIfNeeded(); | 1229 exceptionState.throwIfNeeded(); |
| 1230 return; | 1230 return; |
| 1231 } | 1231 } |
| 1232 testInterfaceEmptyArg = V8TestInterfaceEmpty::toImplWithTypeCheck(info.G
etIsolate(), info[1]); | 1232 testInterfaceEmptyArg = V8TestInterfaceEmpty::toImpl(v8::Handle<v8::Obje
ct>::Cast(info[1])); |
| 1233 } | 1233 } |
| 1234 ExecutionContext* executionContext = currentExecutionContext(info.GetIsolate
()); | 1234 ExecutionContext* executionContext = currentExecutionContext(info.GetIsolate
()); |
| 1235 RefPtr<TestInterfaceEmpty> result = impl->implementsComplexMethod(executionC
ontext, strArg, testInterfaceEmptyArg, exceptionState); | 1235 RefPtr<TestInterfaceEmpty> result = impl->implementsComplexMethod(executionC
ontext, strArg, testInterfaceEmptyArg, exceptionState); |
| 1236 if (exceptionState.hadException()) { | 1236 if (exceptionState.hadException()) { |
| 1237 exceptionState.throwIfNeeded(); | 1237 exceptionState.throwIfNeeded(); |
| 1238 return; | 1238 return; |
| 1239 } | 1239 } |
| 1240 v8SetReturnValue(info, result.release()); | 1240 v8SetReturnValue(info, result.release()); |
| 1241 } | 1241 } |
| 1242 | 1242 |
| (...skipping 920 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2163 | 2163 |
| 2164 ScriptState::Scope scope(scriptState); | 2164 ScriptState::Scope scope(scriptState); |
| 2165 v8::Handle<v8::Value> holder = toV8(holderImpl, scriptState->context()->Glob
al(), scriptState->isolate()); | 2165 v8::Handle<v8::Value> holder = toV8(holderImpl, scriptState->context()->Glob
al(), scriptState->isolate()); |
| 2166 | 2166 |
| 2167 ExceptionState exceptionState(ExceptionState::SetterContext, "stringAttribut
e", "TestInterfaceImplementation", scriptState->context()->Global(), scriptState
->isolate()); | 2167 ExceptionState exceptionState(ExceptionState::SetterContext, "stringAttribut
e", "TestInterfaceImplementation", scriptState->context()->Global(), scriptState
->isolate()); |
| 2168 return PrivateScriptRunner::runDOMAttributeSetter(scriptState, scriptStateIn
UserScript, "TestInterfaceImplementation", "stringAttribute", holder, v8String(s
criptState->isolate(), cppValue)); | 2168 return PrivateScriptRunner::runDOMAttributeSetter(scriptState, scriptStateIn
UserScript, "TestInterfaceImplementation", "stringAttribute", holder, v8String(s
criptState->isolate(), cppValue)); |
| 2169 } | 2169 } |
| 2170 | 2170 |
| 2171 } // namespace blink | 2171 } // namespace blink |
| 2172 #endif // ENABLE(CONDITION) | 2172 #endif // ENABLE(CONDITION) |
| OLD | NEW |