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

Side by Side Diff: Source/bindings/tests/results/V8TestNode.cpp

Issue 214283002: Bindings: rename |jsValue| => |v8Value| (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Reupload Created 6 years, 9 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 | Annotate | Revision Log
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 "V8TestNode.h" 8 #include "V8TestNode.h"
9 9
10 #include "RuntimeEnabledFeatures.h" 10 #include "RuntimeEnabledFeatures.h"
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
50 v8SetReturnValueString(info, impl->href(), info.GetIsolate()); 50 v8SetReturnValueString(info, impl->href(), info.GetIsolate());
51 } 51 }
52 52
53 static void hrefAttributeGetterCallback(v8::Local<v8::String>, const v8::Propert yCallbackInfo<v8::Value>& info) 53 static void hrefAttributeGetterCallback(v8::Local<v8::String>, const v8::Propert yCallbackInfo<v8::Value>& info)
54 { 54 {
55 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); 55 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter");
56 TestNodeV8Internal::hrefAttributeGetter(info); 56 TestNodeV8Internal::hrefAttributeGetter(info);
57 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); 57 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution");
58 } 58 }
59 59
60 static void hrefAttributeSetter(v8::Local<v8::Value> jsValue, const v8::Property CallbackInfo<void>& info) 60 static void hrefAttributeSetter(v8::Local<v8::Value> v8Value, const v8::Property CallbackInfo<void>& info)
61 { 61 {
62 v8::Handle<v8::Object> holder = info.Holder(); 62 v8::Handle<v8::Object> holder = info.Holder();
63 TestNode* impl = V8TestNode::toNative(holder); 63 TestNode* impl = V8TestNode::toNative(holder);
64 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, cppValue, jsValue); 64 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, cppValue, v8Value);
65 impl->setHref(cppValue); 65 impl->setHref(cppValue);
66 } 66 }
67 67
68 static void hrefAttributeSetterCallback(v8::Local<v8::String>, v8::Local<v8::Val ue> jsValue, const v8::PropertyCallbackInfo<void>& info) 68 static void hrefAttributeSetterCallback(v8::Local<v8::String>, v8::Local<v8::Val ue> v8Value, const v8::PropertyCallbackInfo<void>& info)
69 { 69 {
70 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); 70 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter");
71 TestNodeV8Internal::hrefAttributeSetter(jsValue, info); 71 TestNodeV8Internal::hrefAttributeSetter(v8Value, info);
72 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); 72 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution");
73 } 73 }
74 74
75 static void hrefThrowsAttributeGetter(const v8::PropertyCallbackInfo<v8::Value>& info) 75 static void hrefThrowsAttributeGetter(const v8::PropertyCallbackInfo<v8::Value>& info)
76 { 76 {
77 v8::Handle<v8::Object> holder = info.Holder(); 77 v8::Handle<v8::Object> holder = info.Holder();
78 TestNode* impl = V8TestNode::toNative(holder); 78 TestNode* impl = V8TestNode::toNative(holder);
79 v8SetReturnValueString(info, impl->hrefThrows(), info.GetIsolate()); 79 v8SetReturnValueString(info, impl->hrefThrows(), info.GetIsolate());
80 } 80 }
81 81
82 static void hrefThrowsAttributeGetterCallback(v8::Local<v8::String>, const v8::P ropertyCallbackInfo<v8::Value>& info) 82 static void hrefThrowsAttributeGetterCallback(v8::Local<v8::String>, const v8::P ropertyCallbackInfo<v8::Value>& info)
83 { 83 {
84 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); 84 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter");
85 TestNodeV8Internal::hrefThrowsAttributeGetter(info); 85 TestNodeV8Internal::hrefThrowsAttributeGetter(info);
86 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); 86 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution");
87 } 87 }
88 88
89 static void hrefThrowsAttributeSetter(v8::Local<v8::Value> jsValue, const v8::Pr opertyCallbackInfo<void>& info) 89 static void hrefThrowsAttributeSetter(v8::Local<v8::Value> v8Value, const v8::Pr opertyCallbackInfo<void>& info)
90 { 90 {
91 v8::Handle<v8::Object> holder = info.Holder(); 91 v8::Handle<v8::Object> holder = info.Holder();
92 ExceptionState exceptionState(ExceptionState::SetterContext, "hrefThrows", " TestNode", holder, info.GetIsolate()); 92 ExceptionState exceptionState(ExceptionState::SetterContext, "hrefThrows", " TestNode", holder, info.GetIsolate());
93 TestNode* impl = V8TestNode::toNative(holder); 93 TestNode* impl = V8TestNode::toNative(holder);
94 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, cppValue, jsValue); 94 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, cppValue, v8Value);
95 impl->setHrefThrows(cppValue, exceptionState); 95 impl->setHrefThrows(cppValue, exceptionState);
96 exceptionState.throwIfNeeded(); 96 exceptionState.throwIfNeeded();
97 } 97 }
98 98
99 static void hrefThrowsAttributeSetterCallback(v8::Local<v8::String>, v8::Local<v 8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) 99 static void hrefThrowsAttributeSetterCallback(v8::Local<v8::String>, v8::Local<v 8::Value> v8Value, const v8::PropertyCallbackInfo<void>& info)
100 { 100 {
101 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); 101 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter");
102 TestNodeV8Internal::hrefThrowsAttributeSetter(jsValue, info); 102 TestNodeV8Internal::hrefThrowsAttributeSetter(v8Value, info);
103 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); 103 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution");
104 } 104 }
105 105
106 static void hrefCallWithAttributeGetter(const v8::PropertyCallbackInfo<v8::Value >& info) 106 static void hrefCallWithAttributeGetter(const v8::PropertyCallbackInfo<v8::Value >& info)
107 { 107 {
108 v8::Handle<v8::Object> holder = info.Holder(); 108 v8::Handle<v8::Object> holder = info.Holder();
109 TestNode* impl = V8TestNode::toNative(holder); 109 TestNode* impl = V8TestNode::toNative(holder);
110 v8SetReturnValueString(info, impl->hrefCallWith(), info.GetIsolate()); 110 v8SetReturnValueString(info, impl->hrefCallWith(), info.GetIsolate());
111 } 111 }
112 112
113 static void hrefCallWithAttributeGetterCallback(v8::Local<v8::String>, const v8: :PropertyCallbackInfo<v8::Value>& info) 113 static void hrefCallWithAttributeGetterCallback(v8::Local<v8::String>, const v8: :PropertyCallbackInfo<v8::Value>& info)
114 { 114 {
115 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); 115 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter");
116 TestNodeV8Internal::hrefCallWithAttributeGetter(info); 116 TestNodeV8Internal::hrefCallWithAttributeGetter(info);
117 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); 117 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution");
118 } 118 }
119 119
120 static void hrefCallWithAttributeSetter(v8::Local<v8::Value> jsValue, const v8:: PropertyCallbackInfo<void>& info) 120 static void hrefCallWithAttributeSetter(v8::Local<v8::Value> v8Value, const v8:: PropertyCallbackInfo<void>& info)
121 { 121 {
122 v8::Handle<v8::Object> holder = info.Holder(); 122 v8::Handle<v8::Object> holder = info.Holder();
123 TestNode* impl = V8TestNode::toNative(holder); 123 TestNode* impl = V8TestNode::toNative(holder);
124 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, cppValue, jsValue); 124 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, cppValue, v8Value);
125 impl->setHrefCallWith(callingDOMWindow(info.GetIsolate()), enteredDOMWindow( info.GetIsolate()), cppValue); 125 impl->setHrefCallWith(callingDOMWindow(info.GetIsolate()), enteredDOMWindow( info.GetIsolate()), cppValue);
126 } 126 }
127 127
128 static void hrefCallWithAttributeSetterCallback(v8::Local<v8::String>, v8::Local <v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) 128 static void hrefCallWithAttributeSetterCallback(v8::Local<v8::String>, v8::Local <v8::Value> v8Value, const v8::PropertyCallbackInfo<void>& info)
129 { 129 {
130 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); 130 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter");
131 TestNodeV8Internal::hrefCallWithAttributeSetter(jsValue, info); 131 TestNodeV8Internal::hrefCallWithAttributeSetter(v8Value, info);
132 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); 132 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution");
133 } 133 }
134 134
135 static void constructor(const v8::FunctionCallbackInfo<v8::Value>& info) 135 static void constructor(const v8::FunctionCallbackInfo<v8::Value>& info)
136 { 136 {
137 v8::Isolate* isolate = info.GetIsolate(); 137 v8::Isolate* isolate = info.GetIsolate();
138 RefPtr<TestNode> impl = TestNode::create(); 138 RefPtr<TestNode> impl = TestNode::create();
139 139
140 v8::Handle<v8::Object> wrapper = info.Holder(); 140 v8::Handle<v8::Object> wrapper = info.Holder();
141 V8DOMWrapper::associateObjectWithWrapper<V8TestNode>(impl.release(), &V8Test Node::wrapperTypeInfo, wrapper, isolate, WrapperConfiguration::Dependent); 141 V8DOMWrapper::associateObjectWithWrapper<V8TestNode>(impl.release(), &V8Test Node::wrapperTypeInfo, wrapper, isolate, WrapperConfiguration::Dependent);
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after
192 if (!result.IsEmpty()) 192 if (!result.IsEmpty())
193 return result; 193 return result;
194 194
195 TRACE_EVENT_SCOPED_SAMPLING_STATE("Blink", "BuildDOMTemplate"); 195 TRACE_EVENT_SCOPED_SAMPLING_STATE("Blink", "BuildDOMTemplate");
196 result = v8::FunctionTemplate::New(isolate, V8ObjectConstructor::isValidCons tructorMode); 196 result = v8::FunctionTemplate::New(isolate, V8ObjectConstructor::isValidCons tructorMode);
197 configureV8TestNodeTemplate(result, isolate); 197 configureV8TestNodeTemplate(result, isolate);
198 data->setDOMTemplate(const_cast<WrapperTypeInfo*>(&wrapperTypeInfo), result) ; 198 data->setDOMTemplate(const_cast<WrapperTypeInfo*>(&wrapperTypeInfo), result) ;
199 return result; 199 return result;
200 } 200 }
201 201
202 bool V8TestNode::hasInstance(v8::Handle<v8::Value> jsValue, v8::Isolate* isolate ) 202 bool V8TestNode::hasInstance(v8::Handle<v8::Value> v8Value, v8::Isolate* isolate )
203 { 203 {
204 return V8PerIsolateData::from(isolate)->hasInstance(&wrapperTypeInfo, jsValu e); 204 return V8PerIsolateData::from(isolate)->hasInstance(&wrapperTypeInfo, v8Valu e);
205 } 205 }
206 206
207 v8::Handle<v8::Object> V8TestNode::findInstanceInPrototypeChain(v8::Handle<v8::V alue> jsValue, v8::Isolate* isolate) 207 v8::Handle<v8::Object> V8TestNode::findInstanceInPrototypeChain(v8::Handle<v8::V alue> v8Value, v8::Isolate* isolate)
208 { 208 {
209 return V8PerIsolateData::from(isolate)->findInstanceInPrototypeChain(&wrappe rTypeInfo, jsValue); 209 return V8PerIsolateData::from(isolate)->findInstanceInPrototypeChain(&wrappe rTypeInfo, v8Value);
210 } 210 }
211 211
212 TestNode* V8TestNode::toNativeWithTypeCheck(v8::Isolate* isolate, v8::Handle<v8: :Value> value) 212 TestNode* V8TestNode::toNativeWithTypeCheck(v8::Isolate* isolate, v8::Handle<v8: :Value> value)
213 { 213 {
214 return hasInstance(value, isolate) ? fromInternalPointer(v8::Handle<v8::Obje ct>::Cast(value)->GetAlignedPointerFromInternalField(v8DOMWrapperObjectIndex)) : 0; 214 return hasInstance(value, isolate) ? fromInternalPointer(v8::Handle<v8::Obje ct>::Cast(value)->GetAlignedPointerFromInternalField(v8DOMWrapperObjectIndex)) : 0;
215 } 215 }
216 216
217 EventTarget* V8TestNode::toEventTarget(v8::Handle<v8::Object> object) 217 EventTarget* V8TestNode::toEventTarget(v8::Handle<v8::Object> object)
218 { 218 {
219 return toNative(object); 219 return toNative(object);
(...skipping 24 matching lines...) Expand all
244 fromInternalPointer(object)->deref(); 244 fromInternalPointer(object)->deref();
245 } 245 }
246 246
247 template<> 247 template<>
248 v8::Handle<v8::Value> toV8NoInline(TestNode* impl, v8::Handle<v8::Object> creati onContext, v8::Isolate* isolate) 248 v8::Handle<v8::Value> toV8NoInline(TestNode* impl, v8::Handle<v8::Object> creati onContext, v8::Isolate* isolate)
249 { 249 {
250 return toV8(impl, creationContext, isolate); 250 return toV8(impl, creationContext, isolate);
251 } 251 }
252 252
253 } // namespace WebCore 253 } // namespace WebCore
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698