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

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

Issue 1051753003: bindings: Add toBoolean() to V8Binding.h (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 years, 8 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
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 #include "V8TestInterfaceNode.h" 8 #include "V8TestInterfaceNode.h"
9 9
10 #include "bindings/core/v8/ExceptionState.h" 10 #include "bindings/core/v8/ExceptionState.h"
(...skipping 258 matching lines...) Expand 10 before | Expand all | Expand 10 after
269 269
270 static void perWorldBindingsTestInterfaceEmptyMethodMethodCallbackForMainWorld(c onst v8::FunctionCallbackInfo<v8::Value>& info) 270 static void perWorldBindingsTestInterfaceEmptyMethodMethodCallbackForMainWorld(c onst v8::FunctionCallbackInfo<v8::Value>& info)
271 { 271 {
272 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMMethod"); 272 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMMethod");
273 TestInterfaceNodeV8Internal::perWorldBindingsTestInterfaceEmptyMethodMethodF orMainWorld(info); 273 TestInterfaceNodeV8Internal::perWorldBindingsTestInterfaceEmptyMethodMethodF orMainWorld(info);
274 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); 274 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
275 } 275 }
276 276
277 static void perWorldBindingsTestInterfaceEmptyMethodOptionalBooleanArgMethod(con st v8::FunctionCallbackInfo<v8::Value>& info) 277 static void perWorldBindingsTestInterfaceEmptyMethodOptionalBooleanArgMethod(con st v8::FunctionCallbackInfo<v8::Value>& info)
278 { 278 {
279 ExceptionState exceptionState(ExceptionState::ExecutionContext, "perWorldBin dingsTestInterfaceEmptyMethodOptionalBooleanArg", "TestInterfaceNode", info.Hold er(), info.GetIsolate());
279 TestInterfaceNode* impl = V8TestInterfaceNode::toImpl(info.Holder()); 280 TestInterfaceNode* impl = V8TestInterfaceNode::toImpl(info.Holder());
280 bool optionalBooleanArgument; 281 bool optionalBooleanArgument;
281 { 282 {
282 if (UNLIKELY(info.Length() <= 0)) { 283 if (UNLIKELY(info.Length() <= 0)) {
283 v8SetReturnValueFast(info, WTF::getPtr(impl->perWorldBindingsTestInt erfaceEmptyMethodOptionalBooleanArg()), impl); 284 v8SetReturnValueFast(info, WTF::getPtr(impl->perWorldBindingsTestInt erfaceEmptyMethodOptionalBooleanArg()), impl);
284 return; 285 return;
285 } 286 }
286 optionalBooleanArgument = info[0]->BooleanValue(); 287 optionalBooleanArgument = toBoolean(info.GetIsolate(), info[0], exceptio nState);
288 if (exceptionState.throwIfNeeded())
289 return;
287 } 290 }
288 v8SetReturnValueFast(info, WTF::getPtr(impl->perWorldBindingsTestInterfaceEm ptyMethodOptionalBooleanArg(optionalBooleanArgument)), impl); 291 v8SetReturnValueFast(info, WTF::getPtr(impl->perWorldBindingsTestInterfaceEm ptyMethodOptionalBooleanArg(optionalBooleanArgument)), impl);
289 } 292 }
290 293
291 static void perWorldBindingsTestInterfaceEmptyMethodOptionalBooleanArgMethodCall back(const v8::FunctionCallbackInfo<v8::Value>& info) 294 static void perWorldBindingsTestInterfaceEmptyMethodOptionalBooleanArgMethodCall back(const v8::FunctionCallbackInfo<v8::Value>& info)
292 { 295 {
293 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMMethod"); 296 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMMethod");
294 TestInterfaceNodeV8Internal::perWorldBindingsTestInterfaceEmptyMethodOptiona lBooleanArgMethod(info); 297 TestInterfaceNodeV8Internal::perWorldBindingsTestInterfaceEmptyMethodOptiona lBooleanArgMethod(info);
295 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); 298 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
296 } 299 }
297 300
298 static void perWorldBindingsTestInterfaceEmptyMethodOptionalBooleanArgMethodForM ainWorld(const v8::FunctionCallbackInfo<v8::Value>& info) 301 static void perWorldBindingsTestInterfaceEmptyMethodOptionalBooleanArgMethodForM ainWorld(const v8::FunctionCallbackInfo<v8::Value>& info)
299 { 302 {
303 ExceptionState exceptionState(ExceptionState::ExecutionContext, "perWorldBin dingsTestInterfaceEmptyMethodOptionalBooleanArg", "TestInterfaceNode", info.Hold er(), info.GetIsolate());
300 TestInterfaceNode* impl = V8TestInterfaceNode::toImpl(info.Holder()); 304 TestInterfaceNode* impl = V8TestInterfaceNode::toImpl(info.Holder());
301 bool optionalBooleanArgument; 305 bool optionalBooleanArgument;
302 { 306 {
303 if (UNLIKELY(info.Length() <= 0)) { 307 if (UNLIKELY(info.Length() <= 0)) {
304 v8SetReturnValueForMainWorld(info, WTF::getPtr(impl->perWorldBinding sTestInterfaceEmptyMethodOptionalBooleanArg())); 308 v8SetReturnValueForMainWorld(info, WTF::getPtr(impl->perWorldBinding sTestInterfaceEmptyMethodOptionalBooleanArg()));
305 return; 309 return;
306 } 310 }
307 optionalBooleanArgument = info[0]->BooleanValue(); 311 optionalBooleanArgument = toBoolean(info.GetIsolate(), info[0], exceptio nState);
312 if (exceptionState.throwIfNeeded())
313 return;
308 } 314 }
309 v8SetReturnValueForMainWorld(info, WTF::getPtr(impl->perWorldBindingsTestInt erfaceEmptyMethodOptionalBooleanArg(optionalBooleanArgument))); 315 v8SetReturnValueForMainWorld(info, WTF::getPtr(impl->perWorldBindingsTestInt erfaceEmptyMethodOptionalBooleanArg(optionalBooleanArgument)));
310 } 316 }
311 317
312 static void perWorldBindingsTestInterfaceEmptyMethodOptionalBooleanArgMethodCall backForMainWorld(const v8::FunctionCallbackInfo<v8::Value>& info) 318 static void perWorldBindingsTestInterfaceEmptyMethodOptionalBooleanArgMethodCall backForMainWorld(const v8::FunctionCallbackInfo<v8::Value>& info)
313 { 319 {
314 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMMethod"); 320 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMMethod");
315 TestInterfaceNodeV8Internal::perWorldBindingsTestInterfaceEmptyMethodOptiona lBooleanArgMethodForMainWorld(info); 321 TestInterfaceNodeV8Internal::perWorldBindingsTestInterfaceEmptyMethodOptiona lBooleanArgMethodForMainWorld(info);
316 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); 322 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution");
317 } 323 }
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after
380 } 386 }
381 387
382 void V8TestInterfaceNode::derefObject(ScriptWrappable* scriptWrappable) 388 void V8TestInterfaceNode::derefObject(ScriptWrappable* scriptWrappable)
383 { 389 {
384 #if !ENABLE(OILPAN) 390 #if !ENABLE(OILPAN)
385 scriptWrappable->toImpl<TestInterfaceNode>()->deref(); 391 scriptWrappable->toImpl<TestInterfaceNode>()->deref();
386 #endif 392 #endif
387 } 393 }
388 394
389 } // namespace blink 395 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698