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 "V8TestInterfaceNode.h" | 8 #include "V8TestInterfaceNode.h" |
9 | 9 |
10 #include "bindings/core/v8/ExceptionState.h" | 10 #include "bindings/core/v8/ExceptionState.h" |
| 11 #include "bindings/core/v8/Optional.h" |
11 #include "bindings/core/v8/V8AbstractEventListener.h" | 12 #include "bindings/core/v8/V8AbstractEventListener.h" |
12 #include "bindings/core/v8/V8DOMConfiguration.h" | 13 #include "bindings/core/v8/V8DOMConfiguration.h" |
13 #include "bindings/core/v8/V8EventListenerList.h" | 14 #include "bindings/core/v8/V8EventListenerList.h" |
14 #include "bindings/core/v8/V8HiddenValue.h" | 15 #include "bindings/core/v8/V8HiddenValue.h" |
15 #include "bindings/core/v8/V8ObjectConstructor.h" | 16 #include "bindings/core/v8/V8ObjectConstructor.h" |
16 #include "bindings/tests/v8/V8TestInterfaceEmpty.h" | 17 #include "bindings/tests/v8/V8TestInterfaceEmpty.h" |
17 #include "core/HTMLNames.h" | 18 #include "core/HTMLNames.h" |
18 #include "core/dom/ContextFeatures.h" | 19 #include "core/dom/ContextFeatures.h" |
19 #include "core/dom/Document.h" | 20 #include "core/dom/Document.h" |
20 #include "core/dom/custom/CustomElementCallbackDispatcher.h" | 21 #include "core/dom/custom/CustomElementCallbackDispatcher.h" |
(...skipping 221 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
242 static void perWorldBindingsTestInterfaceEmptyMethodMethodCallbackForMainWorld(c
onst v8::FunctionCallbackInfo<v8::Value>& info) | 243 static void perWorldBindingsTestInterfaceEmptyMethodMethodCallbackForMainWorld(c
onst v8::FunctionCallbackInfo<v8::Value>& info) |
243 { | 244 { |
244 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMMethod"); | 245 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMMethod"); |
245 TestInterfaceNodeV8Internal::perWorldBindingsTestInterfaceEmptyMethodMethodF
orMainWorld(info); | 246 TestInterfaceNodeV8Internal::perWorldBindingsTestInterfaceEmptyMethodMethodF
orMainWorld(info); |
246 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); | 247 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); |
247 } | 248 } |
248 | 249 |
249 static void perWorldBindingsTestInterfaceEmptyMethodOptionalBooleanArgMethod(con
st v8::FunctionCallbackInfo<v8::Value>& info) | 250 static void perWorldBindingsTestInterfaceEmptyMethodOptionalBooleanArgMethod(con
st v8::FunctionCallbackInfo<v8::Value>& info) |
250 { | 251 { |
251 TestInterfaceNode* impl = V8TestInterfaceNode::toNative(info.Holder()); | 252 TestInterfaceNode* impl = V8TestInterfaceNode::toNative(info.Holder()); |
252 bool optionalBooleanArgument; | 253 bool optionalBooleanArgument = false; |
| 254 bool optionalBooleanArgumentMissing = false; |
253 { | 255 { |
254 v8::TryCatch block; | 256 v8::TryCatch block; |
255 V8RethrowTryCatchScope rethrow(block); | 257 V8RethrowTryCatchScope rethrow(block); |
256 if (UNLIKELY(info.Length() <= 0)) { | 258 if (!info[0]->IsUndefined()) { |
257 v8SetReturnValueFast(info, WTF::getPtr(impl->perWorldBindingsTestInt
erfaceEmptyMethodOptionalBooleanArg()), impl); | 259 TONATIVE_VOID_INTERNAL(optionalBooleanArgument, info[0]->BooleanValu
e()); |
258 return; | 260 } else { |
| 261 optionalBooleanArgumentMissing = true; |
259 } | 262 } |
260 TONATIVE_VOID_INTERNAL(optionalBooleanArgument, info[0]->BooleanValue())
; | |
261 } | 263 } |
262 v8SetReturnValueFast(info, WTF::getPtr(impl->perWorldBindingsTestInterfaceEm
ptyMethodOptionalBooleanArg(optionalBooleanArgument)), impl); | 264 v8SetReturnValueFast(info, WTF::getPtr(impl->perWorldBindingsTestInterfaceEm
ptyMethodOptionalBooleanArg(Optional<bool>(optionalBooleanArgument, optionalBool
eanArgumentMissing))), impl); |
263 } | 265 } |
264 | 266 |
265 static void perWorldBindingsTestInterfaceEmptyMethodOptionalBooleanArgMethodCall
back(const v8::FunctionCallbackInfo<v8::Value>& info) | 267 static void perWorldBindingsTestInterfaceEmptyMethodOptionalBooleanArgMethodCall
back(const v8::FunctionCallbackInfo<v8::Value>& info) |
266 { | 268 { |
267 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMMethod"); | 269 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMMethod"); |
268 TestInterfaceNodeV8Internal::perWorldBindingsTestInterfaceEmptyMethodOptiona
lBooleanArgMethod(info); | 270 TestInterfaceNodeV8Internal::perWorldBindingsTestInterfaceEmptyMethodOptiona
lBooleanArgMethod(info); |
269 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); | 271 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); |
270 } | 272 } |
271 | 273 |
272 static void perWorldBindingsTestInterfaceEmptyMethodOptionalBooleanArgMethodForM
ainWorld(const v8::FunctionCallbackInfo<v8::Value>& info) | 274 static void perWorldBindingsTestInterfaceEmptyMethodOptionalBooleanArgMethodForM
ainWorld(const v8::FunctionCallbackInfo<v8::Value>& info) |
273 { | 275 { |
274 TestInterfaceNode* impl = V8TestInterfaceNode::toNative(info.Holder()); | 276 TestInterfaceNode* impl = V8TestInterfaceNode::toNative(info.Holder()); |
275 bool optionalBooleanArgument; | 277 bool optionalBooleanArgument = false; |
| 278 bool optionalBooleanArgumentMissing = false; |
276 { | 279 { |
277 v8::TryCatch block; | 280 v8::TryCatch block; |
278 V8RethrowTryCatchScope rethrow(block); | 281 V8RethrowTryCatchScope rethrow(block); |
279 if (UNLIKELY(info.Length() <= 0)) { | 282 if (!info[0]->IsUndefined()) { |
280 v8SetReturnValueForMainWorld(info, WTF::getPtr(impl->perWorldBinding
sTestInterfaceEmptyMethodOptionalBooleanArg())); | 283 TONATIVE_VOID_INTERNAL(optionalBooleanArgument, info[0]->BooleanValu
e()); |
281 return; | 284 } else { |
| 285 optionalBooleanArgumentMissing = true; |
282 } | 286 } |
283 TONATIVE_VOID_INTERNAL(optionalBooleanArgument, info[0]->BooleanValue())
; | |
284 } | 287 } |
285 v8SetReturnValueForMainWorld(info, WTF::getPtr(impl->perWorldBindingsTestInt
erfaceEmptyMethodOptionalBooleanArg(optionalBooleanArgument))); | 288 v8SetReturnValueForMainWorld(info, WTF::getPtr(impl->perWorldBindingsTestInt
erfaceEmptyMethodOptionalBooleanArg(Optional<bool>(optionalBooleanArgument, opti
onalBooleanArgumentMissing)))); |
286 } | 289 } |
287 | 290 |
288 static void perWorldBindingsTestInterfaceEmptyMethodOptionalBooleanArgMethodCall
backForMainWorld(const v8::FunctionCallbackInfo<v8::Value>& info) | 291 static void perWorldBindingsTestInterfaceEmptyMethodOptionalBooleanArgMethodCall
backForMainWorld(const v8::FunctionCallbackInfo<v8::Value>& info) |
289 { | 292 { |
290 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMMethod"); | 293 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMMethod"); |
291 TestInterfaceNodeV8Internal::perWorldBindingsTestInterfaceEmptyMethodOptiona
lBooleanArgMethodForMainWorld(info); | 294 TestInterfaceNodeV8Internal::perWorldBindingsTestInterfaceEmptyMethodOptiona
lBooleanArgMethodForMainWorld(info); |
292 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); | 295 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); |
293 } | 296 } |
294 | 297 |
295 } // namespace TestInterfaceNodeV8Internal | 298 } // namespace TestInterfaceNodeV8Internal |
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
385 #endif // !ENABLE(OILPAN) | 388 #endif // !ENABLE(OILPAN) |
386 } | 389 } |
387 | 390 |
388 template<> | 391 template<> |
389 v8::Handle<v8::Value> toV8NoInline(TestInterfaceNode* impl, v8::Handle<v8::Objec
t> creationContext, v8::Isolate* isolate) | 392 v8::Handle<v8::Value> toV8NoInline(TestInterfaceNode* impl, v8::Handle<v8::Objec
t> creationContext, v8::Isolate* isolate) |
390 { | 393 { |
391 return toV8(impl, creationContext, isolate); | 394 return toV8(impl, creationContext, isolate); |
392 } | 395 } |
393 | 396 |
394 } // namespace blink | 397 } // namespace blink |
OLD | NEW |