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

Side by Side Diff: third_party/WebKit/Source/bindings/tests/results/modules/V8TestInterface2Partial.cpp

Issue 1884423002: IDL bindings: Avoid extended attributes leaking onto merged interface. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Remove TestPartialInterface4.idl (which doesn't exist) from list. Created 4 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
(Empty)
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
3 // found in the LICENSE file.
4
5 // This file has been auto-generated by code_generator_v8.py. DO NOT MODIFY!
6
7 #include "V8TestInterface2Partial.h"
8
9 #include "bindings/core/v8/ExceptionState.h"
10 #include "bindings/core/v8/V8DOMConfiguration.h"
11 #include "bindings/core/v8/V8GCController.h"
12 #include "bindings/core/v8/V8ObjectConstructor.h"
13 #include "bindings/core/v8/V8TestInterface2.h"
14 #include "bindings/tests/idls/modules/TestInterface2Partial.h"
15 #include "bindings/tests/idls/modules/TestInterface2Partial2.h"
16 #include "core/dom/Document.h"
17 #include "core/dom/Element.h"
18 #include "platform/RuntimeEnabledFeatures.h"
19 #include "wtf/GetPtr.h"
20 #include "wtf/RefPtr.h"
21
22 namespace blink {
23
24 namespace TestInterface2PartialV8Internal {
25
26 static void voidMethodPartial1Method(const v8::FunctionCallbackInfo<v8::Value>& info)
27 {
28 if (UNLIKELY(info.Length() < 1)) {
29 V8ThrowException::throwException(createMinimumArityTypeErrorForMethod(in fo.GetIsolate(), "voidMethodPartial1", "TestInterface2", 1, info.Length()), info .GetIsolate());
30 return;
31 }
32 TestInterface2* impl = V8TestInterface2::toImpl(info.Holder());
33 V8StringResource<> value;
34 {
35 value = info[0];
36 if (!value.prepare())
37 return;
38 }
39 TestInterface2Partial::voidMethodPartial1(*impl, value);
40 }
41
42 static void voidMethodPartial1MethodCallback(const v8::FunctionCallbackInfo<v8:: Value>& info)
43 {
44 TestInterface2PartialV8Internal::voidMethodPartial1Method(info);
45 }
46
47 static void voidMethodPartial2Method(const v8::FunctionCallbackInfo<v8::Value>& info)
48 {
49 if (UNLIKELY(info.Length() < 1)) {
50 V8ThrowException::throwException(createMinimumArityTypeErrorForMethod(in fo.GetIsolate(), "voidMethodPartial2", "TestInterface2", 1, info.Length()), info .GetIsolate());
51 return;
52 }
53 TestInterface2* impl = V8TestInterface2::toImpl(info.Holder());
54 V8StringResource<> value;
55 {
56 value = info[0];
57 if (!value.prepare())
58 return;
59 }
60 TestInterface2Partial2::voidMethodPartial2(*impl, value);
61 }
62
63 static void voidMethodPartial2MethodCallback(const v8::FunctionCallbackInfo<v8:: Value>& info)
64 {
65 TestInterface2PartialV8Internal::voidMethodPartial2Method(info);
66 }
67
68 } // namespace TestInterface2PartialV8Internal
69
70 const V8DOMConfiguration::MethodConfiguration V8TestInterface2Methods[] = {
71 {"voidMethodPartial2", TestInterface2PartialV8Internal::voidMethodPartial2Me thodCallback, 0, 1, v8::None, V8DOMConfiguration::ExposedToAllScripts, V8DOMConf iguration::OnPrototype},
72 };
73
74 void V8TestInterface2Partial::installV8TestInterface2Template(v8::Isolate* isola te, const DOMWrapperWorld& world, v8::Local<v8::FunctionTemplate> interfaceTempl ate)
75 {
76 // Initialize the interface object's template.
77 V8TestInterface2::installV8TestInterface2Template(isolate, world, interfaceT emplate);
78 v8::Local<v8::Signature> signature = v8::Signature::New(isolate, interfaceTe mplate);
79 ALLOW_UNUSED_LOCAL(signature);
80 v8::Local<v8::ObjectTemplate> instanceTemplate = interfaceTemplate->Instance Template();
81 ALLOW_UNUSED_LOCAL(instanceTemplate);
82 v8::Local<v8::ObjectTemplate> prototypeTemplate = interfaceTemplate->Prototy peTemplate();
83 ALLOW_UNUSED_LOCAL(prototypeTemplate);
84 // Register DOM constants, attributes and operations.
85 V8DOMConfiguration::installMethods(isolate, world, instanceTemplate, prototy peTemplate, interfaceTemplate, signature, V8TestInterface2Methods, WTF_ARRAY_LEN GTH(V8TestInterface2Methods));
86
87 if (RuntimeEnabledFeatures::interface2PartialFeatureNameEnabled()) {
88 const V8DOMConfiguration::MethodConfiguration voidMethodPartial1MethodCo nfiguration = {"voidMethodPartial1", TestInterface2PartialV8Internal::voidMethod Partial1MethodCallback, 0, 1, v8::None, V8DOMConfiguration::ExposedToAllScripts, V8DOMConfiguration::OnPrototype};
89 V8DOMConfiguration::installMethod(isolate, world, instanceTemplate, prot otypeTemplate, interfaceTemplate, signature, voidMethodPartial1MethodConfigurati on);
90 }
91 }
92
93 void V8TestInterface2Partial::preparePrototypeAndInterfaceObject(v8::Local<v8::C ontext> context, const DOMWrapperWorld& world, v8::Local<v8::Object> prototypeOb ject, v8::Local<v8::Function> interfaceObject, v8::Local<v8::FunctionTemplate> i nterfaceTemplate)
94 {
95 V8TestInterface2::preparePrototypeAndInterfaceObject(context, world, prototy peObject, interfaceObject, interfaceTemplate);
96 }
97
98 void V8TestInterface2Partial::initialize()
99 {
100 // Should be invoked from ModulesInitializer.
101 V8TestInterface2::updateWrapperTypeInfo(
102 &V8TestInterface2Partial::installV8TestInterface2Template,
103 &V8TestInterface2Partial::preparePrototypeAndInterfaceObject);
104 }
105
106 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698