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 "V8TestInterface3.h" | 8 #include "V8TestInterface3.h" |
9 | 9 |
10 #include "bindings/core/v8/ExceptionState.h" | 10 #include "bindings/core/v8/ExceptionState.h" |
(...skipping 152 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
163 | 163 |
164 static void namedPropertyEnumeratorCallback(const v8::PropertyCallbackInfo<v8::A
rray>& info) | 164 static void namedPropertyEnumeratorCallback(const v8::PropertyCallbackInfo<v8::A
rray>& info) |
165 { | 165 { |
166 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMNamedProperty"); | 166 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMNamedProperty"); |
167 V8TestInterface3::namedPropertyEnumeratorCustom(info); | 167 V8TestInterface3::namedPropertyEnumeratorCustom(info); |
168 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); | 168 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); |
169 } | 169 } |
170 | 170 |
171 } // namespace TestInterface3V8Internal | 171 } // namespace TestInterface3V8Internal |
172 | 172 |
173 static const V8DOMConfiguration::MethodConfiguration V8TestInterface3Methods[] =
{ | |
174 {"keys", TestInterface3V8Internal::keysMethodCallback, 0, 0, V8DOMConfigurat
ion::ExposedToAllScripts}, | |
175 {"values", TestInterface3V8Internal::valuesMethodCallback, 0, 0, V8DOMConfig
uration::ExposedToAllScripts}, | |
176 {"entries", TestInterface3V8Internal::entriesMethodCallback, 0, 0, V8DOMConf
iguration::ExposedToAllScripts}, | |
177 }; | |
178 | |
179 static void installV8TestInterface3Template(v8::Local<v8::FunctionTemplate> func
tionTemplate, v8::Isolate* isolate) | 173 static void installV8TestInterface3Template(v8::Local<v8::FunctionTemplate> func
tionTemplate, v8::Isolate* isolate) |
180 { | 174 { |
181 functionTemplate->ReadOnlyPrototype(); | 175 functionTemplate->ReadOnlyPrototype(); |
182 | 176 |
183 v8::Local<v8::Signature> defaultSignature; | 177 v8::Local<v8::Signature> defaultSignature; |
184 defaultSignature = V8DOMConfiguration::installDOMClassTemplate(isolate, func
tionTemplate, "TestInterface3", v8::Local<v8::FunctionTemplate>(), V8TestInterfa
ce3::internalFieldCount, | 178 defaultSignature = V8DOMConfiguration::installDOMClassTemplate(isolate, func
tionTemplate, "TestInterface3", v8::Local<v8::FunctionTemplate>(), V8TestInterfa
ce3::internalFieldCount, |
185 0, 0, | 179 0, 0, |
186 0, 0, | 180 0, 0, |
187 V8TestInterface3Methods, WTF_ARRAY_LENGTH(V8TestInterface3Methods)); | 181 0, 0); |
188 v8::Local<v8::ObjectTemplate> instanceTemplate = functionTemplate->InstanceT
emplate(); | 182 v8::Local<v8::ObjectTemplate> instanceTemplate = functionTemplate->InstanceT
emplate(); |
189 ALLOW_UNUSED_LOCAL(instanceTemplate); | 183 ALLOW_UNUSED_LOCAL(instanceTemplate); |
190 v8::Local<v8::ObjectTemplate> prototypeTemplate = functionTemplate->Prototyp
eTemplate(); | 184 v8::Local<v8::ObjectTemplate> prototypeTemplate = functionTemplate->Prototyp
eTemplate(); |
191 ALLOW_UNUSED_LOCAL(prototypeTemplate); | 185 ALLOW_UNUSED_LOCAL(prototypeTemplate); |
192 functionTemplate->InstanceTemplate()->SetHandler(v8::IndexedPropertyHandlerC
onfiguration(TestInterface3V8Internal::indexedPropertyGetterCallback, TestInterf
ace3V8Internal::indexedPropertySetterCallback, 0, TestInterface3V8Internal::inde
xedPropertyDeleterCallback, indexedPropertyEnumerator<TestInterface3>)); | 186 functionTemplate->InstanceTemplate()->SetHandler(v8::IndexedPropertyHandlerC
onfiguration(TestInterface3V8Internal::indexedPropertyGetterCallback, TestInterf
ace3V8Internal::indexedPropertySetterCallback, 0, TestInterface3V8Internal::inde
xedPropertyDeleterCallback, indexedPropertyEnumerator<TestInterface3>)); |
193 functionTemplate->InstanceTemplate()->SetHandler(v8::NamedPropertyHandlerCon
figuration(TestInterface3V8Internal::namedPropertyGetterCallback, TestInterface3
V8Internal::namedPropertySetterCallback, TestInterface3V8Internal::namedProperty
QueryCallback, TestInterface3V8Internal::namedPropertyDeleterCallback, TestInter
face3V8Internal::namedPropertyEnumeratorCallback)); | 187 functionTemplate->InstanceTemplate()->SetHandler(v8::NamedPropertyHandlerCon
figuration(TestInterface3V8Internal::namedPropertyGetterCallback, TestInterface3
V8Internal::namedPropertySetterCallback, TestInterface3V8Internal::namedProperty
QueryCallback, TestInterface3V8Internal::namedPropertyDeleterCallback, TestInter
face3V8Internal::namedPropertyEnumeratorCallback)); |
194 static const V8DOMConfiguration::SymbolKeyedMethodConfiguration symbolKeyedI
teratorConfiguration = { v8::Symbol::GetIterator, TestInterface3V8Internal::iter
atorMethodCallback, 0, V8DOMConfiguration::ExposedToAllScripts }; | 188 if (RuntimeEnabledFeatures::featureNameEnabled()) { |
195 V8DOMConfiguration::installMethod(prototypeTemplate, defaultSignature, v8::D
ontDelete, symbolKeyedIteratorConfiguration, isolate); | 189 static const V8DOMConfiguration::SymbolKeyedMethodConfiguration symbolKe
yedIteratorConfiguration = { v8::Symbol::GetIterator, TestInterface3V8Internal::
iteratorMethodCallback, 0, V8DOMConfiguration::ExposedToAllScripts }; |
| 190 V8DOMConfiguration::installMethod(prototypeTemplate, defaultSignature, v
8::DontDelete, symbolKeyedIteratorConfiguration, isolate); |
| 191 } |
| 192 if (RuntimeEnabledFeatures::featureNameEnabled()) { |
| 193 const V8DOMConfiguration::MethodConfiguration keysMethodConfiguration =
{ |
| 194 "keys", TestInterface3V8Internal::keysMethodCallback, 0, 0, V8DOMCon
figuration::ExposedToAllScripts, |
| 195 }; |
| 196 V8DOMConfiguration::installMethod(prototypeTemplate, defaultSignature, v
8::None, keysMethodConfiguration, isolate); |
| 197 } |
| 198 if (RuntimeEnabledFeatures::featureNameEnabled()) { |
| 199 const V8DOMConfiguration::MethodConfiguration valuesMethodConfiguration
= { |
| 200 "values", TestInterface3V8Internal::valuesMethodCallback, 0, 0, V8DO
MConfiguration::ExposedToAllScripts, |
| 201 }; |
| 202 V8DOMConfiguration::installMethod(prototypeTemplate, defaultSignature, v
8::None, valuesMethodConfiguration, isolate); |
| 203 } |
| 204 if (RuntimeEnabledFeatures::featureNameEnabled()) { |
| 205 const V8DOMConfiguration::MethodConfiguration entriesMethodConfiguration
= { |
| 206 "entries", TestInterface3V8Internal::entriesMethodCallback, 0, 0, V8
DOMConfiguration::ExposedToAllScripts, |
| 207 }; |
| 208 V8DOMConfiguration::installMethod(prototypeTemplate, defaultSignature, v
8::None, entriesMethodConfiguration, isolate); |
| 209 } |
196 | 210 |
197 // Custom toString template | 211 // Custom toString template |
198 functionTemplate->Set(v8AtomicString(isolate, "toString"), V8PerIsolateData:
:from(isolate)->toStringTemplate()); | 212 functionTemplate->Set(v8AtomicString(isolate, "toString"), V8PerIsolateData:
:from(isolate)->toStringTemplate()); |
199 } | 213 } |
200 | 214 |
201 v8::Local<v8::FunctionTemplate> V8TestInterface3::domTemplate(v8::Isolate* isola
te) | 215 v8::Local<v8::FunctionTemplate> V8TestInterface3::domTemplate(v8::Isolate* isola
te) |
202 { | 216 { |
203 return V8DOMConfiguration::domClassTemplate(isolate, const_cast<WrapperTypeI
nfo*>(&wrapperTypeInfo), installV8TestInterface3Template); | 217 return V8DOMConfiguration::domClassTemplate(isolate, const_cast<WrapperTypeI
nfo*>(&wrapperTypeInfo), installV8TestInterface3Template); |
204 } | 218 } |
205 | 219 |
(...skipping 16 matching lines...) Expand all Loading... |
222 { | 236 { |
223 scriptWrappable->toImpl<TestInterface3>()->ref(); | 237 scriptWrappable->toImpl<TestInterface3>()->ref(); |
224 } | 238 } |
225 | 239 |
226 void V8TestInterface3::derefObject(ScriptWrappable* scriptWrappable) | 240 void V8TestInterface3::derefObject(ScriptWrappable* scriptWrappable) |
227 { | 241 { |
228 scriptWrappable->toImpl<TestInterface3>()->deref(); | 242 scriptWrappable->toImpl<TestInterface3>()->deref(); |
229 } | 243 } |
230 | 244 |
231 } // namespace blink | 245 } // namespace blink |
OLD | NEW |