| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2013 Google Inc. All rights reserved. | 2 * Copyright (C) 2013 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 105 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 116 static void readonlyStringAttributeAttributeGetter(const v8::PropertyCallbackInf
o<v8::Value>& info) | 116 static void readonlyStringAttributeAttributeGetter(const v8::PropertyCallbackInf
o<v8::Value>& info) |
| 117 { | 117 { |
| 118 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 118 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 119 v8SetReturnValueString(info, imp->readonlyStringAttribute(), info.GetIsolate
()); | 119 v8SetReturnValueString(info, imp->readonlyStringAttribute(), info.GetIsolate
()); |
| 120 } | 120 } |
| 121 | 121 |
| 122 static void readonlyStringAttributeAttributeGetterCallback(v8::Local<v8::String>
, const v8::PropertyCallbackInfo<v8::Value>& info) | 122 static void readonlyStringAttributeAttributeGetterCallback(v8::Local<v8::String>
, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 123 { | 123 { |
| 124 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 124 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 125 TestObjectPythonV8Internal::readonlyStringAttributeAttributeGetter(info); | 125 TestObjectPythonV8Internal::readonlyStringAttributeAttributeGetter(info); |
| 126 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 126 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 127 } | 127 } |
| 128 | 128 |
| 129 static void readonlyTestInterfaceEmptyAttributeAttributeGetter(const v8::Propert
yCallbackInfo<v8::Value>& info) | 129 static void readonlyTestInterfaceEmptyAttributeAttributeGetter(const v8::Propert
yCallbackInfo<v8::Value>& info) |
| 130 { | 130 { |
| 131 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 131 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 132 RefPtr<TestInterfaceEmpty> result = imp->readonlyTestInterfaceEmptyAttribute
(); | 132 RefPtr<TestInterfaceEmpty> result = imp->readonlyTestInterfaceEmptyAttribute
(); |
| 133 if (result && DOMDataStore::setReturnValueFromWrapper<V8TestInterfaceEmpty>(
info.GetReturnValue(), result.get())) | 133 if (result && DOMDataStore::setReturnValueFromWrapper<V8TestInterfaceEmpty>(
info.GetReturnValue(), result.get())) |
| 134 return; | 134 return; |
| 135 v8::Handle<v8::Value> wrapper = toV8(result.get(), info.Holder(), info.GetIs
olate()); | 135 v8::Handle<v8::Value> wrapper = toV8(result.get(), info.Holder(), info.GetIs
olate()); |
| 136 if (!wrapper.IsEmpty()) { | 136 if (!wrapper.IsEmpty()) { |
| 137 V8HiddenPropertyName::setNamedHiddenReference(info.Holder(), "readonlyTe
stInterfaceEmptyAttribute", wrapper); | 137 V8HiddenPropertyName::setNamedHiddenReference(info.Holder(), "readonlyTe
stInterfaceEmptyAttribute", wrapper); |
| 138 v8SetReturnValue(info, wrapper); | 138 v8SetReturnValue(info, wrapper); |
| 139 } | 139 } |
| 140 } | 140 } |
| 141 | 141 |
| 142 static void readonlyTestInterfaceEmptyAttributeAttributeGetterCallback(v8::Local
<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) | 142 static void readonlyTestInterfaceEmptyAttributeAttributeGetterCallback(v8::Local
<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 143 { | 143 { |
| 144 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 144 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 145 TestObjectPythonV8Internal::readonlyTestInterfaceEmptyAttributeAttributeGett
er(info); | 145 TestObjectPythonV8Internal::readonlyTestInterfaceEmptyAttributeAttributeGett
er(info); |
| 146 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 146 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 147 } | 147 } |
| 148 | 148 |
| 149 static void readonlyLongAttributeAttributeGetter(const v8::PropertyCallbackInfo<
v8::Value>& info) | 149 static void readonlyLongAttributeAttributeGetter(const v8::PropertyCallbackInfo<
v8::Value>& info) |
| 150 { | 150 { |
| 151 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 151 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 152 v8SetReturnValueInt(info, imp->readonlyLongAttribute()); | 152 v8SetReturnValueInt(info, imp->readonlyLongAttribute()); |
| 153 } | 153 } |
| 154 | 154 |
| 155 static void readonlyLongAttributeAttributeGetterCallback(v8::Local<v8::String>,
const v8::PropertyCallbackInfo<v8::Value>& info) | 155 static void readonlyLongAttributeAttributeGetterCallback(v8::Local<v8::String>,
const v8::PropertyCallbackInfo<v8::Value>& info) |
| 156 { | 156 { |
| 157 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 157 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 158 TestObjectPythonV8Internal::readonlyLongAttributeAttributeGetter(info); | 158 TestObjectPythonV8Internal::readonlyLongAttributeAttributeGetter(info); |
| 159 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 159 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 160 } | 160 } |
| 161 | 161 |
| 162 static void dateAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::Valu
e>& info) | 162 static void dateAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::Valu
e>& info) |
| 163 { | 163 { |
| 164 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 164 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 165 v8SetReturnValue(info, v8DateOrNull(imp->dateAttribute(), info.GetIsolate())
); | 165 v8SetReturnValue(info, v8DateOrNull(imp->dateAttribute(), info.GetIsolate())
); |
| 166 } | 166 } |
| 167 | 167 |
| 168 static void dateAttributeAttributeGetterCallback(v8::Local<v8::String>, const v8
::PropertyCallbackInfo<v8::Value>& info) | 168 static void dateAttributeAttributeGetterCallback(v8::Local<v8::String>, const v8
::PropertyCallbackInfo<v8::Value>& info) |
| 169 { | 169 { |
| 170 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 170 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 171 TestObjectPythonV8Internal::dateAttributeAttributeGetter(info); | 171 TestObjectPythonV8Internal::dateAttributeAttributeGetter(info); |
| 172 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 172 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 173 } | 173 } |
| 174 | 174 |
| 175 static void dateAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const v8:
:PropertyCallbackInfo<void>& info) | 175 static void dateAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const v8:
:PropertyCallbackInfo<void>& info) |
| 176 { | 176 { |
| 177 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 177 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 178 V8TRYCATCH_VOID(double, cppValue, toWebCoreDate(jsValue)); | 178 V8TRYCATCH_VOID(double, cppValue, toWebCoreDate(jsValue)); |
| 179 imp->setDateAttribute(cppValue); | 179 imp->setDateAttribute(cppValue); |
| 180 } | 180 } |
| 181 | 181 |
| 182 static void dateAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::Loca
l<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 182 static void dateAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::Loca
l<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 183 { | 183 { |
| 184 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 184 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 185 TestObjectPythonV8Internal::dateAttributeAttributeSetter(jsValue, info); | 185 TestObjectPythonV8Internal::dateAttributeAttributeSetter(jsValue, info); |
| 186 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 186 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 187 } | 187 } |
| 188 | 188 |
| 189 static void stringAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::Va
lue>& info) | 189 static void stringAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::Va
lue>& info) |
| 190 { | 190 { |
| 191 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 191 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 192 v8SetReturnValueString(info, imp->stringAttribute(), info.GetIsolate()); | 192 v8SetReturnValueString(info, imp->stringAttribute(), info.GetIsolate()); |
| 193 } | 193 } |
| 194 | 194 |
| 195 static void stringAttributeAttributeGetterCallback(v8::Local<v8::String>, const
v8::PropertyCallbackInfo<v8::Value>& info) | 195 static void stringAttributeAttributeGetterCallback(v8::Local<v8::String>, const
v8::PropertyCallbackInfo<v8::Value>& info) |
| 196 { | 196 { |
| 197 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 197 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 198 TestObjectPythonV8Internal::stringAttributeAttributeGetter(info); | 198 TestObjectPythonV8Internal::stringAttributeAttributeGetter(info); |
| 199 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 199 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 200 } | 200 } |
| 201 | 201 |
| 202 static void stringAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const v
8::PropertyCallbackInfo<void>& info) | 202 static void stringAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const v
8::PropertyCallbackInfo<void>& info) |
| 203 { | 203 { |
| 204 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 204 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 205 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, cppValue, jsValue); | 205 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, cppValue, jsValue); |
| 206 imp->setStringAttribute(cppValue); | 206 imp->setStringAttribute(cppValue); |
| 207 } | 207 } |
| 208 | 208 |
| 209 static void stringAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::Lo
cal<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 209 static void stringAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::Lo
cal<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 210 { | 210 { |
| 211 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 211 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 212 TestObjectPythonV8Internal::stringAttributeAttributeSetter(jsValue, info); | 212 TestObjectPythonV8Internal::stringAttributeAttributeSetter(jsValue, info); |
| 213 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 213 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 214 } | 214 } |
| 215 | 215 |
| 216 static void readonlyDOMTimeStampAttributeAttributeGetter(const v8::PropertyCallb
ackInfo<v8::Value>& info) | 216 static void readonlyDOMTimeStampAttributeAttributeGetter(const v8::PropertyCallb
ackInfo<v8::Value>& info) |
| 217 { | 217 { |
| 218 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 218 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 219 v8SetReturnValue(info, static_cast<double>(imp->readonlyDOMTimeStampAttribut
e())); | 219 v8SetReturnValue(info, static_cast<double>(imp->readonlyDOMTimeStampAttribut
e())); |
| 220 } | 220 } |
| 221 | 221 |
| 222 static void readonlyDOMTimeStampAttributeAttributeGetterCallback(v8::Local<v8::S
tring>, const v8::PropertyCallbackInfo<v8::Value>& info) | 222 static void readonlyDOMTimeStampAttributeAttributeGetterCallback(v8::Local<v8::S
tring>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 223 { | 223 { |
| 224 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 224 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 225 TestObjectPythonV8Internal::readonlyDOMTimeStampAttributeAttributeGetter(inf
o); | 225 TestObjectPythonV8Internal::readonlyDOMTimeStampAttributeAttributeGetter(inf
o); |
| 226 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 226 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 227 } | 227 } |
| 228 | 228 |
| 229 static void booleanAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::V
alue>& info) | 229 static void booleanAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::V
alue>& info) |
| 230 { | 230 { |
| 231 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 231 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 232 v8SetReturnValueBool(info, imp->booleanAttribute()); | 232 v8SetReturnValueBool(info, imp->booleanAttribute()); |
| 233 } | 233 } |
| 234 | 234 |
| 235 static void booleanAttributeAttributeGetterCallback(v8::Local<v8::String>, const
v8::PropertyCallbackInfo<v8::Value>& info) | 235 static void booleanAttributeAttributeGetterCallback(v8::Local<v8::String>, const
v8::PropertyCallbackInfo<v8::Value>& info) |
| 236 { | 236 { |
| 237 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 237 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 238 TestObjectPythonV8Internal::booleanAttributeAttributeGetter(info); | 238 TestObjectPythonV8Internal::booleanAttributeAttributeGetter(info); |
| 239 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 239 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 240 } | 240 } |
| 241 | 241 |
| 242 static void booleanAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const
v8::PropertyCallbackInfo<void>& info) | 242 static void booleanAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const
v8::PropertyCallbackInfo<void>& info) |
| 243 { | 243 { |
| 244 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 244 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 245 V8TRYCATCH_VOID(bool, cppValue, jsValue->BooleanValue()); | 245 V8TRYCATCH_VOID(bool, cppValue, jsValue->BooleanValue()); |
| 246 imp->setBooleanAttribute(cppValue); | 246 imp->setBooleanAttribute(cppValue); |
| 247 } | 247 } |
| 248 | 248 |
| 249 static void booleanAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::L
ocal<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 249 static void booleanAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::L
ocal<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 250 { | 250 { |
| 251 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 251 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 252 TestObjectPythonV8Internal::booleanAttributeAttributeSetter(jsValue, info); | 252 TestObjectPythonV8Internal::booleanAttributeAttributeSetter(jsValue, info); |
| 253 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 253 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 254 } | 254 } |
| 255 | 255 |
| 256 static void byteAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::Valu
e>& info) | 256 static void byteAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::Valu
e>& info) |
| 257 { | 257 { |
| 258 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 258 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 259 v8SetReturnValueInt(info, imp->byteAttribute()); | 259 v8SetReturnValueInt(info, imp->byteAttribute()); |
| 260 } | 260 } |
| 261 | 261 |
| 262 static void byteAttributeAttributeGetterCallback(v8::Local<v8::String>, const v8
::PropertyCallbackInfo<v8::Value>& info) | 262 static void byteAttributeAttributeGetterCallback(v8::Local<v8::String>, const v8
::PropertyCallbackInfo<v8::Value>& info) |
| 263 { | 263 { |
| 264 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 264 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 265 TestObjectPythonV8Internal::byteAttributeAttributeGetter(info); | 265 TestObjectPythonV8Internal::byteAttributeAttributeGetter(info); |
| 266 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 266 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 267 } | 267 } |
| 268 | 268 |
| 269 static void byteAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const v8:
:PropertyCallbackInfo<void>& info) | 269 static void byteAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const v8:
:PropertyCallbackInfo<void>& info) |
| 270 { | 270 { |
| 271 ExceptionState exceptionState(ExceptionState::SetterContext, "byteAttribute"
, "TestObjectPython", info.Holder(), info.GetIsolate()); | 271 ExceptionState exceptionState(ExceptionState::SetterContext, "byteAttribute"
, "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 272 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 272 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 273 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt8(jsValue, exceptionState), ex
ceptionState); | 273 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt8(jsValue, exceptionState), ex
ceptionState); |
| 274 imp->setByteAttribute(cppValue); | 274 imp->setByteAttribute(cppValue); |
| 275 } | 275 } |
| 276 | 276 |
| 277 static void byteAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::Loca
l<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 277 static void byteAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::Loca
l<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 278 { | 278 { |
| 279 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 279 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 280 TestObjectPythonV8Internal::byteAttributeAttributeSetter(jsValue, info); | 280 TestObjectPythonV8Internal::byteAttributeAttributeSetter(jsValue, info); |
| 281 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 281 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 282 } | 282 } |
| 283 | 283 |
| 284 static void doubleAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::Va
lue>& info) | 284 static void doubleAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::Va
lue>& info) |
| 285 { | 285 { |
| 286 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 286 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 287 v8SetReturnValue(info, imp->doubleAttribute()); | 287 v8SetReturnValue(info, imp->doubleAttribute()); |
| 288 } | 288 } |
| 289 | 289 |
| 290 static void doubleAttributeAttributeGetterCallback(v8::Local<v8::String>, const
v8::PropertyCallbackInfo<v8::Value>& info) | 290 static void doubleAttributeAttributeGetterCallback(v8::Local<v8::String>, const
v8::PropertyCallbackInfo<v8::Value>& info) |
| 291 { | 291 { |
| 292 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 292 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 293 TestObjectPythonV8Internal::doubleAttributeAttributeGetter(info); | 293 TestObjectPythonV8Internal::doubleAttributeAttributeGetter(info); |
| 294 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 294 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 295 } | 295 } |
| 296 | 296 |
| 297 static void doubleAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const v
8::PropertyCallbackInfo<void>& info) | 297 static void doubleAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const v
8::PropertyCallbackInfo<void>& info) |
| 298 { | 298 { |
| 299 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 299 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 300 V8TRYCATCH_VOID(double, cppValue, static_cast<double>(jsValue->NumberValue()
)); | 300 V8TRYCATCH_VOID(double, cppValue, static_cast<double>(jsValue->NumberValue()
)); |
| 301 imp->setDoubleAttribute(cppValue); | 301 imp->setDoubleAttribute(cppValue); |
| 302 } | 302 } |
| 303 | 303 |
| 304 static void doubleAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::Lo
cal<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 304 static void doubleAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::Lo
cal<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 305 { | 305 { |
| 306 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 306 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 307 TestObjectPythonV8Internal::doubleAttributeAttributeSetter(jsValue, info); | 307 TestObjectPythonV8Internal::doubleAttributeAttributeSetter(jsValue, info); |
| 308 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 308 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 309 } | 309 } |
| 310 | 310 |
| 311 static void floatAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::Val
ue>& info) | 311 static void floatAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::Val
ue>& info) |
| 312 { | 312 { |
| 313 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 313 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 314 v8SetReturnValue(info, imp->floatAttribute()); | 314 v8SetReturnValue(info, imp->floatAttribute()); |
| 315 } | 315 } |
| 316 | 316 |
| 317 static void floatAttributeAttributeGetterCallback(v8::Local<v8::String>, const v
8::PropertyCallbackInfo<v8::Value>& info) | 317 static void floatAttributeAttributeGetterCallback(v8::Local<v8::String>, const v
8::PropertyCallbackInfo<v8::Value>& info) |
| 318 { | 318 { |
| 319 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 319 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 320 TestObjectPythonV8Internal::floatAttributeAttributeGetter(info); | 320 TestObjectPythonV8Internal::floatAttributeAttributeGetter(info); |
| 321 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 321 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 322 } | 322 } |
| 323 | 323 |
| 324 static void floatAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const v8
::PropertyCallbackInfo<void>& info) | 324 static void floatAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const v8
::PropertyCallbackInfo<void>& info) |
| 325 { | 325 { |
| 326 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 326 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 327 V8TRYCATCH_VOID(float, cppValue, static_cast<float>(jsValue->NumberValue()))
; | 327 V8TRYCATCH_VOID(float, cppValue, static_cast<float>(jsValue->NumberValue()))
; |
| 328 imp->setFloatAttribute(cppValue); | 328 imp->setFloatAttribute(cppValue); |
| 329 } | 329 } |
| 330 | 330 |
| 331 static void floatAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::Loc
al<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 331 static void floatAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::Loc
al<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 332 { | 332 { |
| 333 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 333 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 334 TestObjectPythonV8Internal::floatAttributeAttributeSetter(jsValue, info); | 334 TestObjectPythonV8Internal::floatAttributeAttributeSetter(jsValue, info); |
| 335 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 335 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 336 } | 336 } |
| 337 | 337 |
| 338 static void longAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::Valu
e>& info) | 338 static void longAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::Valu
e>& info) |
| 339 { | 339 { |
| 340 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 340 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 341 v8SetReturnValueInt(info, imp->longAttribute()); | 341 v8SetReturnValueInt(info, imp->longAttribute()); |
| 342 } | 342 } |
| 343 | 343 |
| 344 static void longAttributeAttributeGetterCallback(v8::Local<v8::String>, const v8
::PropertyCallbackInfo<v8::Value>& info) | 344 static void longAttributeAttributeGetterCallback(v8::Local<v8::String>, const v8
::PropertyCallbackInfo<v8::Value>& info) |
| 345 { | 345 { |
| 346 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 346 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 347 TestObjectPythonV8Internal::longAttributeAttributeGetter(info); | 347 TestObjectPythonV8Internal::longAttributeAttributeGetter(info); |
| 348 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 348 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 349 } | 349 } |
| 350 | 350 |
| 351 static void longAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const v8:
:PropertyCallbackInfo<void>& info) | 351 static void longAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const v8:
:PropertyCallbackInfo<void>& info) |
| 352 { | 352 { |
| 353 ExceptionState exceptionState(ExceptionState::SetterContext, "longAttribute"
, "TestObjectPython", info.Holder(), info.GetIsolate()); | 353 ExceptionState exceptionState(ExceptionState::SetterContext, "longAttribute"
, "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 354 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 354 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 355 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); | 355 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); |
| 356 imp->setLongAttribute(cppValue); | 356 imp->setLongAttribute(cppValue); |
| 357 } | 357 } |
| 358 | 358 |
| 359 static void longAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::Loca
l<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 359 static void longAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::Loca
l<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 360 { | 360 { |
| 361 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 361 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 362 TestObjectPythonV8Internal::longAttributeAttributeSetter(jsValue, info); | 362 TestObjectPythonV8Internal::longAttributeAttributeSetter(jsValue, info); |
| 363 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 363 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 364 } | 364 } |
| 365 | 365 |
| 366 static void longLongAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::
Value>& info) | 366 static void longLongAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::
Value>& info) |
| 367 { | 367 { |
| 368 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 368 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 369 v8SetReturnValue(info, static_cast<double>(imp->longLongAttribute())); | 369 v8SetReturnValue(info, static_cast<double>(imp->longLongAttribute())); |
| 370 } | 370 } |
| 371 | 371 |
| 372 static void longLongAttributeAttributeGetterCallback(v8::Local<v8::String>, cons
t v8::PropertyCallbackInfo<v8::Value>& info) | 372 static void longLongAttributeAttributeGetterCallback(v8::Local<v8::String>, cons
t v8::PropertyCallbackInfo<v8::Value>& info) |
| 373 { | 373 { |
| 374 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 374 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 375 TestObjectPythonV8Internal::longLongAttributeAttributeGetter(info); | 375 TestObjectPythonV8Internal::longLongAttributeAttributeGetter(info); |
| 376 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 376 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 377 } | 377 } |
| 378 | 378 |
| 379 static void longLongAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const
v8::PropertyCallbackInfo<void>& info) | 379 static void longLongAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const
v8::PropertyCallbackInfo<void>& info) |
| 380 { | 380 { |
| 381 ExceptionState exceptionState(ExceptionState::SetterContext, "longLongAttrib
ute", "TestObjectPython", info.Holder(), info.GetIsolate()); | 381 ExceptionState exceptionState(ExceptionState::SetterContext, "longLongAttrib
ute", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 382 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 382 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 383 V8TRYCATCH_EXCEPTION_VOID(long long, cppValue, toInt64(jsValue, exceptionSta
te), exceptionState); | 383 V8TRYCATCH_EXCEPTION_VOID(long long, cppValue, toInt64(jsValue, exceptionSta
te), exceptionState); |
| 384 imp->setLongLongAttribute(cppValue); | 384 imp->setLongLongAttribute(cppValue); |
| 385 } | 385 } |
| 386 | 386 |
| 387 static void longLongAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::
Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 387 static void longLongAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::
Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 388 { | 388 { |
| 389 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 389 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 390 TestObjectPythonV8Internal::longLongAttributeAttributeSetter(jsValue, info); | 390 TestObjectPythonV8Internal::longLongAttributeAttributeSetter(jsValue, info); |
| 391 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 391 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 392 } | 392 } |
| 393 | 393 |
| 394 static void octetAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::Val
ue>& info) | 394 static void octetAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::Val
ue>& info) |
| 395 { | 395 { |
| 396 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 396 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 397 v8SetReturnValueUnsigned(info, imp->octetAttribute()); | 397 v8SetReturnValueUnsigned(info, imp->octetAttribute()); |
| 398 } | 398 } |
| 399 | 399 |
| 400 static void octetAttributeAttributeGetterCallback(v8::Local<v8::String>, const v
8::PropertyCallbackInfo<v8::Value>& info) | 400 static void octetAttributeAttributeGetterCallback(v8::Local<v8::String>, const v
8::PropertyCallbackInfo<v8::Value>& info) |
| 401 { | 401 { |
| 402 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 402 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 403 TestObjectPythonV8Internal::octetAttributeAttributeGetter(info); | 403 TestObjectPythonV8Internal::octetAttributeAttributeGetter(info); |
| 404 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 404 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 405 } | 405 } |
| 406 | 406 |
| 407 static void octetAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const v8
::PropertyCallbackInfo<void>& info) | 407 static void octetAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const v8
::PropertyCallbackInfo<void>& info) |
| 408 { | 408 { |
| 409 ExceptionState exceptionState(ExceptionState::SetterContext, "octetAttribute
", "TestObjectPython", info.Holder(), info.GetIsolate()); | 409 ExceptionState exceptionState(ExceptionState::SetterContext, "octetAttribute
", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 410 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 410 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 411 V8TRYCATCH_EXCEPTION_VOID(unsigned, cppValue, toUInt8(jsValue, exceptionStat
e), exceptionState); | 411 V8TRYCATCH_EXCEPTION_VOID(unsigned, cppValue, toUInt8(jsValue, exceptionStat
e), exceptionState); |
| 412 imp->setOctetAttribute(cppValue); | 412 imp->setOctetAttribute(cppValue); |
| 413 } | 413 } |
| 414 | 414 |
| 415 static void octetAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::Loc
al<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 415 static void octetAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::Loc
al<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 416 { | 416 { |
| 417 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 417 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 418 TestObjectPythonV8Internal::octetAttributeAttributeSetter(jsValue, info); | 418 TestObjectPythonV8Internal::octetAttributeAttributeSetter(jsValue, info); |
| 419 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 419 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 420 } | 420 } |
| 421 | 421 |
| 422 static void shortAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::Val
ue>& info) | 422 static void shortAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::Val
ue>& info) |
| 423 { | 423 { |
| 424 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 424 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 425 v8SetReturnValueInt(info, imp->shortAttribute()); | 425 v8SetReturnValueInt(info, imp->shortAttribute()); |
| 426 } | 426 } |
| 427 | 427 |
| 428 static void shortAttributeAttributeGetterCallback(v8::Local<v8::String>, const v
8::PropertyCallbackInfo<v8::Value>& info) | 428 static void shortAttributeAttributeGetterCallback(v8::Local<v8::String>, const v
8::PropertyCallbackInfo<v8::Value>& info) |
| 429 { | 429 { |
| 430 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 430 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 431 TestObjectPythonV8Internal::shortAttributeAttributeGetter(info); | 431 TestObjectPythonV8Internal::shortAttributeAttributeGetter(info); |
| 432 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 432 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 433 } | 433 } |
| 434 | 434 |
| 435 static void shortAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const v8
::PropertyCallbackInfo<void>& info) | 435 static void shortAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const v8
::PropertyCallbackInfo<void>& info) |
| 436 { | 436 { |
| 437 ExceptionState exceptionState(ExceptionState::SetterContext, "shortAttribute
", "TestObjectPython", info.Holder(), info.GetIsolate()); | 437 ExceptionState exceptionState(ExceptionState::SetterContext, "shortAttribute
", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 438 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 438 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 439 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt16(jsValue, exceptionState), e
xceptionState); | 439 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt16(jsValue, exceptionState), e
xceptionState); |
| 440 imp->setShortAttribute(cppValue); | 440 imp->setShortAttribute(cppValue); |
| 441 } | 441 } |
| 442 | 442 |
| 443 static void shortAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::Loc
al<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 443 static void shortAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::Loc
al<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 444 { | 444 { |
| 445 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 445 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 446 TestObjectPythonV8Internal::shortAttributeAttributeSetter(jsValue, info); | 446 TestObjectPythonV8Internal::shortAttributeAttributeSetter(jsValue, info); |
| 447 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 447 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 448 } | 448 } |
| 449 | 449 |
| 450 static void unsignedLongAttributeAttributeGetter(const v8::PropertyCallbackInfo<
v8::Value>& info) | 450 static void unsignedLongAttributeAttributeGetter(const v8::PropertyCallbackInfo<
v8::Value>& info) |
| 451 { | 451 { |
| 452 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 452 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 453 v8SetReturnValueUnsigned(info, imp->unsignedLongAttribute()); | 453 v8SetReturnValueUnsigned(info, imp->unsignedLongAttribute()); |
| 454 } | 454 } |
| 455 | 455 |
| 456 static void unsignedLongAttributeAttributeGetterCallback(v8::Local<v8::String>,
const v8::PropertyCallbackInfo<v8::Value>& info) | 456 static void unsignedLongAttributeAttributeGetterCallback(v8::Local<v8::String>,
const v8::PropertyCallbackInfo<v8::Value>& info) |
| 457 { | 457 { |
| 458 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 458 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 459 TestObjectPythonV8Internal::unsignedLongAttributeAttributeGetter(info); | 459 TestObjectPythonV8Internal::unsignedLongAttributeAttributeGetter(info); |
| 460 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 460 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 461 } | 461 } |
| 462 | 462 |
| 463 static void unsignedLongAttributeAttributeSetter(v8::Local<v8::Value> jsValue, c
onst v8::PropertyCallbackInfo<void>& info) | 463 static void unsignedLongAttributeAttributeSetter(v8::Local<v8::Value> jsValue, c
onst v8::PropertyCallbackInfo<void>& info) |
| 464 { | 464 { |
| 465 ExceptionState exceptionState(ExceptionState::SetterContext, "unsignedLongAt
tribute", "TestObjectPython", info.Holder(), info.GetIsolate()); | 465 ExceptionState exceptionState(ExceptionState::SetterContext, "unsignedLongAt
tribute", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 466 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 466 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 467 V8TRYCATCH_EXCEPTION_VOID(unsigned, cppValue, toUInt32(jsValue, exceptionSta
te), exceptionState); | 467 V8TRYCATCH_EXCEPTION_VOID(unsigned, cppValue, toUInt32(jsValue, exceptionSta
te), exceptionState); |
| 468 imp->setUnsignedLongAttribute(cppValue); | 468 imp->setUnsignedLongAttribute(cppValue); |
| 469 } | 469 } |
| 470 | 470 |
| 471 static void unsignedLongAttributeAttributeSetterCallback(v8::Local<v8::String>,
v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 471 static void unsignedLongAttributeAttributeSetterCallback(v8::Local<v8::String>,
v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 472 { | 472 { |
| 473 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 473 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 474 TestObjectPythonV8Internal::unsignedLongAttributeAttributeSetter(jsValue, in
fo); | 474 TestObjectPythonV8Internal::unsignedLongAttributeAttributeSetter(jsValue, in
fo); |
| 475 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 475 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 476 } | 476 } |
| 477 | 477 |
| 478 static void unsignedLongLongAttributeAttributeGetter(const v8::PropertyCallbackI
nfo<v8::Value>& info) | 478 static void unsignedLongLongAttributeAttributeGetter(const v8::PropertyCallbackI
nfo<v8::Value>& info) |
| 479 { | 479 { |
| 480 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 480 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 481 v8SetReturnValue(info, static_cast<double>(imp->unsignedLongLongAttribute())
); | 481 v8SetReturnValue(info, static_cast<double>(imp->unsignedLongLongAttribute())
); |
| 482 } | 482 } |
| 483 | 483 |
| 484 static void unsignedLongLongAttributeAttributeGetterCallback(v8::Local<v8::Strin
g>, const v8::PropertyCallbackInfo<v8::Value>& info) | 484 static void unsignedLongLongAttributeAttributeGetterCallback(v8::Local<v8::Strin
g>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 485 { | 485 { |
| 486 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 486 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 487 TestObjectPythonV8Internal::unsignedLongLongAttributeAttributeGetter(info); | 487 TestObjectPythonV8Internal::unsignedLongLongAttributeAttributeGetter(info); |
| 488 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 488 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 489 } | 489 } |
| 490 | 490 |
| 491 static void unsignedLongLongAttributeAttributeSetter(v8::Local<v8::Value> jsValu
e, const v8::PropertyCallbackInfo<void>& info) | 491 static void unsignedLongLongAttributeAttributeSetter(v8::Local<v8::Value> jsValu
e, const v8::PropertyCallbackInfo<void>& info) |
| 492 { | 492 { |
| 493 ExceptionState exceptionState(ExceptionState::SetterContext, "unsignedLongLo
ngAttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); | 493 ExceptionState exceptionState(ExceptionState::SetterContext, "unsignedLongLo
ngAttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 494 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 494 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 495 V8TRYCATCH_EXCEPTION_VOID(unsigned long long, cppValue, toUInt64(jsValue, ex
ceptionState), exceptionState); | 495 V8TRYCATCH_EXCEPTION_VOID(unsigned long long, cppValue, toUInt64(jsValue, ex
ceptionState), exceptionState); |
| 496 imp->setUnsignedLongLongAttribute(cppValue); | 496 imp->setUnsignedLongLongAttribute(cppValue); |
| 497 } | 497 } |
| 498 | 498 |
| 499 static void unsignedLongLongAttributeAttributeSetterCallback(v8::Local<v8::Strin
g>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 499 static void unsignedLongLongAttributeAttributeSetterCallback(v8::Local<v8::Strin
g>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 500 { | 500 { |
| 501 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 501 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 502 TestObjectPythonV8Internal::unsignedLongLongAttributeAttributeSetter(jsValue
, info); | 502 TestObjectPythonV8Internal::unsignedLongLongAttributeAttributeSetter(jsValue
, info); |
| 503 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 503 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 504 } | 504 } |
| 505 | 505 |
| 506 static void unsignedShortAttributeAttributeGetter(const v8::PropertyCallbackInfo
<v8::Value>& info) | 506 static void unsignedShortAttributeAttributeGetter(const v8::PropertyCallbackInfo
<v8::Value>& info) |
| 507 { | 507 { |
| 508 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 508 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 509 v8SetReturnValueUnsigned(info, imp->unsignedShortAttribute()); | 509 v8SetReturnValueUnsigned(info, imp->unsignedShortAttribute()); |
| 510 } | 510 } |
| 511 | 511 |
| 512 static void unsignedShortAttributeAttributeGetterCallback(v8::Local<v8::String>,
const v8::PropertyCallbackInfo<v8::Value>& info) | 512 static void unsignedShortAttributeAttributeGetterCallback(v8::Local<v8::String>,
const v8::PropertyCallbackInfo<v8::Value>& info) |
| 513 { | 513 { |
| 514 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 514 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 515 TestObjectPythonV8Internal::unsignedShortAttributeAttributeGetter(info); | 515 TestObjectPythonV8Internal::unsignedShortAttributeAttributeGetter(info); |
| 516 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 516 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 517 } | 517 } |
| 518 | 518 |
| 519 static void unsignedShortAttributeAttributeSetter(v8::Local<v8::Value> jsValue,
const v8::PropertyCallbackInfo<void>& info) | 519 static void unsignedShortAttributeAttributeSetter(v8::Local<v8::Value> jsValue,
const v8::PropertyCallbackInfo<void>& info) |
| 520 { | 520 { |
| 521 ExceptionState exceptionState(ExceptionState::SetterContext, "unsignedShortA
ttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); | 521 ExceptionState exceptionState(ExceptionState::SetterContext, "unsignedShortA
ttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 522 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 522 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 523 V8TRYCATCH_EXCEPTION_VOID(unsigned, cppValue, toUInt16(jsValue, exceptionSta
te), exceptionState); | 523 V8TRYCATCH_EXCEPTION_VOID(unsigned, cppValue, toUInt16(jsValue, exceptionSta
te), exceptionState); |
| 524 imp->setUnsignedShortAttribute(cppValue); | 524 imp->setUnsignedShortAttribute(cppValue); |
| 525 } | 525 } |
| 526 | 526 |
| 527 static void unsignedShortAttributeAttributeSetterCallback(v8::Local<v8::String>,
v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 527 static void unsignedShortAttributeAttributeSetterCallback(v8::Local<v8::String>,
v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 528 { | 528 { |
| 529 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 529 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 530 TestObjectPythonV8Internal::unsignedShortAttributeAttributeSetter(jsValue, i
nfo); | 530 TestObjectPythonV8Internal::unsignedShortAttributeAttributeSetter(jsValue, i
nfo); |
| 531 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 531 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 532 } | 532 } |
| 533 | 533 |
| 534 static void testInterfaceEmptyAttributeAttributeGetter(const v8::PropertyCallbac
kInfo<v8::Value>& info) | 534 static void testInterfaceEmptyAttributeAttributeGetter(const v8::PropertyCallbac
kInfo<v8::Value>& info) |
| 535 { | 535 { |
| 536 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 536 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 537 v8SetReturnValueFast(info, imp->testInterfaceEmptyAttribute(), imp); | 537 v8SetReturnValueFast(info, imp->testInterfaceEmptyAttribute(), imp); |
| 538 } | 538 } |
| 539 | 539 |
| 540 static void testInterfaceEmptyAttributeAttributeGetterCallback(v8::Local<v8::Str
ing>, const v8::PropertyCallbackInfo<v8::Value>& info) | 540 static void testInterfaceEmptyAttributeAttributeGetterCallback(v8::Local<v8::Str
ing>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 541 { | 541 { |
| 542 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 542 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 543 TestObjectPythonV8Internal::testInterfaceEmptyAttributeAttributeGetter(info)
; | 543 TestObjectPythonV8Internal::testInterfaceEmptyAttributeAttributeGetter(info)
; |
| 544 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 544 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 545 } | 545 } |
| 546 | 546 |
| 547 static void testInterfaceEmptyAttributeAttributeSetter(v8::Local<v8::Value> jsVa
lue, const v8::PropertyCallbackInfo<void>& info) | 547 static void testInterfaceEmptyAttributeAttributeSetter(v8::Local<v8::Value> jsVa
lue, const v8::PropertyCallbackInfo<void>& info) |
| 548 { | 548 { |
| 549 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 549 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 550 V8TRYCATCH_VOID(TestInterfaceEmpty*, cppValue, V8TestInterfaceEmpty::hasInst
ance(jsValue, info.GetIsolate(), worldType(info.GetIsolate())) ? V8TestInterface
Empty::toNative(v8::Handle<v8::Object>::Cast(jsValue)) : 0); | 550 V8TRYCATCH_VOID(TestInterfaceEmpty*, cppValue, V8TestInterfaceEmpty::hasInst
ance(jsValue, info.GetIsolate(), worldType(info.GetIsolate())) ? V8TestInterface
Empty::toNative(v8::Handle<v8::Object>::Cast(jsValue)) : 0); |
| 551 imp->setTestInterfaceEmptyAttribute(WTF::getPtr(cppValue)); | 551 imp->setTestInterfaceEmptyAttribute(WTF::getPtr(cppValue)); |
| 552 } | 552 } |
| 553 | 553 |
| 554 static void testInterfaceEmptyAttributeAttributeSetterCallback(v8::Local<v8::Str
ing>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 554 static void testInterfaceEmptyAttributeAttributeSetterCallback(v8::Local<v8::Str
ing>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 555 { | 555 { |
| 556 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 556 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 557 TestObjectPythonV8Internal::testInterfaceEmptyAttributeAttributeSetter(jsVal
ue, info); | 557 TestObjectPythonV8Internal::testInterfaceEmptyAttributeAttributeSetter(jsVal
ue, info); |
| 558 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 558 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 559 } | 559 } |
| 560 | 560 |
| 561 static void testObjectPythonAttributeAttributeGetter(const v8::PropertyCallbackI
nfo<v8::Value>& info) | 561 static void testObjectPythonAttributeAttributeGetter(const v8::PropertyCallbackI
nfo<v8::Value>& info) |
| 562 { | 562 { |
| 563 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 563 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 564 v8SetReturnValueFast(info, imp->testObjectPythonAttribute(), imp); | 564 v8SetReturnValueFast(info, imp->testObjectPythonAttribute(), imp); |
| 565 } | 565 } |
| 566 | 566 |
| 567 static void testObjectPythonAttributeAttributeGetterCallback(v8::Local<v8::Strin
g>, const v8::PropertyCallbackInfo<v8::Value>& info) | 567 static void testObjectPythonAttributeAttributeGetterCallback(v8::Local<v8::Strin
g>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 568 { | 568 { |
| 569 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 569 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 570 TestObjectPythonV8Internal::testObjectPythonAttributeAttributeGetter(info); | 570 TestObjectPythonV8Internal::testObjectPythonAttributeAttributeGetter(info); |
| 571 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 571 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 572 } | 572 } |
| 573 | 573 |
| 574 static void testObjectPythonAttributeAttributeSetter(v8::Local<v8::Value> jsValu
e, const v8::PropertyCallbackInfo<void>& info) | 574 static void testObjectPythonAttributeAttributeSetter(v8::Local<v8::Value> jsValu
e, const v8::PropertyCallbackInfo<void>& info) |
| 575 { | 575 { |
| 576 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 576 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 577 V8TRYCATCH_VOID(TestObjectPython*, cppValue, V8TestObjectPython::hasInstance
(jsValue, info.GetIsolate(), worldType(info.GetIsolate())) ? V8TestObjectPython:
:toNative(v8::Handle<v8::Object>::Cast(jsValue)) : 0); | 577 V8TRYCATCH_VOID(TestObjectPython*, cppValue, V8TestObjectPython::hasInstance
(jsValue, info.GetIsolate(), worldType(info.GetIsolate())) ? V8TestObjectPython:
:toNative(v8::Handle<v8::Object>::Cast(jsValue)) : 0); |
| 578 imp->setTestObjectPythonAttribute(WTF::getPtr(cppValue)); | 578 imp->setTestObjectPythonAttribute(WTF::getPtr(cppValue)); |
| 579 } | 579 } |
| 580 | 580 |
| 581 static void testObjectPythonAttributeAttributeSetterCallback(v8::Local<v8::Strin
g>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 581 static void testObjectPythonAttributeAttributeSetterCallback(v8::Local<v8::Strin
g>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 582 { | 582 { |
| 583 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 583 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 584 TestObjectPythonV8Internal::testObjectPythonAttributeAttributeSetter(jsValue
, info); | 584 TestObjectPythonV8Internal::testObjectPythonAttributeAttributeSetter(jsValue
, info); |
| 585 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 585 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 586 } | 586 } |
| 587 | 587 |
| 588 static void voidCallbackFunctionAttributeAttributeGetter(const v8::PropertyCallb
ackInfo<v8::Value>& info) | 588 static void voidCallbackFunctionAttributeAttributeGetter(const v8::PropertyCallb
ackInfo<v8::Value>& info) |
| 589 { | 589 { |
| 590 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 590 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 591 v8SetReturnValue(info, imp->voidCallbackFunctionAttribute().v8Value()); | 591 v8SetReturnValue(info, imp->voidCallbackFunctionAttribute().v8Value()); |
| 592 } | 592 } |
| 593 | 593 |
| 594 static void voidCallbackFunctionAttributeAttributeGetterCallback(v8::Local<v8::S
tring>, const v8::PropertyCallbackInfo<v8::Value>& info) | 594 static void voidCallbackFunctionAttributeAttributeGetterCallback(v8::Local<v8::S
tring>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 595 { | 595 { |
| 596 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 596 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 597 TestObjectPythonV8Internal::voidCallbackFunctionAttributeAttributeGetter(inf
o); | 597 TestObjectPythonV8Internal::voidCallbackFunctionAttributeAttributeGetter(inf
o); |
| 598 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 598 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 599 } | 599 } |
| 600 | 600 |
| 601 static void voidCallbackFunctionAttributeAttributeSetter(v8::Local<v8::Value> js
Value, const v8::PropertyCallbackInfo<void>& info) | 601 static void voidCallbackFunctionAttributeAttributeSetter(v8::Local<v8::Value> js
Value, const v8::PropertyCallbackInfo<void>& info) |
| 602 { | 602 { |
| 603 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 603 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 604 V8TRYCATCH_VOID(ScriptValue, cppValue, ScriptValue(jsValue, info.GetIsolate(
))); | 604 V8TRYCATCH_VOID(ScriptValue, cppValue, ScriptValue(jsValue, info.GetIsolate(
))); |
| 605 imp->setVoidCallbackFunctionAttribute(cppValue); | 605 imp->setVoidCallbackFunctionAttribute(cppValue); |
| 606 } | 606 } |
| 607 | 607 |
| 608 static void voidCallbackFunctionAttributeAttributeSetterCallback(v8::Local<v8::S
tring>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info
) | 608 static void voidCallbackFunctionAttributeAttributeSetterCallback(v8::Local<v8::S
tring>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info
) |
| 609 { | 609 { |
| 610 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 610 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 611 TestObjectPythonV8Internal::voidCallbackFunctionAttributeAttributeSetter(jsV
alue, info); | 611 TestObjectPythonV8Internal::voidCallbackFunctionAttributeAttributeSetter(jsV
alue, info); |
| 612 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 612 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 613 } | 613 } |
| 614 | 614 |
| 615 static void anyCallbackFunctionOptionalAnyArgAttributeAttributeGetter(const v8::
PropertyCallbackInfo<v8::Value>& info) | 615 static void anyCallbackFunctionOptionalAnyArgAttributeAttributeGetter(const v8::
PropertyCallbackInfo<v8::Value>& info) |
| 616 { | 616 { |
| 617 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 617 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 618 v8SetReturnValue(info, imp->anyCallbackFunctionOptionalAnyArgAttribute().v8V
alue()); | 618 v8SetReturnValue(info, imp->anyCallbackFunctionOptionalAnyArgAttribute().v8V
alue()); |
| 619 } | 619 } |
| 620 | 620 |
| 621 static void anyCallbackFunctionOptionalAnyArgAttributeAttributeGetterCallback(v8
::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) | 621 static void anyCallbackFunctionOptionalAnyArgAttributeAttributeGetterCallback(v8
::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 622 { | 622 { |
| 623 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 623 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 624 TestObjectPythonV8Internal::anyCallbackFunctionOptionalAnyArgAttributeAttrib
uteGetter(info); | 624 TestObjectPythonV8Internal::anyCallbackFunctionOptionalAnyArgAttributeAttrib
uteGetter(info); |
| 625 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 625 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 626 } | 626 } |
| 627 | 627 |
| 628 static void anyCallbackFunctionOptionalAnyArgAttributeAttributeSetter(v8::Local<
v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 628 static void anyCallbackFunctionOptionalAnyArgAttributeAttributeSetter(v8::Local<
v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 629 { | 629 { |
| 630 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 630 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 631 V8TRYCATCH_VOID(ScriptValue, cppValue, ScriptValue(jsValue, info.GetIsolate(
))); | 631 V8TRYCATCH_VOID(ScriptValue, cppValue, ScriptValue(jsValue, info.GetIsolate(
))); |
| 632 imp->setAnyCallbackFunctionOptionalAnyArgAttribute(cppValue); | 632 imp->setAnyCallbackFunctionOptionalAnyArgAttribute(cppValue); |
| 633 } | 633 } |
| 634 | 634 |
| 635 static void anyCallbackFunctionOptionalAnyArgAttributeAttributeSetterCallback(v8
::Local<v8::String>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInf
o<void>& info) | 635 static void anyCallbackFunctionOptionalAnyArgAttributeAttributeSetterCallback(v8
::Local<v8::String>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInf
o<void>& info) |
| 636 { | 636 { |
| 637 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 637 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 638 TestObjectPythonV8Internal::anyCallbackFunctionOptionalAnyArgAttributeAttrib
uteSetter(jsValue, info); | 638 TestObjectPythonV8Internal::anyCallbackFunctionOptionalAnyArgAttributeAttrib
uteSetter(jsValue, info); |
| 639 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 639 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 640 } | 640 } |
| 641 | 641 |
| 642 static void cssAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::Value
>& info) | 642 static void cssAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::Value
>& info) |
| 643 { | 643 { |
| 644 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 644 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 645 v8SetReturnValueInt(info, imp->cssAttribute()); | 645 v8SetReturnValueInt(info, imp->cssAttribute()); |
| 646 } | 646 } |
| 647 | 647 |
| 648 static void cssAttributeAttributeGetterCallback(v8::Local<v8::String>, const v8:
:PropertyCallbackInfo<v8::Value>& info) | 648 static void cssAttributeAttributeGetterCallback(v8::Local<v8::String>, const v8:
:PropertyCallbackInfo<v8::Value>& info) |
| 649 { | 649 { |
| 650 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 650 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 651 TestObjectPythonV8Internal::cssAttributeAttributeGetter(info); | 651 TestObjectPythonV8Internal::cssAttributeAttributeGetter(info); |
| 652 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 652 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 653 } | 653 } |
| 654 | 654 |
| 655 static void cssAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const v8::
PropertyCallbackInfo<void>& info) | 655 static void cssAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const v8::
PropertyCallbackInfo<void>& info) |
| 656 { | 656 { |
| 657 ExceptionState exceptionState(ExceptionState::SetterContext, "cssAttribute",
"TestObjectPython", info.Holder(), info.GetIsolate()); | 657 ExceptionState exceptionState(ExceptionState::SetterContext, "cssAttribute",
"TestObjectPython", info.Holder(), info.GetIsolate()); |
| 658 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 658 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 659 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); | 659 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); |
| 660 imp->setCSSAttribute(cppValue); | 660 imp->setCSSAttribute(cppValue); |
| 661 } | 661 } |
| 662 | 662 |
| 663 static void cssAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::Local
<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 663 static void cssAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::Local
<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 664 { | 664 { |
| 665 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 665 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 666 TestObjectPythonV8Internal::cssAttributeAttributeSetter(jsValue, info); | 666 TestObjectPythonV8Internal::cssAttributeAttributeSetter(jsValue, info); |
| 667 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 667 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 668 } | 668 } |
| 669 | 669 |
| 670 static void imeAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::Value
>& info) | 670 static void imeAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::Value
>& info) |
| 671 { | 671 { |
| 672 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 672 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 673 v8SetReturnValueInt(info, imp->imeAttribute()); | 673 v8SetReturnValueInt(info, imp->imeAttribute()); |
| 674 } | 674 } |
| 675 | 675 |
| 676 static void imeAttributeAttributeGetterCallback(v8::Local<v8::String>, const v8:
:PropertyCallbackInfo<v8::Value>& info) | 676 static void imeAttributeAttributeGetterCallback(v8::Local<v8::String>, const v8:
:PropertyCallbackInfo<v8::Value>& info) |
| 677 { | 677 { |
| 678 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 678 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 679 TestObjectPythonV8Internal::imeAttributeAttributeGetter(info); | 679 TestObjectPythonV8Internal::imeAttributeAttributeGetter(info); |
| 680 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 680 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 681 } | 681 } |
| 682 | 682 |
| 683 static void imeAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const v8::
PropertyCallbackInfo<void>& info) | 683 static void imeAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const v8::
PropertyCallbackInfo<void>& info) |
| 684 { | 684 { |
| 685 ExceptionState exceptionState(ExceptionState::SetterContext, "imeAttribute",
"TestObjectPython", info.Holder(), info.GetIsolate()); | 685 ExceptionState exceptionState(ExceptionState::SetterContext, "imeAttribute",
"TestObjectPython", info.Holder(), info.GetIsolate()); |
| 686 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 686 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 687 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); | 687 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); |
| 688 imp->setIMEAttribute(cppValue); | 688 imp->setIMEAttribute(cppValue); |
| 689 } | 689 } |
| 690 | 690 |
| 691 static void imeAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::Local
<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 691 static void imeAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::Local
<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 692 { | 692 { |
| 693 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 693 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 694 TestObjectPythonV8Internal::imeAttributeAttributeSetter(jsValue, info); | 694 TestObjectPythonV8Internal::imeAttributeAttributeSetter(jsValue, info); |
| 695 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 695 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 696 } | 696 } |
| 697 | 697 |
| 698 static void svgAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::Value
>& info) | 698 static void svgAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::Value
>& info) |
| 699 { | 699 { |
| 700 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 700 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 701 v8SetReturnValueInt(info, imp->svgAttribute()); | 701 v8SetReturnValueInt(info, imp->svgAttribute()); |
| 702 } | 702 } |
| 703 | 703 |
| 704 static void svgAttributeAttributeGetterCallback(v8::Local<v8::String>, const v8:
:PropertyCallbackInfo<v8::Value>& info) | 704 static void svgAttributeAttributeGetterCallback(v8::Local<v8::String>, const v8:
:PropertyCallbackInfo<v8::Value>& info) |
| 705 { | 705 { |
| 706 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 706 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 707 TestObjectPythonV8Internal::svgAttributeAttributeGetter(info); | 707 TestObjectPythonV8Internal::svgAttributeAttributeGetter(info); |
| 708 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 708 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 709 } | 709 } |
| 710 | 710 |
| 711 static void svgAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const v8::
PropertyCallbackInfo<void>& info) | 711 static void svgAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const v8::
PropertyCallbackInfo<void>& info) |
| 712 { | 712 { |
| 713 ExceptionState exceptionState(ExceptionState::SetterContext, "svgAttribute",
"TestObjectPython", info.Holder(), info.GetIsolate()); | 713 ExceptionState exceptionState(ExceptionState::SetterContext, "svgAttribute",
"TestObjectPython", info.Holder(), info.GetIsolate()); |
| 714 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 714 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 715 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); | 715 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); |
| 716 imp->setSVGAttribute(cppValue); | 716 imp->setSVGAttribute(cppValue); |
| 717 } | 717 } |
| 718 | 718 |
| 719 static void svgAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::Local
<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 719 static void svgAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::Local
<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 720 { | 720 { |
| 721 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 721 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 722 TestObjectPythonV8Internal::svgAttributeAttributeSetter(jsValue, info); | 722 TestObjectPythonV8Internal::svgAttributeAttributeSetter(jsValue, info); |
| 723 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 723 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 724 } | 724 } |
| 725 | 725 |
| 726 static void xmlAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::Value
>& info) | 726 static void xmlAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::Value
>& info) |
| 727 { | 727 { |
| 728 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 728 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 729 v8SetReturnValueInt(info, imp->xmlAttribute()); | 729 v8SetReturnValueInt(info, imp->xmlAttribute()); |
| 730 } | 730 } |
| 731 | 731 |
| 732 static void xmlAttributeAttributeGetterCallback(v8::Local<v8::String>, const v8:
:PropertyCallbackInfo<v8::Value>& info) | 732 static void xmlAttributeAttributeGetterCallback(v8::Local<v8::String>, const v8:
:PropertyCallbackInfo<v8::Value>& info) |
| 733 { | 733 { |
| 734 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 734 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 735 TestObjectPythonV8Internal::xmlAttributeAttributeGetter(info); | 735 TestObjectPythonV8Internal::xmlAttributeAttributeGetter(info); |
| 736 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 736 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 737 } | 737 } |
| 738 | 738 |
| 739 static void xmlAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const v8::
PropertyCallbackInfo<void>& info) | 739 static void xmlAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const v8::
PropertyCallbackInfo<void>& info) |
| 740 { | 740 { |
| 741 ExceptionState exceptionState(ExceptionState::SetterContext, "xmlAttribute",
"TestObjectPython", info.Holder(), info.GetIsolate()); | 741 ExceptionState exceptionState(ExceptionState::SetterContext, "xmlAttribute",
"TestObjectPython", info.Holder(), info.GetIsolate()); |
| 742 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 742 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 743 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); | 743 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); |
| 744 imp->setXMLAttribute(cppValue); | 744 imp->setXMLAttribute(cppValue); |
| 745 } | 745 } |
| 746 | 746 |
| 747 static void xmlAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::Local
<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 747 static void xmlAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::Local
<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 748 { | 748 { |
| 749 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 749 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 750 TestObjectPythonV8Internal::xmlAttributeAttributeSetter(jsValue, info); | 750 TestObjectPythonV8Internal::xmlAttributeAttributeSetter(jsValue, info); |
| 751 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 751 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 752 } | 752 } |
| 753 | 753 |
| 754 static void nodeFilterAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8
::Value>& info) | 754 static void nodeFilterAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8
::Value>& info) |
| 755 { | 755 { |
| 756 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 756 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 757 v8SetReturnValueFast(info, imp->nodeFilterAttribute(), imp); | 757 v8SetReturnValueFast(info, imp->nodeFilterAttribute(), imp); |
| 758 } | 758 } |
| 759 | 759 |
| 760 static void nodeFilterAttributeAttributeGetterCallback(v8::Local<v8::String>, co
nst v8::PropertyCallbackInfo<v8::Value>& info) | 760 static void nodeFilterAttributeAttributeGetterCallback(v8::Local<v8::String>, co
nst v8::PropertyCallbackInfo<v8::Value>& info) |
| 761 { | 761 { |
| 762 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 762 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 763 TestObjectPythonV8Internal::nodeFilterAttributeAttributeGetter(info); | 763 TestObjectPythonV8Internal::nodeFilterAttributeAttributeGetter(info); |
| 764 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 764 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 765 } | 765 } |
| 766 | 766 |
| 767 static void nodeFilterAttributeAttributeSetter(v8::Local<v8::Value> jsValue, con
st v8::PropertyCallbackInfo<void>& info) | 767 static void nodeFilterAttributeAttributeSetter(v8::Local<v8::Value> jsValue, con
st v8::PropertyCallbackInfo<void>& info) |
| 768 { | 768 { |
| 769 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 769 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 770 V8TRYCATCH_VOID(RefPtr<NodeFilter>, cppValue, toNodeFilter(jsValue, info.Get
Isolate())); | 770 V8TRYCATCH_VOID(RefPtr<NodeFilter>, cppValue, toNodeFilter(jsValue, info.Get
Isolate())); |
| 771 imp->setNodeFilterAttribute(WTF::getPtr(cppValue)); | 771 imp->setNodeFilterAttribute(WTF::getPtr(cppValue)); |
| 772 } | 772 } |
| 773 | 773 |
| 774 static void nodeFilterAttributeAttributeSetterCallback(v8::Local<v8::String>, v8
::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 774 static void nodeFilterAttributeAttributeSetterCallback(v8::Local<v8::String>, v8
::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 775 { | 775 { |
| 776 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 776 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 777 TestObjectPythonV8Internal::nodeFilterAttributeAttributeSetter(jsValue, info
); | 777 TestObjectPythonV8Internal::nodeFilterAttributeAttributeSetter(jsValue, info
); |
| 778 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 778 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 779 } | 779 } |
| 780 | 780 |
| 781 static void serializedScriptValueAttributeAttributeGetter(const v8::PropertyCall
backInfo<v8::Value>& info) | 781 static void serializedScriptValueAttributeAttributeGetter(const v8::PropertyCall
backInfo<v8::Value>& info) |
| 782 { | 782 { |
| 783 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 783 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 784 v8SetReturnValue(info, imp->serializedScriptValueAttribute() ? imp->serializ
edScriptValueAttribute()->deserialize() : v8::Handle<v8::Value>(v8::Null(info.Ge
tIsolate()))); | 784 v8SetReturnValue(info, imp->serializedScriptValueAttribute() ? imp->serializ
edScriptValueAttribute()->deserialize() : v8::Handle<v8::Value>(v8::Null(info.Ge
tIsolate()))); |
| 785 } | 785 } |
| 786 | 786 |
| 787 static void serializedScriptValueAttributeAttributeGetterCallback(v8::Local<v8::
String>, const v8::PropertyCallbackInfo<v8::Value>& info) | 787 static void serializedScriptValueAttributeAttributeGetterCallback(v8::Local<v8::
String>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 788 { | 788 { |
| 789 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 789 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 790 TestObjectPythonV8Internal::serializedScriptValueAttributeAttributeGetter(in
fo); | 790 TestObjectPythonV8Internal::serializedScriptValueAttributeAttributeGetter(in
fo); |
| 791 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 791 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 792 } | 792 } |
| 793 | 793 |
| 794 static void serializedScriptValueAttributeAttributeSetter(v8::Local<v8::Value> j
sValue, const v8::PropertyCallbackInfo<void>& info) | 794 static void serializedScriptValueAttributeAttributeSetter(v8::Local<v8::Value> j
sValue, const v8::PropertyCallbackInfo<void>& info) |
| 795 { | 795 { |
| 796 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 796 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 797 V8TRYCATCH_VOID(RefPtr<SerializedScriptValue>, cppValue, SerializedScriptVal
ue::create(jsValue, info.GetIsolate())); | 797 V8TRYCATCH_VOID(RefPtr<SerializedScriptValue>, cppValue, SerializedScriptVal
ue::create(jsValue, info.GetIsolate())); |
| 798 imp->setSerializedScriptValueAttribute(WTF::getPtr(cppValue)); | 798 imp->setSerializedScriptValueAttribute(WTF::getPtr(cppValue)); |
| 799 } | 799 } |
| 800 | 800 |
| 801 static void serializedScriptValueAttributeAttributeSetterCallback(v8::Local<v8::
String>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& inf
o) | 801 static void serializedScriptValueAttributeAttributeSetterCallback(v8::Local<v8::
String>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& inf
o) |
| 802 { | 802 { |
| 803 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 803 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 804 TestObjectPythonV8Internal::serializedScriptValueAttributeAttributeSetter(js
Value, info); | 804 TestObjectPythonV8Internal::serializedScriptValueAttributeAttributeSetter(js
Value, info); |
| 805 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 805 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 806 } | 806 } |
| 807 | 807 |
| 808 static void anyAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::Value
>& info) | 808 static void anyAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::Value
>& info) |
| 809 { | 809 { |
| 810 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 810 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 811 v8SetReturnValue(info, imp->anyAttribute().v8Value()); | 811 v8SetReturnValue(info, imp->anyAttribute().v8Value()); |
| 812 } | 812 } |
| 813 | 813 |
| 814 static void anyAttributeAttributeGetterCallback(v8::Local<v8::String>, const v8:
:PropertyCallbackInfo<v8::Value>& info) | 814 static void anyAttributeAttributeGetterCallback(v8::Local<v8::String>, const v8:
:PropertyCallbackInfo<v8::Value>& info) |
| 815 { | 815 { |
| 816 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 816 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 817 TestObjectPythonV8Internal::anyAttributeAttributeGetter(info); | 817 TestObjectPythonV8Internal::anyAttributeAttributeGetter(info); |
| 818 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 818 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 819 } | 819 } |
| 820 | 820 |
| 821 static void anyAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const v8::
PropertyCallbackInfo<void>& info) | 821 static void anyAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const v8::
PropertyCallbackInfo<void>& info) |
| 822 { | 822 { |
| 823 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 823 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 824 V8TRYCATCH_VOID(ScriptValue, cppValue, ScriptValue(jsValue, info.GetIsolate(
))); | 824 V8TRYCATCH_VOID(ScriptValue, cppValue, ScriptValue(jsValue, info.GetIsolate(
))); |
| 825 imp->setAnyAttribute(cppValue); | 825 imp->setAnyAttribute(cppValue); |
| 826 } | 826 } |
| 827 | 827 |
| 828 static void anyAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::Local
<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 828 static void anyAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::Local
<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 829 { | 829 { |
| 830 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 830 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 831 TestObjectPythonV8Internal::anyAttributeAttributeSetter(jsValue, info); | 831 TestObjectPythonV8Internal::anyAttributeAttributeSetter(jsValue, info); |
| 832 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 832 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 833 } | 833 } |
| 834 | 834 |
| 835 static void promiseAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::V
alue>& info) | 835 static void promiseAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::V
alue>& info) |
| 836 { | 836 { |
| 837 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 837 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 838 v8SetReturnValue(info, imp->promiseAttribute().v8Value()); | 838 v8SetReturnValue(info, imp->promiseAttribute().v8Value()); |
| 839 } | 839 } |
| 840 | 840 |
| 841 static void promiseAttributeAttributeGetterCallback(v8::Local<v8::String>, const
v8::PropertyCallbackInfo<v8::Value>& info) | 841 static void promiseAttributeAttributeGetterCallback(v8::Local<v8::String>, const
v8::PropertyCallbackInfo<v8::Value>& info) |
| 842 { | 842 { |
| 843 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 843 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 844 TestObjectPythonV8Internal::promiseAttributeAttributeGetter(info); | 844 TestObjectPythonV8Internal::promiseAttributeAttributeGetter(info); |
| 845 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 845 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 846 } | 846 } |
| 847 | 847 |
| 848 static void promiseAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const
v8::PropertyCallbackInfo<void>& info) | 848 static void promiseAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const
v8::PropertyCallbackInfo<void>& info) |
| 849 { | 849 { |
| 850 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 850 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 851 V8TRYCATCH_VOID(ScriptPromise, cppValue, ScriptPromise(jsValue)); | 851 V8TRYCATCH_VOID(ScriptPromise, cppValue, ScriptPromise(jsValue)); |
| 852 imp->setPromiseAttribute(cppValue); | 852 imp->setPromiseAttribute(cppValue); |
| 853 } | 853 } |
| 854 | 854 |
| 855 static void promiseAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::L
ocal<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 855 static void promiseAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::L
ocal<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 856 { | 856 { |
| 857 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 857 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 858 TestObjectPythonV8Internal::promiseAttributeAttributeSetter(jsValue, info); | 858 TestObjectPythonV8Internal::promiseAttributeAttributeSetter(jsValue, info); |
| 859 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 859 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 860 } | 860 } |
| 861 | 861 |
| 862 static void windowAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::Va
lue>& info) | 862 static void windowAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::Va
lue>& info) |
| 863 { | 863 { |
| 864 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 864 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 865 v8SetReturnValueFast(info, imp->windowAttribute(), imp); | 865 v8SetReturnValueFast(info, imp->windowAttribute(), imp); |
| 866 } | 866 } |
| 867 | 867 |
| 868 static void windowAttributeAttributeGetterCallback(v8::Local<v8::String>, const
v8::PropertyCallbackInfo<v8::Value>& info) | 868 static void windowAttributeAttributeGetterCallback(v8::Local<v8::String>, const
v8::PropertyCallbackInfo<v8::Value>& info) |
| 869 { | 869 { |
| 870 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 870 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 871 TestObjectPythonV8Internal::windowAttributeAttributeGetter(info); | 871 TestObjectPythonV8Internal::windowAttributeAttributeGetter(info); |
| 872 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 872 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 873 } | 873 } |
| 874 | 874 |
| 875 static void windowAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const v
8::PropertyCallbackInfo<void>& info) | 875 static void windowAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const v
8::PropertyCallbackInfo<void>& info) |
| 876 { | 876 { |
| 877 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 877 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 878 V8TRYCATCH_VOID(DOMWindow*, cppValue, toNativeDOMWindow(jsValue, info.GetIso
late())); | 878 V8TRYCATCH_VOID(DOMWindow*, cppValue, toNativeDOMWindow(jsValue, info.GetIso
late())); |
| 879 imp->setWindowAttribute(WTF::getPtr(cppValue)); | 879 imp->setWindowAttribute(WTF::getPtr(cppValue)); |
| 880 } | 880 } |
| 881 | 881 |
| 882 static void windowAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::Lo
cal<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 882 static void windowAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::Lo
cal<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 883 { | 883 { |
| 884 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 884 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 885 TestObjectPythonV8Internal::windowAttributeAttributeSetter(jsValue, info); | 885 TestObjectPythonV8Internal::windowAttributeAttributeSetter(jsValue, info); |
| 886 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 886 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 887 } | 887 } |
| 888 | 888 |
| 889 static void documentAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::
Value>& info) | 889 static void documentAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::
Value>& info) |
| 890 { | 890 { |
| 891 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 891 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 892 v8SetReturnValueFast(info, imp->documentAttribute(), imp); | 892 v8SetReturnValueFast(info, imp->documentAttribute(), imp); |
| 893 } | 893 } |
| 894 | 894 |
| 895 static void documentAttributeAttributeGetterCallback(v8::Local<v8::String>, cons
t v8::PropertyCallbackInfo<v8::Value>& info) | 895 static void documentAttributeAttributeGetterCallback(v8::Local<v8::String>, cons
t v8::PropertyCallbackInfo<v8::Value>& info) |
| 896 { | 896 { |
| 897 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 897 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 898 TestObjectPythonV8Internal::documentAttributeAttributeGetter(info); | 898 TestObjectPythonV8Internal::documentAttributeAttributeGetter(info); |
| 899 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 899 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 900 } | 900 } |
| 901 | 901 |
| 902 static void documentAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const
v8::PropertyCallbackInfo<void>& info) | 902 static void documentAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const
v8::PropertyCallbackInfo<void>& info) |
| 903 { | 903 { |
| 904 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 904 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 905 V8TRYCATCH_VOID(Document*, cppValue, V8Document::hasInstance(jsValue, info.G
etIsolate(), worldType(info.GetIsolate())) ? V8Document::toNative(v8::Handle<v8:
:Object>::Cast(jsValue)) : 0); | 905 V8TRYCATCH_VOID(Document*, cppValue, V8Document::hasInstance(jsValue, info.G
etIsolate(), worldType(info.GetIsolate())) ? V8Document::toNative(v8::Handle<v8:
:Object>::Cast(jsValue)) : 0); |
| 906 imp->setDocumentAttribute(WTF::getPtr(cppValue)); | 906 imp->setDocumentAttribute(WTF::getPtr(cppValue)); |
| 907 } | 907 } |
| 908 | 908 |
| 909 static void documentAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::
Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 909 static void documentAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::
Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 910 { | 910 { |
| 911 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 911 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 912 TestObjectPythonV8Internal::documentAttributeAttributeSetter(jsValue, info); | 912 TestObjectPythonV8Internal::documentAttributeAttributeSetter(jsValue, info); |
| 913 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 913 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 914 } | 914 } |
| 915 | 915 |
| 916 static void documentFragmentAttributeAttributeGetter(const v8::PropertyCallbackI
nfo<v8::Value>& info) | 916 static void documentFragmentAttributeAttributeGetter(const v8::PropertyCallbackI
nfo<v8::Value>& info) |
| 917 { | 917 { |
| 918 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 918 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 919 v8SetReturnValueFast(info, imp->documentFragmentAttribute(), imp); | 919 v8SetReturnValueFast(info, imp->documentFragmentAttribute(), imp); |
| 920 } | 920 } |
| 921 | 921 |
| 922 static void documentFragmentAttributeAttributeGetterCallback(v8::Local<v8::Strin
g>, const v8::PropertyCallbackInfo<v8::Value>& info) | 922 static void documentFragmentAttributeAttributeGetterCallback(v8::Local<v8::Strin
g>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 923 { | 923 { |
| 924 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 924 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 925 TestObjectPythonV8Internal::documentFragmentAttributeAttributeGetter(info); | 925 TestObjectPythonV8Internal::documentFragmentAttributeAttributeGetter(info); |
| 926 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 926 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 927 } | 927 } |
| 928 | 928 |
| 929 static void documentFragmentAttributeAttributeSetter(v8::Local<v8::Value> jsValu
e, const v8::PropertyCallbackInfo<void>& info) | 929 static void documentFragmentAttributeAttributeSetter(v8::Local<v8::Value> jsValu
e, const v8::PropertyCallbackInfo<void>& info) |
| 930 { | 930 { |
| 931 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 931 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 932 V8TRYCATCH_VOID(DocumentFragment*, cppValue, V8DocumentFragment::hasInstance
(jsValue, info.GetIsolate(), worldType(info.GetIsolate())) ? V8DocumentFragment:
:toNative(v8::Handle<v8::Object>::Cast(jsValue)) : 0); | 932 V8TRYCATCH_VOID(DocumentFragment*, cppValue, V8DocumentFragment::hasInstance
(jsValue, info.GetIsolate(), worldType(info.GetIsolate())) ? V8DocumentFragment:
:toNative(v8::Handle<v8::Object>::Cast(jsValue)) : 0); |
| 933 imp->setDocumentFragmentAttribute(WTF::getPtr(cppValue)); | 933 imp->setDocumentFragmentAttribute(WTF::getPtr(cppValue)); |
| 934 } | 934 } |
| 935 | 935 |
| 936 static void documentFragmentAttributeAttributeSetterCallback(v8::Local<v8::Strin
g>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 936 static void documentFragmentAttributeAttributeSetterCallback(v8::Local<v8::Strin
g>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 937 { | 937 { |
| 938 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 938 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 939 TestObjectPythonV8Internal::documentFragmentAttributeAttributeSetter(jsValue
, info); | 939 TestObjectPythonV8Internal::documentFragmentAttributeAttributeSetter(jsValue
, info); |
| 940 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 940 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 941 } | 941 } |
| 942 | 942 |
| 943 static void documentTypeAttributeAttributeGetter(const v8::PropertyCallbackInfo<
v8::Value>& info) | 943 static void documentTypeAttributeAttributeGetter(const v8::PropertyCallbackInfo<
v8::Value>& info) |
| 944 { | 944 { |
| 945 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 945 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 946 v8SetReturnValueFast(info, imp->documentTypeAttribute(), imp); | 946 v8SetReturnValueFast(info, imp->documentTypeAttribute(), imp); |
| 947 } | 947 } |
| 948 | 948 |
| 949 static void documentTypeAttributeAttributeGetterCallback(v8::Local<v8::String>,
const v8::PropertyCallbackInfo<v8::Value>& info) | 949 static void documentTypeAttributeAttributeGetterCallback(v8::Local<v8::String>,
const v8::PropertyCallbackInfo<v8::Value>& info) |
| 950 { | 950 { |
| 951 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 951 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 952 TestObjectPythonV8Internal::documentTypeAttributeAttributeGetter(info); | 952 TestObjectPythonV8Internal::documentTypeAttributeAttributeGetter(info); |
| 953 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 953 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 954 } | 954 } |
| 955 | 955 |
| 956 static void documentTypeAttributeAttributeSetter(v8::Local<v8::Value> jsValue, c
onst v8::PropertyCallbackInfo<void>& info) | 956 static void documentTypeAttributeAttributeSetter(v8::Local<v8::Value> jsValue, c
onst v8::PropertyCallbackInfo<void>& info) |
| 957 { | 957 { |
| 958 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 958 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 959 V8TRYCATCH_VOID(DocumentType*, cppValue, V8DocumentType::hasInstance(jsValue
, info.GetIsolate(), worldType(info.GetIsolate())) ? V8DocumentType::toNative(v8
::Handle<v8::Object>::Cast(jsValue)) : 0); | 959 V8TRYCATCH_VOID(DocumentType*, cppValue, V8DocumentType::hasInstance(jsValue
, info.GetIsolate(), worldType(info.GetIsolate())) ? V8DocumentType::toNative(v8
::Handle<v8::Object>::Cast(jsValue)) : 0); |
| 960 imp->setDocumentTypeAttribute(WTF::getPtr(cppValue)); | 960 imp->setDocumentTypeAttribute(WTF::getPtr(cppValue)); |
| 961 } | 961 } |
| 962 | 962 |
| 963 static void documentTypeAttributeAttributeSetterCallback(v8::Local<v8::String>,
v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 963 static void documentTypeAttributeAttributeSetterCallback(v8::Local<v8::String>,
v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 964 { | 964 { |
| 965 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 965 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 966 TestObjectPythonV8Internal::documentTypeAttributeAttributeSetter(jsValue, in
fo); | 966 TestObjectPythonV8Internal::documentTypeAttributeAttributeSetter(jsValue, in
fo); |
| 967 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 967 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 968 } | 968 } |
| 969 | 969 |
| 970 static void elementAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::V
alue>& info) | 970 static void elementAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::V
alue>& info) |
| 971 { | 971 { |
| 972 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 972 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 973 v8SetReturnValueFast(info, imp->elementAttribute(), imp); | 973 v8SetReturnValueFast(info, imp->elementAttribute(), imp); |
| 974 } | 974 } |
| 975 | 975 |
| 976 static void elementAttributeAttributeGetterCallback(v8::Local<v8::String>, const
v8::PropertyCallbackInfo<v8::Value>& info) | 976 static void elementAttributeAttributeGetterCallback(v8::Local<v8::String>, const
v8::PropertyCallbackInfo<v8::Value>& info) |
| 977 { | 977 { |
| 978 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 978 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 979 TestObjectPythonV8Internal::elementAttributeAttributeGetter(info); | 979 TestObjectPythonV8Internal::elementAttributeAttributeGetter(info); |
| 980 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 980 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 981 } | 981 } |
| 982 | 982 |
| 983 static void elementAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const
v8::PropertyCallbackInfo<void>& info) | 983 static void elementAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const
v8::PropertyCallbackInfo<void>& info) |
| 984 { | 984 { |
| 985 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 985 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 986 V8TRYCATCH_VOID(Element*, cppValue, V8Element::hasInstance(jsValue, info.Get
Isolate(), worldType(info.GetIsolate())) ? V8Element::toNative(v8::Handle<v8::Ob
ject>::Cast(jsValue)) : 0); | 986 V8TRYCATCH_VOID(Element*, cppValue, V8Element::hasInstance(jsValue, info.Get
Isolate(), worldType(info.GetIsolate())) ? V8Element::toNative(v8::Handle<v8::Ob
ject>::Cast(jsValue)) : 0); |
| 987 imp->setElementAttribute(WTF::getPtr(cppValue)); | 987 imp->setElementAttribute(WTF::getPtr(cppValue)); |
| 988 } | 988 } |
| 989 | 989 |
| 990 static void elementAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::L
ocal<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 990 static void elementAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::L
ocal<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 991 { | 991 { |
| 992 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 992 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 993 TestObjectPythonV8Internal::elementAttributeAttributeSetter(jsValue, info); | 993 TestObjectPythonV8Internal::elementAttributeAttributeSetter(jsValue, info); |
| 994 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 994 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 995 } | 995 } |
| 996 | 996 |
| 997 static void entityAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::Va
lue>& info) | 997 static void entityAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::Va
lue>& info) |
| 998 { | 998 { |
| 999 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 999 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1000 v8SetReturnValueFast(info, imp->entityAttribute(), imp); | 1000 v8SetReturnValueFast(info, imp->entityAttribute(), imp); |
| 1001 } | 1001 } |
| 1002 | 1002 |
| 1003 static void entityAttributeAttributeGetterCallback(v8::Local<v8::String>, const
v8::PropertyCallbackInfo<v8::Value>& info) | 1003 static void entityAttributeAttributeGetterCallback(v8::Local<v8::String>, const
v8::PropertyCallbackInfo<v8::Value>& info) |
| 1004 { | 1004 { |
| 1005 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 1005 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 1006 TestObjectPythonV8Internal::entityAttributeAttributeGetter(info); | 1006 TestObjectPythonV8Internal::entityAttributeAttributeGetter(info); |
| 1007 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1007 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1008 } | 1008 } |
| 1009 | 1009 |
| 1010 static void entityAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const v
8::PropertyCallbackInfo<void>& info) | 1010 static void entityAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const v
8::PropertyCallbackInfo<void>& info) |
| 1011 { | 1011 { |
| 1012 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1012 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1013 V8TRYCATCH_VOID(Entity*, cppValue, V8Entity::hasInstance(jsValue, info.GetIs
olate(), worldType(info.GetIsolate())) ? V8Entity::toNative(v8::Handle<v8::Objec
t>::Cast(jsValue)) : 0); | 1013 V8TRYCATCH_VOID(Entity*, cppValue, V8Entity::hasInstance(jsValue, info.GetIs
olate(), worldType(info.GetIsolate())) ? V8Entity::toNative(v8::Handle<v8::Objec
t>::Cast(jsValue)) : 0); |
| 1014 imp->setEntityAttribute(WTF::getPtr(cppValue)); | 1014 imp->setEntityAttribute(WTF::getPtr(cppValue)); |
| 1015 } | 1015 } |
| 1016 | 1016 |
| 1017 static void entityAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::Lo
cal<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 1017 static void entityAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::Lo
cal<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 1018 { | 1018 { |
| 1019 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 1019 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 1020 TestObjectPythonV8Internal::entityAttributeAttributeSetter(jsValue, info); | 1020 TestObjectPythonV8Internal::entityAttributeAttributeSetter(jsValue, info); |
| 1021 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1021 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1022 } | 1022 } |
| 1023 | 1023 |
| 1024 static void nodeAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::Valu
e>& info) | 1024 static void nodeAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::Valu
e>& info) |
| 1025 { | 1025 { |
| 1026 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1026 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1027 v8SetReturnValueFast(info, imp->nodeAttribute(), imp); | 1027 v8SetReturnValueFast(info, imp->nodeAttribute(), imp); |
| 1028 } | 1028 } |
| 1029 | 1029 |
| 1030 static void nodeAttributeAttributeGetterCallback(v8::Local<v8::String>, const v8
::PropertyCallbackInfo<v8::Value>& info) | 1030 static void nodeAttributeAttributeGetterCallback(v8::Local<v8::String>, const v8
::PropertyCallbackInfo<v8::Value>& info) |
| 1031 { | 1031 { |
| 1032 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 1032 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 1033 TestObjectPythonV8Internal::nodeAttributeAttributeGetter(info); | 1033 TestObjectPythonV8Internal::nodeAttributeAttributeGetter(info); |
| 1034 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1034 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1035 } | 1035 } |
| 1036 | 1036 |
| 1037 static void nodeAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const v8:
:PropertyCallbackInfo<void>& info) | 1037 static void nodeAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const v8:
:PropertyCallbackInfo<void>& info) |
| 1038 { | 1038 { |
| 1039 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1039 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1040 V8TRYCATCH_VOID(Node*, cppValue, V8Node::hasInstance(jsValue, info.GetIsolat
e(), worldType(info.GetIsolate())) ? V8Node::toNative(v8::Handle<v8::Object>::Ca
st(jsValue)) : 0); | 1040 V8TRYCATCH_VOID(Node*, cppValue, V8Node::hasInstance(jsValue, info.GetIsolat
e(), worldType(info.GetIsolate())) ? V8Node::toNative(v8::Handle<v8::Object>::Ca
st(jsValue)) : 0); |
| 1041 imp->setNodeAttribute(WTF::getPtr(cppValue)); | 1041 imp->setNodeAttribute(WTF::getPtr(cppValue)); |
| 1042 } | 1042 } |
| 1043 | 1043 |
| 1044 static void nodeAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::Loca
l<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 1044 static void nodeAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::Loca
l<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 1045 { | 1045 { |
| 1046 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 1046 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 1047 TestObjectPythonV8Internal::nodeAttributeAttributeSetter(jsValue, info); | 1047 TestObjectPythonV8Internal::nodeAttributeAttributeSetter(jsValue, info); |
| 1048 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1048 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1049 } | 1049 } |
| 1050 | 1050 |
| 1051 static void shadowRootAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8
::Value>& info) | 1051 static void shadowRootAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8
::Value>& info) |
| 1052 { | 1052 { |
| 1053 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1053 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1054 v8SetReturnValueFast(info, imp->shadowRootAttribute(), imp); | 1054 v8SetReturnValueFast(info, imp->shadowRootAttribute(), imp); |
| 1055 } | 1055 } |
| 1056 | 1056 |
| 1057 static void shadowRootAttributeAttributeGetterCallback(v8::Local<v8::String>, co
nst v8::PropertyCallbackInfo<v8::Value>& info) | 1057 static void shadowRootAttributeAttributeGetterCallback(v8::Local<v8::String>, co
nst v8::PropertyCallbackInfo<v8::Value>& info) |
| 1058 { | 1058 { |
| 1059 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 1059 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 1060 TestObjectPythonV8Internal::shadowRootAttributeAttributeGetter(info); | 1060 TestObjectPythonV8Internal::shadowRootAttributeAttributeGetter(info); |
| 1061 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1061 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1062 } | 1062 } |
| 1063 | 1063 |
| 1064 static void shadowRootAttributeAttributeSetter(v8::Local<v8::Value> jsValue, con
st v8::PropertyCallbackInfo<void>& info) | 1064 static void shadowRootAttributeAttributeSetter(v8::Local<v8::Value> jsValue, con
st v8::PropertyCallbackInfo<void>& info) |
| 1065 { | 1065 { |
| 1066 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1066 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1067 V8TRYCATCH_VOID(ShadowRoot*, cppValue, V8ShadowRoot::hasInstance(jsValue, in
fo.GetIsolate(), worldType(info.GetIsolate())) ? V8ShadowRoot::toNative(v8::Hand
le<v8::Object>::Cast(jsValue)) : 0); | 1067 V8TRYCATCH_VOID(ShadowRoot*, cppValue, V8ShadowRoot::hasInstance(jsValue, in
fo.GetIsolate(), worldType(info.GetIsolate())) ? V8ShadowRoot::toNative(v8::Hand
le<v8::Object>::Cast(jsValue)) : 0); |
| 1068 imp->setShadowRootAttribute(WTF::getPtr(cppValue)); | 1068 imp->setShadowRootAttribute(WTF::getPtr(cppValue)); |
| 1069 } | 1069 } |
| 1070 | 1070 |
| 1071 static void shadowRootAttributeAttributeSetterCallback(v8::Local<v8::String>, v8
::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 1071 static void shadowRootAttributeAttributeSetterCallback(v8::Local<v8::String>, v8
::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 1072 { | 1072 { |
| 1073 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 1073 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 1074 TestObjectPythonV8Internal::shadowRootAttributeAttributeSetter(jsValue, info
); | 1074 TestObjectPythonV8Internal::shadowRootAttributeAttributeSetter(jsValue, info
); |
| 1075 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1075 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1076 } | 1076 } |
| 1077 | 1077 |
| 1078 static void arrayBufferAttributeAttributeGetter(const v8::PropertyCallbackInfo<v
8::Value>& info) | 1078 static void arrayBufferAttributeAttributeGetter(const v8::PropertyCallbackInfo<v
8::Value>& info) |
| 1079 { | 1079 { |
| 1080 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1080 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1081 v8SetReturnValueFast(info, imp->arrayBufferAttribute(), imp); | 1081 v8SetReturnValueFast(info, imp->arrayBufferAttribute(), imp); |
| 1082 } | 1082 } |
| 1083 | 1083 |
| 1084 static void arrayBufferAttributeAttributeGetterCallback(v8::Local<v8::String>, c
onst v8::PropertyCallbackInfo<v8::Value>& info) | 1084 static void arrayBufferAttributeAttributeGetterCallback(v8::Local<v8::String>, c
onst v8::PropertyCallbackInfo<v8::Value>& info) |
| 1085 { | 1085 { |
| 1086 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 1086 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 1087 TestObjectPythonV8Internal::arrayBufferAttributeAttributeGetter(info); | 1087 TestObjectPythonV8Internal::arrayBufferAttributeAttributeGetter(info); |
| 1088 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1088 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1089 } | 1089 } |
| 1090 | 1090 |
| 1091 static void arrayBufferAttributeAttributeSetter(v8::Local<v8::Value> jsValue, co
nst v8::PropertyCallbackInfo<void>& info) | 1091 static void arrayBufferAttributeAttributeSetter(v8::Local<v8::Value> jsValue, co
nst v8::PropertyCallbackInfo<void>& info) |
| 1092 { | 1092 { |
| 1093 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1093 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1094 V8TRYCATCH_VOID(ArrayBuffer*, cppValue, jsValue->IsArrayBuffer() ? V8ArrayBu
ffer::toNative(v8::Handle<v8::ArrayBuffer>::Cast(jsValue)) : 0); | 1094 V8TRYCATCH_VOID(ArrayBuffer*, cppValue, jsValue->IsArrayBuffer() ? V8ArrayBu
ffer::toNative(v8::Handle<v8::ArrayBuffer>::Cast(jsValue)) : 0); |
| 1095 imp->setArrayBufferAttribute(WTF::getPtr(cppValue)); | 1095 imp->setArrayBufferAttribute(WTF::getPtr(cppValue)); |
| 1096 } | 1096 } |
| 1097 | 1097 |
| 1098 static void arrayBufferAttributeAttributeSetterCallback(v8::Local<v8::String>, v
8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 1098 static void arrayBufferAttributeAttributeSetterCallback(v8::Local<v8::String>, v
8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 1099 { | 1099 { |
| 1100 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 1100 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 1101 TestObjectPythonV8Internal::arrayBufferAttributeAttributeSetter(jsValue, inf
o); | 1101 TestObjectPythonV8Internal::arrayBufferAttributeAttributeSetter(jsValue, inf
o); |
| 1102 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1102 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1103 } | 1103 } |
| 1104 | 1104 |
| 1105 static void float32ArrayAttributeAttributeGetter(const v8::PropertyCallbackInfo<
v8::Value>& info) | 1105 static void float32ArrayAttributeAttributeGetter(const v8::PropertyCallbackInfo<
v8::Value>& info) |
| 1106 { | 1106 { |
| 1107 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1107 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1108 v8SetReturnValueFast(info, imp->float32ArrayAttribute(), imp); | 1108 v8SetReturnValueFast(info, imp->float32ArrayAttribute(), imp); |
| 1109 } | 1109 } |
| 1110 | 1110 |
| 1111 static void float32ArrayAttributeAttributeGetterCallback(v8::Local<v8::String>,
const v8::PropertyCallbackInfo<v8::Value>& info) | 1111 static void float32ArrayAttributeAttributeGetterCallback(v8::Local<v8::String>,
const v8::PropertyCallbackInfo<v8::Value>& info) |
| 1112 { | 1112 { |
| 1113 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 1113 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 1114 TestObjectPythonV8Internal::float32ArrayAttributeAttributeGetter(info); | 1114 TestObjectPythonV8Internal::float32ArrayAttributeAttributeGetter(info); |
| 1115 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1115 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1116 } | 1116 } |
| 1117 | 1117 |
| 1118 static void float32ArrayAttributeAttributeSetter(v8::Local<v8::Value> jsValue, c
onst v8::PropertyCallbackInfo<void>& info) | 1118 static void float32ArrayAttributeAttributeSetter(v8::Local<v8::Value> jsValue, c
onst v8::PropertyCallbackInfo<void>& info) |
| 1119 { | 1119 { |
| 1120 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1120 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1121 V8TRYCATCH_VOID(Float32Array*, cppValue, jsValue->IsFloat32Array() ? V8Float
32Array::toNative(v8::Handle<v8::Float32Array>::Cast(jsValue)) : 0); | 1121 V8TRYCATCH_VOID(Float32Array*, cppValue, jsValue->IsFloat32Array() ? V8Float
32Array::toNative(v8::Handle<v8::Float32Array>::Cast(jsValue)) : 0); |
| 1122 imp->setFloat32ArrayAttribute(WTF::getPtr(cppValue)); | 1122 imp->setFloat32ArrayAttribute(WTF::getPtr(cppValue)); |
| 1123 } | 1123 } |
| 1124 | 1124 |
| 1125 static void float32ArrayAttributeAttributeSetterCallback(v8::Local<v8::String>,
v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 1125 static void float32ArrayAttributeAttributeSetterCallback(v8::Local<v8::String>,
v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 1126 { | 1126 { |
| 1127 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 1127 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 1128 TestObjectPythonV8Internal::float32ArrayAttributeAttributeSetter(jsValue, in
fo); | 1128 TestObjectPythonV8Internal::float32ArrayAttributeAttributeSetter(jsValue, in
fo); |
| 1129 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1129 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1130 } | 1130 } |
| 1131 | 1131 |
| 1132 static void uint8ArrayAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8
::Value>& info) | 1132 static void uint8ArrayAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8
::Value>& info) |
| 1133 { | 1133 { |
| 1134 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1134 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1135 v8SetReturnValueFast(info, imp->uint8ArrayAttribute(), imp); | 1135 v8SetReturnValueFast(info, imp->uint8ArrayAttribute(), imp); |
| 1136 } | 1136 } |
| 1137 | 1137 |
| 1138 static void uint8ArrayAttributeAttributeGetterCallback(v8::Local<v8::String>, co
nst v8::PropertyCallbackInfo<v8::Value>& info) | 1138 static void uint8ArrayAttributeAttributeGetterCallback(v8::Local<v8::String>, co
nst v8::PropertyCallbackInfo<v8::Value>& info) |
| 1139 { | 1139 { |
| 1140 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 1140 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 1141 TestObjectPythonV8Internal::uint8ArrayAttributeAttributeGetter(info); | 1141 TestObjectPythonV8Internal::uint8ArrayAttributeAttributeGetter(info); |
| 1142 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1142 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1143 } | 1143 } |
| 1144 | 1144 |
| 1145 static void uint8ArrayAttributeAttributeSetter(v8::Local<v8::Value> jsValue, con
st v8::PropertyCallbackInfo<void>& info) | 1145 static void uint8ArrayAttributeAttributeSetter(v8::Local<v8::Value> jsValue, con
st v8::PropertyCallbackInfo<void>& info) |
| 1146 { | 1146 { |
| 1147 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1147 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1148 V8TRYCATCH_VOID(Uint8Array*, cppValue, jsValue->IsUint8Array() ? V8Uint8Arra
y::toNative(v8::Handle<v8::Uint8Array>::Cast(jsValue)) : 0); | 1148 V8TRYCATCH_VOID(Uint8Array*, cppValue, jsValue->IsUint8Array() ? V8Uint8Arra
y::toNative(v8::Handle<v8::Uint8Array>::Cast(jsValue)) : 0); |
| 1149 imp->setUint8ArrayAttribute(WTF::getPtr(cppValue)); | 1149 imp->setUint8ArrayAttribute(WTF::getPtr(cppValue)); |
| 1150 } | 1150 } |
| 1151 | 1151 |
| 1152 static void uint8ArrayAttributeAttributeSetterCallback(v8::Local<v8::String>, v8
::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 1152 static void uint8ArrayAttributeAttributeSetterCallback(v8::Local<v8::String>, v8
::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 1153 { | 1153 { |
| 1154 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 1154 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 1155 TestObjectPythonV8Internal::uint8ArrayAttributeAttributeSetter(jsValue, info
); | 1155 TestObjectPythonV8Internal::uint8ArrayAttributeAttributeSetter(jsValue, info
); |
| 1156 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1156 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1157 } | 1157 } |
| 1158 | 1158 |
| 1159 static void selfAttributeGetter(const v8::PropertyCallbackInfo<v8::Value>& info) | 1159 static void selfAttributeGetter(const v8::PropertyCallbackInfo<v8::Value>& info) |
| 1160 { | 1160 { |
| 1161 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1161 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1162 v8SetReturnValueFast(info, imp->self(), imp); | 1162 v8SetReturnValueFast(info, imp->self(), imp); |
| 1163 } | 1163 } |
| 1164 | 1164 |
| 1165 static void selfAttributeGetterCallback(v8::Local<v8::String>, const v8::Propert
yCallbackInfo<v8::Value>& info) | 1165 static void selfAttributeGetterCallback(v8::Local<v8::String>, const v8::Propert
yCallbackInfo<v8::Value>& info) |
| 1166 { | 1166 { |
| 1167 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 1167 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 1168 TestObjectPythonV8Internal::selfAttributeGetter(info); | 1168 TestObjectPythonV8Internal::selfAttributeGetter(info); |
| 1169 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1169 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1170 } | 1170 } |
| 1171 | 1171 |
| 1172 static void readonlyEventTargetAttributeAttributeGetter(const v8::PropertyCallba
ckInfo<v8::Value>& info) | 1172 static void readonlyEventTargetAttributeAttributeGetter(const v8::PropertyCallba
ckInfo<v8::Value>& info) |
| 1173 { | 1173 { |
| 1174 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1174 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1175 v8SetReturnValueFast(info, imp->readonlyEventTargetAttribute(), imp); | 1175 v8SetReturnValueFast(info, imp->readonlyEventTargetAttribute(), imp); |
| 1176 } | 1176 } |
| 1177 | 1177 |
| 1178 static void readonlyEventTargetAttributeAttributeGetterCallback(v8::Local<v8::St
ring>, const v8::PropertyCallbackInfo<v8::Value>& info) | 1178 static void readonlyEventTargetAttributeAttributeGetterCallback(v8::Local<v8::St
ring>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 1179 { | 1179 { |
| 1180 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 1180 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 1181 TestObjectPythonV8Internal::readonlyEventTargetAttributeAttributeGetter(info
); | 1181 TestObjectPythonV8Internal::readonlyEventTargetAttributeAttributeGetter(info
); |
| 1182 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1182 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1183 } | 1183 } |
| 1184 | 1184 |
| 1185 static void readonlyWindowAttributeAttributeGetter(const v8::PropertyCallbackInf
o<v8::Value>& info) | 1185 static void readonlyWindowAttributeAttributeGetter(const v8::PropertyCallbackInf
o<v8::Value>& info) |
| 1186 { | 1186 { |
| 1187 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1187 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1188 v8SetReturnValueFast(info, imp->readonlyWindowAttribute(), imp); | 1188 v8SetReturnValueFast(info, imp->readonlyWindowAttribute(), imp); |
| 1189 } | 1189 } |
| 1190 | 1190 |
| 1191 static void readonlyWindowAttributeAttributeGetterCallback(v8::Local<v8::String>
, const v8::PropertyCallbackInfo<v8::Value>& info) | 1191 static void readonlyWindowAttributeAttributeGetterCallback(v8::Local<v8::String>
, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 1192 { | 1192 { |
| 1193 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 1193 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 1194 TestObjectPythonV8Internal::readonlyWindowAttributeAttributeGetter(info); | 1194 TestObjectPythonV8Internal::readonlyWindowAttributeAttributeGetter(info); |
| 1195 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1195 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1196 } | 1196 } |
| 1197 | 1197 |
| 1198 static void htmlCollectionAttributeAttributeGetter(const v8::PropertyCallbackInf
o<v8::Value>& info) | 1198 static void htmlCollectionAttributeAttributeGetter(const v8::PropertyCallbackInf
o<v8::Value>& info) |
| 1199 { | 1199 { |
| 1200 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1200 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1201 v8SetReturnValueFast(info, imp->htmlCollectionAttribute(), imp); | 1201 v8SetReturnValueFast(info, imp->htmlCollectionAttribute(), imp); |
| 1202 } | 1202 } |
| 1203 | 1203 |
| 1204 static void htmlCollectionAttributeAttributeGetterCallback(v8::Local<v8::String>
, const v8::PropertyCallbackInfo<v8::Value>& info) | 1204 static void htmlCollectionAttributeAttributeGetterCallback(v8::Local<v8::String>
, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 1205 { | 1205 { |
| 1206 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 1206 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 1207 TestObjectPythonV8Internal::htmlCollectionAttributeAttributeGetter(info); | 1207 TestObjectPythonV8Internal::htmlCollectionAttributeAttributeGetter(info); |
| 1208 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1208 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1209 } | 1209 } |
| 1210 | 1210 |
| 1211 static void htmlElementAttributeAttributeGetter(const v8::PropertyCallbackInfo<v
8::Value>& info) | 1211 static void htmlElementAttributeAttributeGetter(const v8::PropertyCallbackInfo<v
8::Value>& info) |
| 1212 { | 1212 { |
| 1213 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1213 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1214 v8SetReturnValueFast(info, imp->htmlElementAttribute(), imp); | 1214 v8SetReturnValueFast(info, imp->htmlElementAttribute(), imp); |
| 1215 } | 1215 } |
| 1216 | 1216 |
| 1217 static void htmlElementAttributeAttributeGetterCallback(v8::Local<v8::String>, c
onst v8::PropertyCallbackInfo<v8::Value>& info) | 1217 static void htmlElementAttributeAttributeGetterCallback(v8::Local<v8::String>, c
onst v8::PropertyCallbackInfo<v8::Value>& info) |
| 1218 { | 1218 { |
| 1219 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 1219 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 1220 TestObjectPythonV8Internal::htmlElementAttributeAttributeGetter(info); | 1220 TestObjectPythonV8Internal::htmlElementAttributeAttributeGetter(info); |
| 1221 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1221 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1222 } | 1222 } |
| 1223 | 1223 |
| 1224 static void stringArrayAttributeAttributeGetter(const v8::PropertyCallbackInfo<v
8::Value>& info) | 1224 static void stringArrayAttributeAttributeGetter(const v8::PropertyCallbackInfo<v
8::Value>& info) |
| 1225 { | 1225 { |
| 1226 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1226 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1227 v8SetReturnValue(info, v8Array(imp->stringArrayAttribute(), info.GetIsolate(
))); | 1227 v8SetReturnValue(info, v8Array(imp->stringArrayAttribute(), info.GetIsolate(
))); |
| 1228 } | 1228 } |
| 1229 | 1229 |
| 1230 static void stringArrayAttributeAttributeGetterCallback(v8::Local<v8::String>, c
onst v8::PropertyCallbackInfo<v8::Value>& info) | 1230 static void stringArrayAttributeAttributeGetterCallback(v8::Local<v8::String>, c
onst v8::PropertyCallbackInfo<v8::Value>& info) |
| 1231 { | 1231 { |
| 1232 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 1232 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 1233 TestObjectPythonV8Internal::stringArrayAttributeAttributeGetter(info); | 1233 TestObjectPythonV8Internal::stringArrayAttributeAttributeGetter(info); |
| 1234 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1234 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1235 } | 1235 } |
| 1236 | 1236 |
| 1237 static void stringArrayAttributeAttributeSetter(v8::Local<v8::Value> jsValue, co
nst v8::PropertyCallbackInfo<void>& info) | 1237 static void stringArrayAttributeAttributeSetter(v8::Local<v8::Value> jsValue, co
nst v8::PropertyCallbackInfo<void>& info) |
| 1238 { | 1238 { |
| 1239 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1239 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1240 V8TRYCATCH_VOID(Vector<String>, cppValue, toNativeArray<String>(jsValue, 0,
info.GetIsolate())); | 1240 V8TRYCATCH_VOID(Vector<String>, cppValue, toNativeArray<String>(jsValue, 0,
info.GetIsolate())); |
| 1241 imp->setStringArrayAttribute(cppValue); | 1241 imp->setStringArrayAttribute(cppValue); |
| 1242 } | 1242 } |
| 1243 | 1243 |
| 1244 static void stringArrayAttributeAttributeSetterCallback(v8::Local<v8::String>, v
8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 1244 static void stringArrayAttributeAttributeSetterCallback(v8::Local<v8::String>, v
8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 1245 { | 1245 { |
| 1246 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 1246 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 1247 TestObjectPythonV8Internal::stringArrayAttributeAttributeSetter(jsValue, inf
o); | 1247 TestObjectPythonV8Internal::stringArrayAttributeAttributeSetter(jsValue, inf
o); |
| 1248 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1248 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1249 } | 1249 } |
| 1250 | 1250 |
| 1251 static void testInterfaceEmptyArrayAttributeAttributeGetter(const v8::PropertyCa
llbackInfo<v8::Value>& info) | 1251 static void testInterfaceEmptyArrayAttributeAttributeGetter(const v8::PropertyCa
llbackInfo<v8::Value>& info) |
| 1252 { | 1252 { |
| 1253 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1253 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1254 v8SetReturnValue(info, v8Array(imp->testInterfaceEmptyArrayAttribute(), info
.GetIsolate())); | 1254 v8SetReturnValue(info, v8Array(imp->testInterfaceEmptyArrayAttribute(), info
.GetIsolate())); |
| 1255 } | 1255 } |
| 1256 | 1256 |
| 1257 static void testInterfaceEmptyArrayAttributeAttributeGetterCallback(v8::Local<v8
::String>, const v8::PropertyCallbackInfo<v8::Value>& info) | 1257 static void testInterfaceEmptyArrayAttributeAttributeGetterCallback(v8::Local<v8
::String>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 1258 { | 1258 { |
| 1259 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 1259 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 1260 TestObjectPythonV8Internal::testInterfaceEmptyArrayAttributeAttributeGetter(
info); | 1260 TestObjectPythonV8Internal::testInterfaceEmptyArrayAttributeAttributeGetter(
info); |
| 1261 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1261 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1262 } | 1262 } |
| 1263 | 1263 |
| 1264 static void testInterfaceEmptyArrayAttributeAttributeSetter(v8::Local<v8::Value>
jsValue, const v8::PropertyCallbackInfo<void>& info) | 1264 static void testInterfaceEmptyArrayAttributeAttributeSetter(v8::Local<v8::Value>
jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 1265 { | 1265 { |
| 1266 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1266 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1267 V8TRYCATCH_VOID(Vector<RefPtr<TestInterfaceEmpty> >, cppValue, (toRefPtrNati
veArray<TestInterfaceEmpty, V8TestInterfaceEmpty>(jsValue, 0, info.GetIsolate())
)); | 1267 V8TRYCATCH_VOID(Vector<RefPtr<TestInterfaceEmpty> >, cppValue, (toRefPtrNati
veArray<TestInterfaceEmpty, V8TestInterfaceEmpty>(jsValue, 0, info.GetIsolate())
)); |
| 1268 imp->setTestInterfaceEmptyArrayAttribute(cppValue); | 1268 imp->setTestInterfaceEmptyArrayAttribute(cppValue); |
| 1269 } | 1269 } |
| 1270 | 1270 |
| 1271 static void testInterfaceEmptyArrayAttributeAttributeSetterCallback(v8::Local<v8
::String>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& i
nfo) | 1271 static void testInterfaceEmptyArrayAttributeAttributeSetterCallback(v8::Local<v8
::String>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& i
nfo) |
| 1272 { | 1272 { |
| 1273 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 1273 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 1274 TestObjectPythonV8Internal::testInterfaceEmptyArrayAttributeAttributeSetter(
jsValue, info); | 1274 TestObjectPythonV8Internal::testInterfaceEmptyArrayAttributeAttributeSetter(
jsValue, info); |
| 1275 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1275 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1276 } | 1276 } |
| 1277 | 1277 |
| 1278 static void floatArrayAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8
::Value>& info) | 1278 static void floatArrayAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8
::Value>& info) |
| 1279 { | 1279 { |
| 1280 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1280 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1281 v8SetReturnValue(info, v8Array(imp->floatArrayAttribute(), info.GetIsolate()
)); | 1281 v8SetReturnValue(info, v8Array(imp->floatArrayAttribute(), info.GetIsolate()
)); |
| 1282 } | 1282 } |
| 1283 | 1283 |
| 1284 static void floatArrayAttributeAttributeGetterCallback(v8::Local<v8::String>, co
nst v8::PropertyCallbackInfo<v8::Value>& info) | 1284 static void floatArrayAttributeAttributeGetterCallback(v8::Local<v8::String>, co
nst v8::PropertyCallbackInfo<v8::Value>& info) |
| 1285 { | 1285 { |
| 1286 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 1286 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 1287 TestObjectPythonV8Internal::floatArrayAttributeAttributeGetter(info); | 1287 TestObjectPythonV8Internal::floatArrayAttributeAttributeGetter(info); |
| 1288 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1288 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1289 } | 1289 } |
| 1290 | 1290 |
| 1291 static void floatArrayAttributeAttributeSetter(v8::Local<v8::Value> jsValue, con
st v8::PropertyCallbackInfo<void>& info) | 1291 static void floatArrayAttributeAttributeSetter(v8::Local<v8::Value> jsValue, con
st v8::PropertyCallbackInfo<void>& info) |
| 1292 { | 1292 { |
| 1293 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1293 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1294 V8TRYCATCH_VOID(Vector<float>, cppValue, toNativeArray<float>(jsValue, 0, in
fo.GetIsolate())); | 1294 V8TRYCATCH_VOID(Vector<float>, cppValue, toNativeArray<float>(jsValue, 0, in
fo.GetIsolate())); |
| 1295 imp->setFloatArrayAttribute(cppValue); | 1295 imp->setFloatArrayAttribute(cppValue); |
| 1296 } | 1296 } |
| 1297 | 1297 |
| 1298 static void floatArrayAttributeAttributeSetterCallback(v8::Local<v8::String>, v8
::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 1298 static void floatArrayAttributeAttributeSetterCallback(v8::Local<v8::String>, v8
::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 1299 { | 1299 { |
| 1300 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 1300 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 1301 TestObjectPythonV8Internal::floatArrayAttributeAttributeSetter(jsValue, info
); | 1301 TestObjectPythonV8Internal::floatArrayAttributeAttributeSetter(jsValue, info
); |
| 1302 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1302 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1303 } | 1303 } |
| 1304 | 1304 |
| 1305 static void nullableStringAttributeAttributeGetter(const v8::PropertyCallbackInf
o<v8::Value>& info) | 1305 static void nullableStringAttributeAttributeGetter(const v8::PropertyCallbackInf
o<v8::Value>& info) |
| 1306 { | 1306 { |
| 1307 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1307 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1308 bool isNull = false; | 1308 bool isNull = false; |
| 1309 String jsValue = imp->nullableStringAttribute(isNull); | 1309 String jsValue = imp->nullableStringAttribute(isNull); |
| 1310 if (isNull) { | 1310 if (isNull) { |
| 1311 v8SetReturnValueNull(info); | 1311 v8SetReturnValueNull(info); |
| 1312 return; | 1312 return; |
| 1313 } | 1313 } |
| 1314 v8SetReturnValueString(info, jsValue, info.GetIsolate()); | 1314 v8SetReturnValueString(info, jsValue, info.GetIsolate()); |
| 1315 } | 1315 } |
| 1316 | 1316 |
| 1317 static void nullableStringAttributeAttributeGetterCallback(v8::Local<v8::String>
, const v8::PropertyCallbackInfo<v8::Value>& info) | 1317 static void nullableStringAttributeAttributeGetterCallback(v8::Local<v8::String>
, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 1318 { | 1318 { |
| 1319 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 1319 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 1320 TestObjectPythonV8Internal::nullableStringAttributeAttributeGetter(info); | 1320 TestObjectPythonV8Internal::nullableStringAttributeAttributeGetter(info); |
| 1321 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1321 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1322 } | 1322 } |
| 1323 | 1323 |
| 1324 static void nullableStringAttributeAttributeSetter(v8::Local<v8::Value> jsValue,
const v8::PropertyCallbackInfo<void>& info) | 1324 static void nullableStringAttributeAttributeSetter(v8::Local<v8::Value> jsValue,
const v8::PropertyCallbackInfo<void>& info) |
| 1325 { | 1325 { |
| 1326 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1326 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1327 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, cppValue, jsValue); | 1327 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, cppValue, jsValue); |
| 1328 imp->setNullableStringAttribute(cppValue); | 1328 imp->setNullableStringAttribute(cppValue); |
| 1329 } | 1329 } |
| 1330 | 1330 |
| 1331 static void nullableStringAttributeAttributeSetterCallback(v8::Local<v8::String>
, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 1331 static void nullableStringAttributeAttributeSetterCallback(v8::Local<v8::String>
, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 1332 { | 1332 { |
| 1333 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 1333 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 1334 TestObjectPythonV8Internal::nullableStringAttributeAttributeSetter(jsValue,
info); | 1334 TestObjectPythonV8Internal::nullableStringAttributeAttributeSetter(jsValue,
info); |
| 1335 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1335 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1336 } | 1336 } |
| 1337 | 1337 |
| 1338 static void nullableLongAttributeAttributeGetter(const v8::PropertyCallbackInfo<
v8::Value>& info) | 1338 static void nullableLongAttributeAttributeGetter(const v8::PropertyCallbackInfo<
v8::Value>& info) |
| 1339 { | 1339 { |
| 1340 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1340 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1341 bool isNull = false; | 1341 bool isNull = false; |
| 1342 int jsValue = imp->nullableLongAttribute(isNull); | 1342 int jsValue = imp->nullableLongAttribute(isNull); |
| 1343 if (isNull) { | 1343 if (isNull) { |
| 1344 v8SetReturnValueNull(info); | 1344 v8SetReturnValueNull(info); |
| 1345 return; | 1345 return; |
| 1346 } | 1346 } |
| 1347 v8SetReturnValueInt(info, jsValue); | 1347 v8SetReturnValueInt(info, jsValue); |
| 1348 } | 1348 } |
| 1349 | 1349 |
| 1350 static void nullableLongAttributeAttributeGetterCallback(v8::Local<v8::String>,
const v8::PropertyCallbackInfo<v8::Value>& info) | 1350 static void nullableLongAttributeAttributeGetterCallback(v8::Local<v8::String>,
const v8::PropertyCallbackInfo<v8::Value>& info) |
| 1351 { | 1351 { |
| 1352 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 1352 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 1353 TestObjectPythonV8Internal::nullableLongAttributeAttributeGetter(info); | 1353 TestObjectPythonV8Internal::nullableLongAttributeAttributeGetter(info); |
| 1354 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1354 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1355 } | 1355 } |
| 1356 | 1356 |
| 1357 static void nullableLongAttributeAttributeSetter(v8::Local<v8::Value> jsValue, c
onst v8::PropertyCallbackInfo<void>& info) | 1357 static void nullableLongAttributeAttributeSetter(v8::Local<v8::Value> jsValue, c
onst v8::PropertyCallbackInfo<void>& info) |
| 1358 { | 1358 { |
| 1359 ExceptionState exceptionState(ExceptionState::SetterContext, "nullableLongAt
tribute", "TestObjectPython", info.Holder(), info.GetIsolate()); | 1359 ExceptionState exceptionState(ExceptionState::SetterContext, "nullableLongAt
tribute", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 1360 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1360 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1361 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); | 1361 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); |
| 1362 imp->setNullableLongAttribute(cppValue); | 1362 imp->setNullableLongAttribute(cppValue); |
| 1363 } | 1363 } |
| 1364 | 1364 |
| 1365 static void nullableLongAttributeAttributeSetterCallback(v8::Local<v8::String>,
v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 1365 static void nullableLongAttributeAttributeSetterCallback(v8::Local<v8::String>,
v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 1366 { | 1366 { |
| 1367 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 1367 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 1368 TestObjectPythonV8Internal::nullableLongAttributeAttributeSetter(jsValue, in
fo); | 1368 TestObjectPythonV8Internal::nullableLongAttributeAttributeSetter(jsValue, in
fo); |
| 1369 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1369 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1370 } | 1370 } |
| 1371 | 1371 |
| 1372 static void testEnumAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::
Value>& info) | 1372 static void testEnumAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::
Value>& info) |
| 1373 { | 1373 { |
| 1374 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1374 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1375 v8SetReturnValueString(info, imp->testEnumAttribute(), info.GetIsolate()); | 1375 v8SetReturnValueString(info, imp->testEnumAttribute(), info.GetIsolate()); |
| 1376 } | 1376 } |
| 1377 | 1377 |
| 1378 static void testEnumAttributeAttributeGetterCallback(v8::Local<v8::String>, cons
t v8::PropertyCallbackInfo<v8::Value>& info) | 1378 static void testEnumAttributeAttributeGetterCallback(v8::Local<v8::String>, cons
t v8::PropertyCallbackInfo<v8::Value>& info) |
| 1379 { | 1379 { |
| 1380 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 1380 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 1381 TestObjectPythonV8Internal::testEnumAttributeAttributeGetter(info); | 1381 TestObjectPythonV8Internal::testEnumAttributeAttributeGetter(info); |
| 1382 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1382 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1383 } | 1383 } |
| 1384 | 1384 |
| 1385 static void testEnumAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const
v8::PropertyCallbackInfo<void>& info) | 1385 static void testEnumAttributeAttributeSetter(v8::Local<v8::Value> jsValue, const
v8::PropertyCallbackInfo<void>& info) |
| 1386 { | 1386 { |
| 1387 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1387 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1388 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, cppValue, jsValue); | 1388 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, cppValue, jsValue); |
| 1389 String string = cppValue; | 1389 String string = cppValue; |
| 1390 if (!(string == "" || string == "EnumValue1" || string == "EnumValue2" || st
ring == "EnumValue3")) | 1390 if (!(string == "" || string == "EnumValue1" || string == "EnumValue2" || st
ring == "EnumValue3")) |
| 1391 return; | 1391 return; |
| 1392 imp->setTestEnumAttribute(cppValue); | 1392 imp->setTestEnumAttribute(cppValue); |
| 1393 } | 1393 } |
| 1394 | 1394 |
| 1395 static void testEnumAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::
Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 1395 static void testEnumAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::
Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 1396 { | 1396 { |
| 1397 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 1397 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 1398 TestObjectPythonV8Internal::testEnumAttributeAttributeSetter(jsValue, info); | 1398 TestObjectPythonV8Internal::testEnumAttributeAttributeSetter(jsValue, info); |
| 1399 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1399 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1400 } | 1400 } |
| 1401 | 1401 |
| 1402 static void staticStringAttributeAttributeGetter(const v8::PropertyCallbackInfo<
v8::Value>& info) | 1402 static void staticStringAttributeAttributeGetter(const v8::PropertyCallbackInfo<
v8::Value>& info) |
| 1403 { | 1403 { |
| 1404 v8SetReturnValueString(info, TestObjectPython::staticStringAttribute(), info
.GetIsolate()); | 1404 v8SetReturnValueString(info, TestObjectPython::staticStringAttribute(), info
.GetIsolate()); |
| 1405 } | 1405 } |
| 1406 | 1406 |
| 1407 static void staticStringAttributeAttributeGetterCallback(v8::Local<v8::String>,
const v8::PropertyCallbackInfo<v8::Value>& info) | 1407 static void staticStringAttributeAttributeGetterCallback(v8::Local<v8::String>,
const v8::PropertyCallbackInfo<v8::Value>& info) |
| 1408 { | 1408 { |
| 1409 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 1409 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 1410 TestObjectPythonV8Internal::staticStringAttributeAttributeGetter(info); | 1410 TestObjectPythonV8Internal::staticStringAttributeAttributeGetter(info); |
| 1411 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1411 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1412 } | 1412 } |
| 1413 | 1413 |
| 1414 static void staticStringAttributeAttributeSetter(v8::Local<v8::Value> jsValue, c
onst v8::PropertyCallbackInfo<void>& info) | 1414 static void staticStringAttributeAttributeSetter(v8::Local<v8::Value> jsValue, c
onst v8::PropertyCallbackInfo<void>& info) |
| 1415 { | 1415 { |
| 1416 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, cppValue, jsValue); | 1416 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, cppValue, jsValue); |
| 1417 TestObjectPython::setStaticStringAttribute(cppValue); | 1417 TestObjectPython::setStaticStringAttribute(cppValue); |
| 1418 } | 1418 } |
| 1419 | 1419 |
| 1420 static void staticStringAttributeAttributeSetterCallback(v8::Local<v8::String>,
v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 1420 static void staticStringAttributeAttributeSetterCallback(v8::Local<v8::String>,
v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 1421 { | 1421 { |
| 1422 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 1422 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 1423 TestObjectPythonV8Internal::staticStringAttributeAttributeSetter(jsValue, in
fo); | 1423 TestObjectPythonV8Internal::staticStringAttributeAttributeSetter(jsValue, in
fo); |
| 1424 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1424 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1425 } | 1425 } |
| 1426 | 1426 |
| 1427 static void staticLongAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8
::Value>& info) | 1427 static void staticLongAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8
::Value>& info) |
| 1428 { | 1428 { |
| 1429 v8SetReturnValueInt(info, TestObjectPython::staticLongAttribute()); | 1429 v8SetReturnValueInt(info, TestObjectPython::staticLongAttribute()); |
| 1430 } | 1430 } |
| 1431 | 1431 |
| 1432 static void staticLongAttributeAttributeGetterCallback(v8::Local<v8::String>, co
nst v8::PropertyCallbackInfo<v8::Value>& info) | 1432 static void staticLongAttributeAttributeGetterCallback(v8::Local<v8::String>, co
nst v8::PropertyCallbackInfo<v8::Value>& info) |
| 1433 { | 1433 { |
| 1434 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 1434 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 1435 TestObjectPythonV8Internal::staticLongAttributeAttributeGetter(info); | 1435 TestObjectPythonV8Internal::staticLongAttributeAttributeGetter(info); |
| 1436 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1436 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1437 } | 1437 } |
| 1438 | 1438 |
| 1439 static void staticLongAttributeAttributeSetter(v8::Local<v8::Value> jsValue, con
st v8::PropertyCallbackInfo<void>& info) | 1439 static void staticLongAttributeAttributeSetter(v8::Local<v8::Value> jsValue, con
st v8::PropertyCallbackInfo<void>& info) |
| 1440 { | 1440 { |
| 1441 ExceptionState exceptionState(ExceptionState::SetterContext, "staticLongAttr
ibute", "TestObjectPython", info.Holder(), info.GetIsolate()); | 1441 ExceptionState exceptionState(ExceptionState::SetterContext, "staticLongAttr
ibute", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 1442 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); | 1442 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); |
| 1443 TestObjectPython::setStaticLongAttribute(cppValue); | 1443 TestObjectPython::setStaticLongAttribute(cppValue); |
| 1444 } | 1444 } |
| 1445 | 1445 |
| 1446 static void staticLongAttributeAttributeSetterCallback(v8::Local<v8::String>, v8
::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 1446 static void staticLongAttributeAttributeSetterCallback(v8::Local<v8::String>, v8
::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 1447 { | 1447 { |
| 1448 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 1448 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 1449 TestObjectPythonV8Internal::staticLongAttributeAttributeSetter(jsValue, info
); | 1449 TestObjectPythonV8Internal::staticLongAttributeAttributeSetter(jsValue, info
); |
| 1450 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1450 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1451 } | 1451 } |
| 1452 | 1452 |
| 1453 static void eventHandlerAttributeAttributeGetter(const v8::PropertyCallbackInfo<
v8::Value>& info) | 1453 static void eventHandlerAttributeAttributeGetter(const v8::PropertyCallbackInfo<
v8::Value>& info) |
| 1454 { | 1454 { |
| 1455 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1455 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1456 EventListener* jsValue = imp->eventHandlerAttribute(isolatedWorldForIsolate(
info.GetIsolate())); | 1456 EventListener* jsValue = imp->eventHandlerAttribute(isolatedWorldForIsolate(
info.GetIsolate())); |
| 1457 v8SetReturnValue(info, jsValue ? v8::Handle<v8::Value>(V8AbstractEventListen
er::cast(jsValue)->getListenerObject(imp->executionContext())) : v8::Handle<v8::
Value>(v8::Null(info.GetIsolate()))); | 1457 v8SetReturnValue(info, jsValue ? v8::Handle<v8::Value>(V8AbstractEventListen
er::cast(jsValue)->getListenerObject(imp->executionContext())) : v8::Handle<v8::
Value>(v8::Null(info.GetIsolate()))); |
| 1458 } | 1458 } |
| 1459 | 1459 |
| 1460 static void eventHandlerAttributeAttributeGetterCallback(v8::Local<v8::String>,
const v8::PropertyCallbackInfo<v8::Value>& info) | 1460 static void eventHandlerAttributeAttributeGetterCallback(v8::Local<v8::String>,
const v8::PropertyCallbackInfo<v8::Value>& info) |
| 1461 { | 1461 { |
| 1462 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 1462 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 1463 TestObjectPythonV8Internal::eventHandlerAttributeAttributeGetter(info); | 1463 TestObjectPythonV8Internal::eventHandlerAttributeAttributeGetter(info); |
| 1464 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1464 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1465 } | 1465 } |
| 1466 | 1466 |
| 1467 static void eventHandlerAttributeAttributeSetter(v8::Local<v8::Value> jsValue, c
onst v8::PropertyCallbackInfo<void>& info) | 1467 static void eventHandlerAttributeAttributeSetter(v8::Local<v8::Value> jsValue, c
onst v8::PropertyCallbackInfo<void>& info) |
| 1468 { | 1468 { |
| 1469 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1469 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1470 transferHiddenDependency(info.Holder(), imp->eventHandlerAttribute(isolatedW
orldForIsolate(info.GetIsolate())), jsValue, V8TestObjectPython::eventListenerCa
cheIndex, info.GetIsolate()); | 1470 transferHiddenDependency(info.Holder(), imp->eventHandlerAttribute(isolatedW
orldForIsolate(info.GetIsolate())), jsValue, V8TestObjectPython::eventListenerCa
cheIndex, info.GetIsolate()); |
| 1471 imp->setEventHandlerAttribute(V8EventListenerList::getEventListener(jsValue,
true, ListenerFindOrCreate), isolatedWorldForIsolate(info.GetIsolate())); | 1471 imp->setEventHandlerAttribute(V8EventListenerList::getEventListener(jsValue,
true, ListenerFindOrCreate), isolatedWorldForIsolate(info.GetIsolate())); |
| 1472 } | 1472 } |
| 1473 | 1473 |
| 1474 static void eventHandlerAttributeAttributeSetterCallback(v8::Local<v8::String>,
v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 1474 static void eventHandlerAttributeAttributeSetterCallback(v8::Local<v8::String>,
v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 1475 { | 1475 { |
| 1476 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 1476 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 1477 TestObjectPythonV8Internal::eventHandlerAttributeAttributeSetter(jsValue, in
fo); | 1477 TestObjectPythonV8Internal::eventHandlerAttributeAttributeSetter(jsValue, in
fo); |
| 1478 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1478 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1479 } | 1479 } |
| 1480 | 1480 |
| 1481 static void activityLoggingAccessForAllWorldsLongAttributeAttributeGetter(const
v8::PropertyCallbackInfo<v8::Value>& info) | 1481 static void activityLoggingAccessForAllWorldsLongAttributeAttributeGetter(const
v8::PropertyCallbackInfo<v8::Value>& info) |
| 1482 { | 1482 { |
| 1483 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1483 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1484 v8SetReturnValueInt(info, imp->activityLoggingAccessForAllWorldsLongAttribut
e()); | 1484 v8SetReturnValueInt(info, imp->activityLoggingAccessForAllWorldsLongAttribut
e()); |
| 1485 } | 1485 } |
| 1486 | 1486 |
| 1487 static void activityLoggingAccessForAllWorldsLongAttributeAttributeGetterCallbac
k(v8::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) | 1487 static void activityLoggingAccessForAllWorldsLongAttributeAttributeGetterCallbac
k(v8::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 1488 { | 1488 { |
| 1489 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 1489 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 1490 V8PerContextData* contextData = V8PerContextData::from(info.GetIsolate()->Ge
tCurrentContext()); | 1490 V8PerContextData* contextData = V8PerContextData::from(info.GetIsolate()->Ge
tCurrentContext()); |
| 1491 if (contextData && contextData->activityLogger()) | 1491 if (contextData && contextData->activityLogger()) |
| 1492 contextData->activityLogger()->log("TestObjectPython.activityLoggingAcce
ssForAllWorldsLongAttribute", 0, 0, "Getter"); | 1492 contextData->activityLogger()->log("TestObjectPython.activityLoggingAcce
ssForAllWorldsLongAttribute", 0, 0, "Getter"); |
| 1493 TestObjectPythonV8Internal::activityLoggingAccessForAllWorldsLongAttributeAt
tributeGetter(info); | 1493 TestObjectPythonV8Internal::activityLoggingAccessForAllWorldsLongAttributeAt
tributeGetter(info); |
| 1494 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1494 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1495 } | 1495 } |
| 1496 | 1496 |
| 1497 static void activityLoggingAccessForAllWorldsLongAttributeAttributeSetter(v8::Lo
cal<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 1497 static void activityLoggingAccessForAllWorldsLongAttributeAttributeSetter(v8::Lo
cal<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 1498 { | 1498 { |
| 1499 ExceptionState exceptionState(ExceptionState::SetterContext, "activityLoggin
gAccessForAllWorldsLongAttribute", "TestObjectPython", info.Holder(), info.GetIs
olate()); | 1499 ExceptionState exceptionState(ExceptionState::SetterContext, "activityLoggin
gAccessForAllWorldsLongAttribute", "TestObjectPython", info.Holder(), info.GetIs
olate()); |
| 1500 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1500 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1501 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); | 1501 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); |
| 1502 imp->setActivityLoggingAccessForAllWorldsLongAttribute(cppValue); | 1502 imp->setActivityLoggingAccessForAllWorldsLongAttribute(cppValue); |
| 1503 } | 1503 } |
| 1504 | 1504 |
| 1505 static void activityLoggingAccessForAllWorldsLongAttributeAttributeSetterCallbac
k(v8::Local<v8::String>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbac
kInfo<void>& info) | 1505 static void activityLoggingAccessForAllWorldsLongAttributeAttributeSetterCallbac
k(v8::Local<v8::String>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbac
kInfo<void>& info) |
| 1506 { | 1506 { |
| 1507 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 1507 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 1508 V8PerContextData* contextData = V8PerContextData::from(info.GetIsolate()->Ge
tCurrentContext()); | 1508 V8PerContextData* contextData = V8PerContextData::from(info.GetIsolate()->Ge
tCurrentContext()); |
| 1509 if (contextData && contextData->activityLogger()) { | 1509 if (contextData && contextData->activityLogger()) { |
| 1510 v8::Handle<v8::Value> loggerArg[] = { jsValue }; | 1510 v8::Handle<v8::Value> loggerArg[] = { jsValue }; |
| 1511 contextData->activityLogger()->log("TestObjectPython.activityLoggingAcce
ssForAllWorldsLongAttribute", 1, &loggerArg[0], "Setter"); | 1511 contextData->activityLogger()->log("TestObjectPython.activityLoggingAcce
ssForAllWorldsLongAttribute", 1, &loggerArg[0], "Setter"); |
| 1512 } | 1512 } |
| 1513 TestObjectPythonV8Internal::activityLoggingAccessForAllWorldsLongAttributeAt
tributeSetter(jsValue, info); | 1513 TestObjectPythonV8Internal::activityLoggingAccessForAllWorldsLongAttributeAt
tributeSetter(jsValue, info); |
| 1514 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1514 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1515 } | 1515 } |
| 1516 | 1516 |
| 1517 static void activityLoggingGetterForAllWorldsLongAttributeAttributeGetter(const
v8::PropertyCallbackInfo<v8::Value>& info) | 1517 static void activityLoggingGetterForAllWorldsLongAttributeAttributeGetter(const
v8::PropertyCallbackInfo<v8::Value>& info) |
| 1518 { | 1518 { |
| 1519 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1519 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1520 v8SetReturnValueInt(info, imp->activityLoggingGetterForAllWorldsLongAttribut
e()); | 1520 v8SetReturnValueInt(info, imp->activityLoggingGetterForAllWorldsLongAttribut
e()); |
| 1521 } | 1521 } |
| 1522 | 1522 |
| 1523 static void activityLoggingGetterForAllWorldsLongAttributeAttributeGetterCallbac
k(v8::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) | 1523 static void activityLoggingGetterForAllWorldsLongAttributeAttributeGetterCallbac
k(v8::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 1524 { | 1524 { |
| 1525 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 1525 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 1526 V8PerContextData* contextData = V8PerContextData::from(info.GetIsolate()->Ge
tCurrentContext()); | 1526 V8PerContextData* contextData = V8PerContextData::from(info.GetIsolate()->Ge
tCurrentContext()); |
| 1527 if (contextData && contextData->activityLogger()) | 1527 if (contextData && contextData->activityLogger()) |
| 1528 contextData->activityLogger()->log("TestObjectPython.activityLoggingGett
erForAllWorldsLongAttribute", 0, 0, "Getter"); | 1528 contextData->activityLogger()->log("TestObjectPython.activityLoggingGett
erForAllWorldsLongAttribute", 0, 0, "Getter"); |
| 1529 TestObjectPythonV8Internal::activityLoggingGetterForAllWorldsLongAttributeAt
tributeGetter(info); | 1529 TestObjectPythonV8Internal::activityLoggingGetterForAllWorldsLongAttributeAt
tributeGetter(info); |
| 1530 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1530 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1531 } | 1531 } |
| 1532 | 1532 |
| 1533 static void activityLoggingGetterForAllWorldsLongAttributeAttributeSetter(v8::Lo
cal<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 1533 static void activityLoggingGetterForAllWorldsLongAttributeAttributeSetter(v8::Lo
cal<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 1534 { | 1534 { |
| 1535 ExceptionState exceptionState(ExceptionState::SetterContext, "activityLoggin
gGetterForAllWorldsLongAttribute", "TestObjectPython", info.Holder(), info.GetIs
olate()); | 1535 ExceptionState exceptionState(ExceptionState::SetterContext, "activityLoggin
gGetterForAllWorldsLongAttribute", "TestObjectPython", info.Holder(), info.GetIs
olate()); |
| 1536 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1536 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1537 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); | 1537 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); |
| 1538 imp->setActivityLoggingGetterForAllWorldsLongAttribute(cppValue); | 1538 imp->setActivityLoggingGetterForAllWorldsLongAttribute(cppValue); |
| 1539 } | 1539 } |
| 1540 | 1540 |
| 1541 static void activityLoggingGetterForAllWorldsLongAttributeAttributeSetterCallbac
k(v8::Local<v8::String>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbac
kInfo<void>& info) | 1541 static void activityLoggingGetterForAllWorldsLongAttributeAttributeSetterCallbac
k(v8::Local<v8::String>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbac
kInfo<void>& info) |
| 1542 { | 1542 { |
| 1543 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 1543 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 1544 TestObjectPythonV8Internal::activityLoggingGetterForAllWorldsLongAttributeAt
tributeSetter(jsValue, info); | 1544 TestObjectPythonV8Internal::activityLoggingGetterForAllWorldsLongAttributeAt
tributeSetter(jsValue, info); |
| 1545 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1545 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1546 } | 1546 } |
| 1547 | 1547 |
| 1548 static void activityLoggingSetterForAllWorldsLongAttributeAttributeGetter(const
v8::PropertyCallbackInfo<v8::Value>& info) | 1548 static void activityLoggingSetterForAllWorldsLongAttributeAttributeGetter(const
v8::PropertyCallbackInfo<v8::Value>& info) |
| 1549 { | 1549 { |
| 1550 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1550 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1551 v8SetReturnValueInt(info, imp->activityLoggingSetterForAllWorldsLongAttribut
e()); | 1551 v8SetReturnValueInt(info, imp->activityLoggingSetterForAllWorldsLongAttribut
e()); |
| 1552 } | 1552 } |
| 1553 | 1553 |
| 1554 static void activityLoggingSetterForAllWorldsLongAttributeAttributeGetterCallbac
k(v8::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) | 1554 static void activityLoggingSetterForAllWorldsLongAttributeAttributeGetterCallbac
k(v8::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 1555 { | 1555 { |
| 1556 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 1556 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 1557 TestObjectPythonV8Internal::activityLoggingSetterForAllWorldsLongAttributeAt
tributeGetter(info); | 1557 TestObjectPythonV8Internal::activityLoggingSetterForAllWorldsLongAttributeAt
tributeGetter(info); |
| 1558 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1558 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1559 } | 1559 } |
| 1560 | 1560 |
| 1561 static void activityLoggingSetterForAllWorldsLongAttributeAttributeSetter(v8::Lo
cal<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 1561 static void activityLoggingSetterForAllWorldsLongAttributeAttributeSetter(v8::Lo
cal<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 1562 { | 1562 { |
| 1563 ExceptionState exceptionState(ExceptionState::SetterContext, "activityLoggin
gSetterForAllWorldsLongAttribute", "TestObjectPython", info.Holder(), info.GetIs
olate()); | 1563 ExceptionState exceptionState(ExceptionState::SetterContext, "activityLoggin
gSetterForAllWorldsLongAttribute", "TestObjectPython", info.Holder(), info.GetIs
olate()); |
| 1564 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1564 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1565 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); | 1565 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); |
| 1566 imp->setActivityLoggingSetterForAllWorldsLongAttribute(cppValue); | 1566 imp->setActivityLoggingSetterForAllWorldsLongAttribute(cppValue); |
| 1567 } | 1567 } |
| 1568 | 1568 |
| 1569 static void activityLoggingSetterForAllWorldsLongAttributeAttributeSetterCallbac
k(v8::Local<v8::String>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbac
kInfo<void>& info) | 1569 static void activityLoggingSetterForAllWorldsLongAttributeAttributeSetterCallbac
k(v8::Local<v8::String>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbac
kInfo<void>& info) |
| 1570 { | 1570 { |
| 1571 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 1571 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 1572 V8PerContextData* contextData = V8PerContextData::from(info.GetIsolate()->Ge
tCurrentContext()); | 1572 V8PerContextData* contextData = V8PerContextData::from(info.GetIsolate()->Ge
tCurrentContext()); |
| 1573 if (contextData && contextData->activityLogger()) { | 1573 if (contextData && contextData->activityLogger()) { |
| 1574 v8::Handle<v8::Value> loggerArg[] = { jsValue }; | 1574 v8::Handle<v8::Value> loggerArg[] = { jsValue }; |
| 1575 contextData->activityLogger()->log("TestObjectPython.activityLoggingSett
erForAllWorldsLongAttribute", 1, &loggerArg[0], "Setter"); | 1575 contextData->activityLogger()->log("TestObjectPython.activityLoggingSett
erForAllWorldsLongAttribute", 1, &loggerArg[0], "Setter"); |
| 1576 } | 1576 } |
| 1577 TestObjectPythonV8Internal::activityLoggingSetterForAllWorldsLongAttributeAt
tributeSetter(jsValue, info); | 1577 TestObjectPythonV8Internal::activityLoggingSetterForAllWorldsLongAttributeAt
tributeSetter(jsValue, info); |
| 1578 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1578 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1579 } | 1579 } |
| 1580 | 1580 |
| 1581 static void cachedAttributeAnyAttributeAttributeGetter(const v8::PropertyCallbac
kInfo<v8::Value>& info) | 1581 static void cachedAttributeAnyAttributeAttributeGetter(const v8::PropertyCallbac
kInfo<v8::Value>& info) |
| 1582 { | 1582 { |
| 1583 v8::Handle<v8::String> propertyName = v8AtomicString(info.GetIsolate(), "cac
hedAttributeAnyAttribute"); | 1583 v8::Handle<v8::String> propertyName = v8AtomicString(info.GetIsolate(), "cac
hedAttributeAnyAttribute"); |
| 1584 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1584 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1585 if (!imp->isValueDirty()) { | 1585 if (!imp->isValueDirty()) { |
| 1586 v8::Handle<v8::Value> jsValue = info.Holder()->GetHiddenValue(propertyNa
me); | 1586 v8::Handle<v8::Value> jsValue = info.Holder()->GetHiddenValue(propertyNa
me); |
| 1587 if (!jsValue.IsEmpty()) { | 1587 if (!jsValue.IsEmpty()) { |
| 1588 v8SetReturnValue(info, jsValue); | 1588 v8SetReturnValue(info, jsValue); |
| 1589 return; | 1589 return; |
| 1590 } | 1590 } |
| 1591 } | 1591 } |
| 1592 ScriptValue jsValue = imp->cachedAttributeAnyAttribute(); | 1592 ScriptValue jsValue = imp->cachedAttributeAnyAttribute(); |
| 1593 info.Holder()->SetHiddenValue(propertyName, jsValue.v8Value()); | 1593 info.Holder()->SetHiddenValue(propertyName, jsValue.v8Value()); |
| 1594 v8SetReturnValue(info, jsValue.v8Value()); | 1594 v8SetReturnValue(info, jsValue.v8Value()); |
| 1595 } | 1595 } |
| 1596 | 1596 |
| 1597 static void cachedAttributeAnyAttributeAttributeGetterCallback(v8::Local<v8::Str
ing>, const v8::PropertyCallbackInfo<v8::Value>& info) | 1597 static void cachedAttributeAnyAttributeAttributeGetterCallback(v8::Local<v8::Str
ing>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 1598 { | 1598 { |
| 1599 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 1599 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 1600 TestObjectPythonV8Internal::cachedAttributeAnyAttributeAttributeGetter(info)
; | 1600 TestObjectPythonV8Internal::cachedAttributeAnyAttributeAttributeGetter(info)
; |
| 1601 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1601 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1602 } | 1602 } |
| 1603 | 1603 |
| 1604 static void cachedAttributeAnyAttributeAttributeSetter(v8::Local<v8::Value> jsVa
lue, const v8::PropertyCallbackInfo<void>& info) | 1604 static void cachedAttributeAnyAttributeAttributeSetter(v8::Local<v8::Value> jsVa
lue, const v8::PropertyCallbackInfo<void>& info) |
| 1605 { | 1605 { |
| 1606 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1606 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1607 V8TRYCATCH_VOID(ScriptValue, cppValue, ScriptValue(jsValue, info.GetIsolate(
))); | 1607 V8TRYCATCH_VOID(ScriptValue, cppValue, ScriptValue(jsValue, info.GetIsolate(
))); |
| 1608 imp->setCachedAttributeAnyAttribute(cppValue); | 1608 imp->setCachedAttributeAnyAttribute(cppValue); |
| 1609 info.Holder()->DeleteHiddenValue(v8AtomicString(info.GetIsolate(), "cachedAt
tributeAnyAttribute")); // Invalidate the cached value. | 1609 info.Holder()->DeleteHiddenValue(v8AtomicString(info.GetIsolate(), "cachedAt
tributeAnyAttribute")); // Invalidate the cached value. |
| 1610 } | 1610 } |
| 1611 | 1611 |
| 1612 static void cachedAttributeAnyAttributeAttributeSetterCallback(v8::Local<v8::Str
ing>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 1612 static void cachedAttributeAnyAttributeAttributeSetterCallback(v8::Local<v8::Str
ing>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 1613 { | 1613 { |
| 1614 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 1614 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 1615 TestObjectPythonV8Internal::cachedAttributeAnyAttributeAttributeSetter(jsVal
ue, info); | 1615 TestObjectPythonV8Internal::cachedAttributeAnyAttributeAttributeSetter(jsVal
ue, info); |
| 1616 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1616 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1617 } | 1617 } |
| 1618 | 1618 |
| 1619 static void callWithExecutionContextAnyAttributeAttributeGetter(const v8::Proper
tyCallbackInfo<v8::Value>& info) | 1619 static void callWithExecutionContextAnyAttributeAttributeGetter(const v8::Proper
tyCallbackInfo<v8::Value>& info) |
| 1620 { | 1620 { |
| 1621 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1621 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1622 ExecutionContext* scriptContext = getExecutionContext(); | 1622 ExecutionContext* scriptContext = getExecutionContext(); |
| 1623 v8SetReturnValue(info, imp->callWithExecutionContextAnyAttribute(scriptConte
xt).v8Value()); | 1623 v8SetReturnValue(info, imp->callWithExecutionContextAnyAttribute(scriptConte
xt).v8Value()); |
| 1624 } | 1624 } |
| 1625 | 1625 |
| 1626 static void callWithExecutionContextAnyAttributeAttributeGetterCallback(v8::Loca
l<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) | 1626 static void callWithExecutionContextAnyAttributeAttributeGetterCallback(v8::Loca
l<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 1627 { | 1627 { |
| 1628 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 1628 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 1629 TestObjectPythonV8Internal::callWithExecutionContextAnyAttributeAttributeGet
ter(info); | 1629 TestObjectPythonV8Internal::callWithExecutionContextAnyAttributeAttributeGet
ter(info); |
| 1630 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1630 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1631 } | 1631 } |
| 1632 | 1632 |
| 1633 static void callWithExecutionContextAnyAttributeAttributeSetter(v8::Local<v8::Va
lue> jsValue, const v8::PropertyCallbackInfo<void>& info) | 1633 static void callWithExecutionContextAnyAttributeAttributeSetter(v8::Local<v8::Va
lue> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 1634 { | 1634 { |
| 1635 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1635 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1636 V8TRYCATCH_VOID(ScriptValue, cppValue, ScriptValue(jsValue, info.GetIsolate(
))); | 1636 V8TRYCATCH_VOID(ScriptValue, cppValue, ScriptValue(jsValue, info.GetIsolate(
))); |
| 1637 ExecutionContext* scriptContext = getExecutionContext(); | 1637 ExecutionContext* scriptContext = getExecutionContext(); |
| 1638 imp->setCallWithExecutionContextAnyAttribute(scriptContext, cppValue); | 1638 imp->setCallWithExecutionContextAnyAttribute(scriptContext, cppValue); |
| 1639 } | 1639 } |
| 1640 | 1640 |
| 1641 static void callWithExecutionContextAnyAttributeAttributeSetterCallback(v8::Loca
l<v8::String>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void
>& info) | 1641 static void callWithExecutionContextAnyAttributeAttributeSetterCallback(v8::Loca
l<v8::String>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void
>& info) |
| 1642 { | 1642 { |
| 1643 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 1643 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 1644 TestObjectPythonV8Internal::callWithExecutionContextAnyAttributeAttributeSet
ter(jsValue, info); | 1644 TestObjectPythonV8Internal::callWithExecutionContextAnyAttributeAttributeSet
ter(jsValue, info); |
| 1645 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1645 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1646 } | 1646 } |
| 1647 | 1647 |
| 1648 static void checkSecurityForNodeReadonlyDocumentAttributeAttributeGetter(const v
8::PropertyCallbackInfo<v8::Value>& info) | 1648 static void checkSecurityForNodeReadonlyDocumentAttributeAttributeGetter(const v
8::PropertyCallbackInfo<v8::Value>& info) |
| 1649 { | 1649 { |
| 1650 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1650 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1651 ExceptionState exceptionState(ExceptionState::GetterContext, "checkSecurityF
orNodeReadonlyDocumentAttribute", "TestObjectPython", info.Holder(), info.GetIso
late()); | 1651 ExceptionState exceptionState(ExceptionState::GetterContext, "checkSecurityF
orNodeReadonlyDocumentAttribute", "TestObjectPython", info.Holder(), info.GetIso
late()); |
| 1652 if (!BindingSecurity::shouldAllowAccessToNode(imp->checkSecurityForNodeReado
nlyDocumentAttribute(), exceptionState)) { | 1652 if (!BindingSecurity::shouldAllowAccessToNode(imp->checkSecurityForNodeReado
nlyDocumentAttribute(), exceptionState)) { |
| 1653 v8SetReturnValueNull(info); | 1653 v8SetReturnValueNull(info); |
| 1654 exceptionState.throwIfNeeded(); | 1654 exceptionState.throwIfNeeded(); |
| 1655 return; | 1655 return; |
| 1656 } | 1656 } |
| 1657 v8SetReturnValueFast(info, imp->checkSecurityForNodeReadonlyDocumentAttribut
e(), imp); | 1657 v8SetReturnValueFast(info, imp->checkSecurityForNodeReadonlyDocumentAttribut
e(), imp); |
| 1658 } | 1658 } |
| 1659 | 1659 |
| 1660 static void checkSecurityForNodeReadonlyDocumentAttributeAttributeGetterCallback
(v8::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) | 1660 static void checkSecurityForNodeReadonlyDocumentAttributeAttributeGetterCallback
(v8::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 1661 { | 1661 { |
| 1662 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 1662 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 1663 TestObjectPythonV8Internal::checkSecurityForNodeReadonlyDocumentAttributeAtt
ributeGetter(info); | 1663 TestObjectPythonV8Internal::checkSecurityForNodeReadonlyDocumentAttributeAtt
ributeGetter(info); |
| 1664 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1664 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1665 } | 1665 } |
| 1666 | 1666 |
| 1667 #if ENABLE(CONDITION) | 1667 #if ENABLE(CONDITION) |
| 1668 static void conditionalLongAttributeAttributeGetter(const v8::PropertyCallbackIn
fo<v8::Value>& info) | 1668 static void conditionalLongAttributeAttributeGetter(const v8::PropertyCallbackIn
fo<v8::Value>& info) |
| 1669 { | 1669 { |
| 1670 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1670 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1671 v8SetReturnValueInt(info, imp->conditionalLongAttribute()); | 1671 v8SetReturnValueInt(info, imp->conditionalLongAttribute()); |
| 1672 } | 1672 } |
| 1673 #endif // ENABLE(CONDITION) | 1673 #endif // ENABLE(CONDITION) |
| 1674 | 1674 |
| 1675 #if ENABLE(CONDITION) | 1675 #if ENABLE(CONDITION) |
| 1676 static void conditionalLongAttributeAttributeGetterCallback(v8::Local<v8::String
>, const v8::PropertyCallbackInfo<v8::Value>& info) | 1676 static void conditionalLongAttributeAttributeGetterCallback(v8::Local<v8::String
>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 1677 { | 1677 { |
| 1678 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 1678 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 1679 TestObjectPythonV8Internal::conditionalLongAttributeAttributeGetter(info); | 1679 TestObjectPythonV8Internal::conditionalLongAttributeAttributeGetter(info); |
| 1680 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1680 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1681 } | 1681 } |
| 1682 #endif // ENABLE(CONDITION) | 1682 #endif // ENABLE(CONDITION) |
| 1683 | 1683 |
| 1684 #if ENABLE(CONDITION) | 1684 #if ENABLE(CONDITION) |
| 1685 static void conditionalLongAttributeAttributeSetter(v8::Local<v8::Value> jsValue
, const v8::PropertyCallbackInfo<void>& info) | 1685 static void conditionalLongAttributeAttributeSetter(v8::Local<v8::Value> jsValue
, const v8::PropertyCallbackInfo<void>& info) |
| 1686 { | 1686 { |
| 1687 ExceptionState exceptionState(ExceptionState::SetterContext, "conditionalLon
gAttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); | 1687 ExceptionState exceptionState(ExceptionState::SetterContext, "conditionalLon
gAttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 1688 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1688 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1689 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); | 1689 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); |
| 1690 imp->setConditionalLongAttribute(cppValue); | 1690 imp->setConditionalLongAttribute(cppValue); |
| 1691 } | 1691 } |
| 1692 #endif // ENABLE(CONDITION) | 1692 #endif // ENABLE(CONDITION) |
| 1693 | 1693 |
| 1694 #if ENABLE(CONDITION) | 1694 #if ENABLE(CONDITION) |
| 1695 static void conditionalLongAttributeAttributeSetterCallback(v8::Local<v8::String
>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 1695 static void conditionalLongAttributeAttributeSetterCallback(v8::Local<v8::String
>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 1696 { | 1696 { |
| 1697 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 1697 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 1698 TestObjectPythonV8Internal::conditionalLongAttributeAttributeSetter(jsValue,
info); | 1698 TestObjectPythonV8Internal::conditionalLongAttributeAttributeSetter(jsValue,
info); |
| 1699 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1699 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1700 } | 1700 } |
| 1701 #endif // ENABLE(CONDITION) | 1701 #endif // ENABLE(CONDITION) |
| 1702 | 1702 |
| 1703 #if ENABLE(CONDITION_1) && ENABLE(CONDITION_2) | 1703 #if ENABLE(CONDITION_1) && ENABLE(CONDITION_2) |
| 1704 static void conditionalAndLongAttributeAttributeGetter(const v8::PropertyCallbac
kInfo<v8::Value>& info) | 1704 static void conditionalAndLongAttributeAttributeGetter(const v8::PropertyCallbac
kInfo<v8::Value>& info) |
| 1705 { | 1705 { |
| 1706 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1706 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1707 v8SetReturnValueInt(info, imp->conditionalAndLongAttribute()); | 1707 v8SetReturnValueInt(info, imp->conditionalAndLongAttribute()); |
| 1708 } | 1708 } |
| 1709 #endif // ENABLE(CONDITION_1) && ENABLE(CONDITION_2) | 1709 #endif // ENABLE(CONDITION_1) && ENABLE(CONDITION_2) |
| 1710 | 1710 |
| 1711 #if ENABLE(CONDITION_1) && ENABLE(CONDITION_2) | 1711 #if ENABLE(CONDITION_1) && ENABLE(CONDITION_2) |
| 1712 static void conditionalAndLongAttributeAttributeGetterCallback(v8::Local<v8::Str
ing>, const v8::PropertyCallbackInfo<v8::Value>& info) | 1712 static void conditionalAndLongAttributeAttributeGetterCallback(v8::Local<v8::Str
ing>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 1713 { | 1713 { |
| 1714 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 1714 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 1715 TestObjectPythonV8Internal::conditionalAndLongAttributeAttributeGetter(info)
; | 1715 TestObjectPythonV8Internal::conditionalAndLongAttributeAttributeGetter(info)
; |
| 1716 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1716 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1717 } | 1717 } |
| 1718 #endif // ENABLE(CONDITION_1) && ENABLE(CONDITION_2) | 1718 #endif // ENABLE(CONDITION_1) && ENABLE(CONDITION_2) |
| 1719 | 1719 |
| 1720 #if ENABLE(CONDITION_1) && ENABLE(CONDITION_2) | 1720 #if ENABLE(CONDITION_1) && ENABLE(CONDITION_2) |
| 1721 static void conditionalAndLongAttributeAttributeSetter(v8::Local<v8::Value> jsVa
lue, const v8::PropertyCallbackInfo<void>& info) | 1721 static void conditionalAndLongAttributeAttributeSetter(v8::Local<v8::Value> jsVa
lue, const v8::PropertyCallbackInfo<void>& info) |
| 1722 { | 1722 { |
| 1723 ExceptionState exceptionState(ExceptionState::SetterContext, "conditionalAnd
LongAttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); | 1723 ExceptionState exceptionState(ExceptionState::SetterContext, "conditionalAnd
LongAttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 1724 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1724 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1725 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); | 1725 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); |
| 1726 imp->setConditionalAndLongAttribute(cppValue); | 1726 imp->setConditionalAndLongAttribute(cppValue); |
| 1727 } | 1727 } |
| 1728 #endif // ENABLE(CONDITION_1) && ENABLE(CONDITION_2) | 1728 #endif // ENABLE(CONDITION_1) && ENABLE(CONDITION_2) |
| 1729 | 1729 |
| 1730 #if ENABLE(CONDITION_1) && ENABLE(CONDITION_2) | 1730 #if ENABLE(CONDITION_1) && ENABLE(CONDITION_2) |
| 1731 static void conditionalAndLongAttributeAttributeSetterCallback(v8::Local<v8::Str
ing>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 1731 static void conditionalAndLongAttributeAttributeSetterCallback(v8::Local<v8::Str
ing>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 1732 { | 1732 { |
| 1733 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 1733 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 1734 TestObjectPythonV8Internal::conditionalAndLongAttributeAttributeSetter(jsVal
ue, info); | 1734 TestObjectPythonV8Internal::conditionalAndLongAttributeAttributeSetter(jsVal
ue, info); |
| 1735 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1735 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1736 } | 1736 } |
| 1737 #endif // ENABLE(CONDITION_1) && ENABLE(CONDITION_2) | 1737 #endif // ENABLE(CONDITION_1) && ENABLE(CONDITION_2) |
| 1738 | 1738 |
| 1739 #if ENABLE(CONDITION_1) || ENABLE(CONDITION_2) | 1739 #if ENABLE(CONDITION_1) || ENABLE(CONDITION_2) |
| 1740 static void conditionalOrLongAttributeAttributeGetter(const v8::PropertyCallback
Info<v8::Value>& info) | 1740 static void conditionalOrLongAttributeAttributeGetter(const v8::PropertyCallback
Info<v8::Value>& info) |
| 1741 { | 1741 { |
| 1742 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1742 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1743 v8SetReturnValueInt(info, imp->conditionalOrLongAttribute()); | 1743 v8SetReturnValueInt(info, imp->conditionalOrLongAttribute()); |
| 1744 } | 1744 } |
| 1745 #endif // ENABLE(CONDITION_1) || ENABLE(CONDITION_2) | 1745 #endif // ENABLE(CONDITION_1) || ENABLE(CONDITION_2) |
| 1746 | 1746 |
| 1747 #if ENABLE(CONDITION_1) || ENABLE(CONDITION_2) | 1747 #if ENABLE(CONDITION_1) || ENABLE(CONDITION_2) |
| 1748 static void conditionalOrLongAttributeAttributeGetterCallback(v8::Local<v8::Stri
ng>, const v8::PropertyCallbackInfo<v8::Value>& info) | 1748 static void conditionalOrLongAttributeAttributeGetterCallback(v8::Local<v8::Stri
ng>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 1749 { | 1749 { |
| 1750 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 1750 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 1751 TestObjectPythonV8Internal::conditionalOrLongAttributeAttributeGetter(info); | 1751 TestObjectPythonV8Internal::conditionalOrLongAttributeAttributeGetter(info); |
| 1752 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1752 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1753 } | 1753 } |
| 1754 #endif // ENABLE(CONDITION_1) || ENABLE(CONDITION_2) | 1754 #endif // ENABLE(CONDITION_1) || ENABLE(CONDITION_2) |
| 1755 | 1755 |
| 1756 #if ENABLE(CONDITION_1) || ENABLE(CONDITION_2) | 1756 #if ENABLE(CONDITION_1) || ENABLE(CONDITION_2) |
| 1757 static void conditionalOrLongAttributeAttributeSetter(v8::Local<v8::Value> jsVal
ue, const v8::PropertyCallbackInfo<void>& info) | 1757 static void conditionalOrLongAttributeAttributeSetter(v8::Local<v8::Value> jsVal
ue, const v8::PropertyCallbackInfo<void>& info) |
| 1758 { | 1758 { |
| 1759 ExceptionState exceptionState(ExceptionState::SetterContext, "conditionalOrL
ongAttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); | 1759 ExceptionState exceptionState(ExceptionState::SetterContext, "conditionalOrL
ongAttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 1760 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1760 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1761 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); | 1761 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); |
| 1762 imp->setConditionalOrLongAttribute(cppValue); | 1762 imp->setConditionalOrLongAttribute(cppValue); |
| 1763 } | 1763 } |
| 1764 #endif // ENABLE(CONDITION_1) || ENABLE(CONDITION_2) | 1764 #endif // ENABLE(CONDITION_1) || ENABLE(CONDITION_2) |
| 1765 | 1765 |
| 1766 #if ENABLE(CONDITION_1) || ENABLE(CONDITION_2) | 1766 #if ENABLE(CONDITION_1) || ENABLE(CONDITION_2) |
| 1767 static void conditionalOrLongAttributeAttributeSetterCallback(v8::Local<v8::Stri
ng>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 1767 static void conditionalOrLongAttributeAttributeSetterCallback(v8::Local<v8::Stri
ng>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 1768 { | 1768 { |
| 1769 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 1769 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 1770 TestObjectPythonV8Internal::conditionalOrLongAttributeAttributeSetter(jsValu
e, info); | 1770 TestObjectPythonV8Internal::conditionalOrLongAttributeAttributeSetter(jsValu
e, info); |
| 1771 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1771 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1772 } | 1772 } |
| 1773 #endif // ENABLE(CONDITION_1) || ENABLE(CONDITION_2) | 1773 #endif // ENABLE(CONDITION_1) || ENABLE(CONDITION_2) |
| 1774 | 1774 |
| 1775 static void customObjectAttributeAttributeGetterCallback(v8::Local<v8::String>,
const v8::PropertyCallbackInfo<v8::Value>& info) | 1775 static void customObjectAttributeAttributeGetterCallback(v8::Local<v8::String>,
const v8::PropertyCallbackInfo<v8::Value>& info) |
| 1776 { | 1776 { |
| 1777 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 1777 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 1778 V8TestObjectPython::customObjectAttributeAttributeGetterCustom(info); | 1778 V8TestObjectPython::customObjectAttributeAttributeGetterCustom(info); |
| 1779 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1779 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1780 } | 1780 } |
| 1781 | 1781 |
| 1782 static void customObjectAttributeAttributeSetterCallback(v8::Local<v8::String>,
v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 1782 static void customObjectAttributeAttributeSetterCallback(v8::Local<v8::String>,
v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 1783 { | 1783 { |
| 1784 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 1784 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 1785 V8TestObjectPython::customObjectAttributeAttributeSetterCustom(jsValue, info
); | 1785 V8TestObjectPython::customObjectAttributeAttributeSetterCustom(jsValue, info
); |
| 1786 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1786 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1787 } | 1787 } |
| 1788 | 1788 |
| 1789 static void customGetterLongAttributeAttributeGetterCallback(v8::Local<v8::Strin
g>, const v8::PropertyCallbackInfo<v8::Value>& info) | 1789 static void customGetterLongAttributeAttributeGetterCallback(v8::Local<v8::Strin
g>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 1790 { | 1790 { |
| 1791 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 1791 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 1792 V8TestObjectPython::customGetterLongAttributeAttributeGetterCustom(info); | 1792 V8TestObjectPython::customGetterLongAttributeAttributeGetterCustom(info); |
| 1793 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1793 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1794 } | 1794 } |
| 1795 | 1795 |
| 1796 static void customGetterLongAttributeAttributeSetter(v8::Local<v8::Value> jsValu
e, const v8::PropertyCallbackInfo<void>& info) | 1796 static void customGetterLongAttributeAttributeSetter(v8::Local<v8::Value> jsValu
e, const v8::PropertyCallbackInfo<void>& info) |
| 1797 { | 1797 { |
| 1798 ExceptionState exceptionState(ExceptionState::SetterContext, "customGetterLo
ngAttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); | 1798 ExceptionState exceptionState(ExceptionState::SetterContext, "customGetterLo
ngAttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 1799 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1799 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1800 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); | 1800 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); |
| 1801 imp->setCustomGetterLongAttribute(cppValue); | 1801 imp->setCustomGetterLongAttribute(cppValue); |
| 1802 } | 1802 } |
| 1803 | 1803 |
| 1804 static void customGetterLongAttributeAttributeSetterCallback(v8::Local<v8::Strin
g>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 1804 static void customGetterLongAttributeAttributeSetterCallback(v8::Local<v8::Strin
g>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 1805 { | 1805 { |
| 1806 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 1806 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 1807 TestObjectPythonV8Internal::customGetterLongAttributeAttributeSetter(jsValue
, info); | 1807 TestObjectPythonV8Internal::customGetterLongAttributeAttributeSetter(jsValue
, info); |
| 1808 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1808 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1809 } | 1809 } |
| 1810 | 1810 |
| 1811 static void customGetterReadonlyObjectAttributeAttributeGetterCallback(v8::Local
<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) | 1811 static void customGetterReadonlyObjectAttributeAttributeGetterCallback(v8::Local
<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 1812 { | 1812 { |
| 1813 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 1813 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 1814 V8TestObjectPython::customGetterReadonlyObjectAttributeAttributeGetterCustom
(info); | 1814 V8TestObjectPython::customGetterReadonlyObjectAttributeAttributeGetterCustom
(info); |
| 1815 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1815 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1816 } | 1816 } |
| 1817 | 1817 |
| 1818 static void customSetterLongAttributeAttributeGetter(const v8::PropertyCallbackI
nfo<v8::Value>& info) | 1818 static void customSetterLongAttributeAttributeGetter(const v8::PropertyCallbackI
nfo<v8::Value>& info) |
| 1819 { | 1819 { |
| 1820 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1820 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1821 v8SetReturnValueInt(info, imp->customSetterLongAttribute()); | 1821 v8SetReturnValueInt(info, imp->customSetterLongAttribute()); |
| 1822 } | 1822 } |
| 1823 | 1823 |
| 1824 static void customSetterLongAttributeAttributeGetterCallback(v8::Local<v8::Strin
g>, const v8::PropertyCallbackInfo<v8::Value>& info) | 1824 static void customSetterLongAttributeAttributeGetterCallback(v8::Local<v8::Strin
g>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 1825 { | 1825 { |
| 1826 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 1826 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 1827 TestObjectPythonV8Internal::customSetterLongAttributeAttributeGetter(info); | 1827 TestObjectPythonV8Internal::customSetterLongAttributeAttributeGetter(info); |
| 1828 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1828 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1829 } | 1829 } |
| 1830 | 1830 |
| 1831 static void customSetterLongAttributeAttributeSetterCallback(v8::Local<v8::Strin
g>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 1831 static void customSetterLongAttributeAttributeSetterCallback(v8::Local<v8::Strin
g>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 1832 { | 1832 { |
| 1833 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 1833 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 1834 V8TestObjectPython::customSetterLongAttributeAttributeSetterCustom(jsValue,
info); | 1834 V8TestObjectPython::customSetterLongAttributeAttributeSetterCustom(jsValue,
info); |
| 1835 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1835 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1836 } | 1836 } |
| 1837 | 1837 |
| 1838 #if ENABLE(CONDITION) | 1838 #if ENABLE(CONDITION) |
| 1839 static void customLongAttributeAttributeGetterCallback(v8::Local<v8::String>, co
nst v8::PropertyCallbackInfo<v8::Value>& info) | 1839 static void customLongAttributeAttributeGetterCallback(v8::Local<v8::String>, co
nst v8::PropertyCallbackInfo<v8::Value>& info) |
| 1840 { | 1840 { |
| 1841 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 1841 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 1842 V8TestObjectPython::customLongAttributeAttributeGetterCustom(info); | 1842 V8TestObjectPython::customLongAttributeAttributeGetterCustom(info); |
| 1843 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1843 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1844 } | 1844 } |
| 1845 #endif // ENABLE(CONDITION) | 1845 #endif // ENABLE(CONDITION) |
| 1846 | 1846 |
| 1847 #if ENABLE(CONDITION) | 1847 #if ENABLE(CONDITION) |
| 1848 static void customLongAttributeAttributeSetterCallback(v8::Local<v8::String>, v8
::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 1848 static void customLongAttributeAttributeSetterCallback(v8::Local<v8::String>, v8
::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 1849 { | 1849 { |
| 1850 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 1850 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 1851 V8TestObjectPython::customLongAttributeAttributeSetterCustom(jsValue, info); | 1851 V8TestObjectPython::customLongAttributeAttributeSetterCustom(jsValue, info); |
| 1852 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1852 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1853 } | 1853 } |
| 1854 #endif // ENABLE(CONDITION) | 1854 #endif // ENABLE(CONDITION) |
| 1855 | 1855 |
| 1856 static void customElementsCallbacksReadonlyLongAttributeAttributeGetter(const v8
::PropertyCallbackInfo<v8::Value>& info) | 1856 static void customElementsCallbacksReadonlyLongAttributeAttributeGetter(const v8
::PropertyCallbackInfo<v8::Value>& info) |
| 1857 { | 1857 { |
| 1858 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1858 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1859 v8SetReturnValueInt(info, imp->customElementsCallbacksReadonlyLongAttribute(
)); | 1859 v8SetReturnValueInt(info, imp->customElementsCallbacksReadonlyLongAttribute(
)); |
| 1860 } | 1860 } |
| 1861 | 1861 |
| 1862 static void customElementsCallbacksReadonlyLongAttributeAttributeGetterCallback(
v8::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) | 1862 static void customElementsCallbacksReadonlyLongAttributeAttributeGetterCallback(
v8::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 1863 { | 1863 { |
| 1864 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 1864 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 1865 TestObjectPythonV8Internal::customElementsCallbacksReadonlyLongAttributeAttr
ibuteGetter(info); | 1865 TestObjectPythonV8Internal::customElementsCallbacksReadonlyLongAttributeAttr
ibuteGetter(info); |
| 1866 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1866 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1867 } | 1867 } |
| 1868 | 1868 |
| 1869 static void deprecatedLongAttributeAttributeGetter(const v8::PropertyCallbackInf
o<v8::Value>& info) | 1869 static void deprecatedLongAttributeAttributeGetter(const v8::PropertyCallbackInf
o<v8::Value>& info) |
| 1870 { | 1870 { |
| 1871 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1871 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1872 v8SetReturnValueInt(info, imp->deprecatedLongAttribute()); | 1872 v8SetReturnValueInt(info, imp->deprecatedLongAttribute()); |
| 1873 } | 1873 } |
| 1874 | 1874 |
| 1875 static void deprecatedLongAttributeAttributeGetterCallback(v8::Local<v8::String>
, const v8::PropertyCallbackInfo<v8::Value>& info) | 1875 static void deprecatedLongAttributeAttributeGetterCallback(v8::Local<v8::String>
, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 1876 { | 1876 { |
| 1877 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 1877 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 1878 UseCounter::countDeprecation(activeExecutionContext(), UseCounter::LongAttri
bute); | 1878 UseCounter::countDeprecation(activeExecutionContext(), UseCounter::LongAttri
bute); |
| 1879 TestObjectPythonV8Internal::deprecatedLongAttributeAttributeGetter(info); | 1879 TestObjectPythonV8Internal::deprecatedLongAttributeAttributeGetter(info); |
| 1880 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1880 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1881 } | 1881 } |
| 1882 | 1882 |
| 1883 static void deprecatedLongAttributeAttributeSetter(v8::Local<v8::Value> jsValue,
const v8::PropertyCallbackInfo<void>& info) | 1883 static void deprecatedLongAttributeAttributeSetter(v8::Local<v8::Value> jsValue,
const v8::PropertyCallbackInfo<void>& info) |
| 1884 { | 1884 { |
| 1885 ExceptionState exceptionState(ExceptionState::SetterContext, "deprecatedLong
Attribute", "TestObjectPython", info.Holder(), info.GetIsolate()); | 1885 ExceptionState exceptionState(ExceptionState::SetterContext, "deprecatedLong
Attribute", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 1886 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1886 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1887 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); | 1887 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); |
| 1888 imp->setDeprecatedLongAttribute(cppValue); | 1888 imp->setDeprecatedLongAttribute(cppValue); |
| 1889 } | 1889 } |
| 1890 | 1890 |
| 1891 static void deprecatedLongAttributeAttributeSetterCallback(v8::Local<v8::String>
, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 1891 static void deprecatedLongAttributeAttributeSetterCallback(v8::Local<v8::String>
, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 1892 { | 1892 { |
| 1893 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 1893 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 1894 UseCounter::countDeprecation(activeExecutionContext(), UseCounter::LongAttri
bute); | 1894 UseCounter::countDeprecation(activeExecutionContext(), UseCounter::LongAttri
bute); |
| 1895 TestObjectPythonV8Internal::deprecatedLongAttributeAttributeSetter(jsValue,
info); | 1895 TestObjectPythonV8Internal::deprecatedLongAttributeAttributeSetter(jsValue,
info); |
| 1896 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1896 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1897 } | 1897 } |
| 1898 | 1898 |
| 1899 static void enforceRangeLongAttributeAttributeGetter(const v8::PropertyCallbackI
nfo<v8::Value>& info) | 1899 static void enforceRangeLongAttributeAttributeGetter(const v8::PropertyCallbackI
nfo<v8::Value>& info) |
| 1900 { | 1900 { |
| 1901 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1901 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1902 v8SetReturnValueInt(info, imp->enforceRangeLongAttribute()); | 1902 v8SetReturnValueInt(info, imp->enforceRangeLongAttribute()); |
| 1903 } | 1903 } |
| 1904 | 1904 |
| 1905 static void enforceRangeLongAttributeAttributeGetterCallback(v8::Local<v8::Strin
g>, const v8::PropertyCallbackInfo<v8::Value>& info) | 1905 static void enforceRangeLongAttributeAttributeGetterCallback(v8::Local<v8::Strin
g>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 1906 { | 1906 { |
| 1907 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 1907 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 1908 TestObjectPythonV8Internal::enforceRangeLongAttributeAttributeGetter(info); | 1908 TestObjectPythonV8Internal::enforceRangeLongAttributeAttributeGetter(info); |
| 1909 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1909 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1910 } | 1910 } |
| 1911 | 1911 |
| 1912 static void enforceRangeLongAttributeAttributeSetter(v8::Local<v8::Value> jsValu
e, const v8::PropertyCallbackInfo<void>& info) | 1912 static void enforceRangeLongAttributeAttributeSetter(v8::Local<v8::Value> jsValu
e, const v8::PropertyCallbackInfo<void>& info) |
| 1913 { | 1913 { |
| 1914 ExceptionState exceptionState(ExceptionState::SetterContext, "enforceRangeLo
ngAttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); | 1914 ExceptionState exceptionState(ExceptionState::SetterContext, "enforceRangeLo
ngAttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 1915 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1915 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1916 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, EnforceRange, exce
ptionState), exceptionState); | 1916 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, EnforceRange, exce
ptionState), exceptionState); |
| 1917 imp->setEnforceRangeLongAttribute(cppValue); | 1917 imp->setEnforceRangeLongAttribute(cppValue); |
| 1918 } | 1918 } |
| 1919 | 1919 |
| 1920 static void enforceRangeLongAttributeAttributeSetterCallback(v8::Local<v8::Strin
g>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 1920 static void enforceRangeLongAttributeAttributeSetterCallback(v8::Local<v8::Strin
g>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 1921 { | 1921 { |
| 1922 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 1922 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 1923 TestObjectPythonV8Internal::enforceRangeLongAttributeAttributeSetter(jsValue
, info); | 1923 TestObjectPythonV8Internal::enforceRangeLongAttributeAttributeSetter(jsValue
, info); |
| 1924 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1924 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1925 } | 1925 } |
| 1926 | 1926 |
| 1927 static void exposeJSAccessorsLongAttributeAttributeGetter(const v8::FunctionCall
backInfo<v8::Value>& info) | 1927 static void exposeJSAccessorsLongAttributeAttributeGetter(const v8::FunctionCall
backInfo<v8::Value>& info) |
| 1928 { | 1928 { |
| 1929 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1929 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1930 v8SetReturnValueInt(info, imp->exposeJSAccessorsLongAttribute()); | 1930 v8SetReturnValueInt(info, imp->exposeJSAccessorsLongAttribute()); |
| 1931 } | 1931 } |
| 1932 | 1932 |
| 1933 static void exposeJSAccessorsLongAttributeAttributeGetterCallback(const v8::Func
tionCallbackInfo<v8::Value>& info) | 1933 static void exposeJSAccessorsLongAttributeAttributeGetterCallback(const v8::Func
tionCallbackInfo<v8::Value>& info) |
| 1934 { | 1934 { |
| 1935 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 1935 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 1936 TestObjectPythonV8Internal::exposeJSAccessorsLongAttributeAttributeGetter(in
fo); | 1936 TestObjectPythonV8Internal::exposeJSAccessorsLongAttributeAttributeGetter(in
fo); |
| 1937 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1937 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1938 } | 1938 } |
| 1939 | 1939 |
| 1940 static void exposeJSAccessorsLongAttributeAttributeSetter(v8::Local<v8::Value> j
sValue, const v8::FunctionCallbackInfo<v8::Value>& info) | 1940 static void exposeJSAccessorsLongAttributeAttributeSetter(v8::Local<v8::Value> j
sValue, const v8::FunctionCallbackInfo<v8::Value>& info) |
| 1941 { | 1941 { |
| 1942 ExceptionState exceptionState(ExceptionState::SetterContext, "exposeJSAccess
orsLongAttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); | 1942 ExceptionState exceptionState(ExceptionState::SetterContext, "exposeJSAccess
orsLongAttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 1943 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1943 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1944 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); | 1944 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); |
| 1945 imp->setExposeJSAccessorsLongAttribute(cppValue); | 1945 imp->setExposeJSAccessorsLongAttribute(cppValue); |
| 1946 } | 1946 } |
| 1947 | 1947 |
| 1948 static void exposeJSAccessorsLongAttributeAttributeSetterCallback(const v8::Func
tionCallbackInfo<v8::Value>& info) | 1948 static void exposeJSAccessorsLongAttributeAttributeSetterCallback(const v8::Func
tionCallbackInfo<v8::Value>& info) |
| 1949 { | 1949 { |
| 1950 v8::Local<v8::Value> jsValue = info[0]; | 1950 v8::Local<v8::Value> jsValue = info[0]; |
| 1951 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 1951 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 1952 TestObjectPythonV8Internal::exposeJSAccessorsLongAttributeAttributeSetter(js
Value, info); | 1952 TestObjectPythonV8Internal::exposeJSAccessorsLongAttributeAttributeSetter(js
Value, info); |
| 1953 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1953 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1954 } | 1954 } |
| 1955 | 1955 |
| 1956 static void getterRaisesExceptionLongAttributeAttributeGetter(const v8::Property
CallbackInfo<v8::Value>& info) | 1956 static void getterRaisesExceptionLongAttributeAttributeGetter(const v8::Property
CallbackInfo<v8::Value>& info) |
| 1957 { | 1957 { |
| 1958 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1958 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1959 ExceptionState exceptionState(ExceptionState::GetterContext, "getterRaisesEx
ceptionLongAttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); | 1959 ExceptionState exceptionState(ExceptionState::GetterContext, "getterRaisesEx
ceptionLongAttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 1960 int jsValue = imp->getterRaisesExceptionLongAttribute(exceptionState); | 1960 int jsValue = imp->getterRaisesExceptionLongAttribute(exceptionState); |
| 1961 if (UNLIKELY(exceptionState.throwIfNeeded())) | 1961 if (UNLIKELY(exceptionState.throwIfNeeded())) |
| 1962 return; | 1962 return; |
| 1963 v8SetReturnValueInt(info, jsValue); | 1963 v8SetReturnValueInt(info, jsValue); |
| 1964 } | 1964 } |
| 1965 | 1965 |
| 1966 static void getterRaisesExceptionLongAttributeAttributeGetterCallback(v8::Local<
v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) | 1966 static void getterRaisesExceptionLongAttributeAttributeGetterCallback(v8::Local<
v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 1967 { | 1967 { |
| 1968 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 1968 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 1969 TestObjectPythonV8Internal::getterRaisesExceptionLongAttributeAttributeGette
r(info); | 1969 TestObjectPythonV8Internal::getterRaisesExceptionLongAttributeAttributeGette
r(info); |
| 1970 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1970 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1971 } | 1971 } |
| 1972 | 1972 |
| 1973 static void getterRaisesExceptionLongAttributeAttributeSetter(v8::Local<v8::Valu
e> jsValue, const v8::PropertyCallbackInfo<void>& info) | 1973 static void getterRaisesExceptionLongAttributeAttributeSetter(v8::Local<v8::Valu
e> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 1974 { | 1974 { |
| 1975 ExceptionState exceptionState(ExceptionState::SetterContext, "getterRaisesEx
ceptionLongAttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); | 1975 ExceptionState exceptionState(ExceptionState::SetterContext, "getterRaisesEx
ceptionLongAttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 1976 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1976 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1977 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); | 1977 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); |
| 1978 imp->setGetterRaisesExceptionLongAttribute(cppValue); | 1978 imp->setGetterRaisesExceptionLongAttribute(cppValue); |
| 1979 } | 1979 } |
| 1980 | 1980 |
| 1981 static void getterRaisesExceptionLongAttributeAttributeSetterCallback(v8::Local<
v8::String>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>&
info) | 1981 static void getterRaisesExceptionLongAttributeAttributeSetterCallback(v8::Local<
v8::String>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>&
info) |
| 1982 { | 1982 { |
| 1983 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 1983 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 1984 TestObjectPythonV8Internal::getterRaisesExceptionLongAttributeAttributeSette
r(jsValue, info); | 1984 TestObjectPythonV8Internal::getterRaisesExceptionLongAttributeAttributeSette
r(jsValue, info); |
| 1985 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1985 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1986 } | 1986 } |
| 1987 | 1987 |
| 1988 static void implementedAsLongAttributeAttributeGetter(const v8::PropertyCallback
Info<v8::Value>& info) | 1988 static void implementedAsLongAttributeAttributeGetter(const v8::PropertyCallback
Info<v8::Value>& info) |
| 1989 { | 1989 { |
| 1990 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 1990 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 1991 v8SetReturnValueInt(info, imp->implementedAsName()); | 1991 v8SetReturnValueInt(info, imp->implementedAsName()); |
| 1992 } | 1992 } |
| 1993 | 1993 |
| 1994 static void implementedAsLongAttributeAttributeGetterCallback(v8::Local<v8::Stri
ng>, const v8::PropertyCallbackInfo<v8::Value>& info) | 1994 static void implementedAsLongAttributeAttributeGetterCallback(v8::Local<v8::Stri
ng>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 1995 { | 1995 { |
| 1996 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 1996 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 1997 TestObjectPythonV8Internal::implementedAsLongAttributeAttributeGetter(info); | 1997 TestObjectPythonV8Internal::implementedAsLongAttributeAttributeGetter(info); |
| 1998 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 1998 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 1999 } | 1999 } |
| 2000 | 2000 |
| 2001 static void implementedAsLongAttributeAttributeSetter(v8::Local<v8::Value> jsVal
ue, const v8::PropertyCallbackInfo<void>& info) | 2001 static void implementedAsLongAttributeAttributeSetter(v8::Local<v8::Value> jsVal
ue, const v8::PropertyCallbackInfo<void>& info) |
| 2002 { | 2002 { |
| 2003 ExceptionState exceptionState(ExceptionState::SetterContext, "implementedAsL
ongAttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); | 2003 ExceptionState exceptionState(ExceptionState::SetterContext, "implementedAsL
ongAttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 2004 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2004 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2005 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); | 2005 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); |
| 2006 imp->setImplementedAsName(cppValue); | 2006 imp->setImplementedAsName(cppValue); |
| 2007 } | 2007 } |
| 2008 | 2008 |
| 2009 static void implementedAsLongAttributeAttributeSetterCallback(v8::Local<v8::Stri
ng>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 2009 static void implementedAsLongAttributeAttributeSetterCallback(v8::Local<v8::Stri
ng>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 2010 { | 2010 { |
| 2011 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 2011 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 2012 TestObjectPythonV8Internal::implementedAsLongAttributeAttributeSetter(jsValu
e, info); | 2012 TestObjectPythonV8Internal::implementedAsLongAttributeAttributeSetter(jsValu
e, info); |
| 2013 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2013 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2014 } | 2014 } |
| 2015 | 2015 |
| 2016 static void customImplementedAsLongAttributeAttributeGetterCallback(v8::Local<v8
::String>, const v8::PropertyCallbackInfo<v8::Value>& info) | 2016 static void customImplementedAsLongAttributeAttributeGetterCallback(v8::Local<v8
::String>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 2017 { | 2017 { |
| 2018 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 2018 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 2019 V8TestObjectPython::customImplementedAsLongAttributeAttributeGetterCustom(in
fo); | 2019 V8TestObjectPython::customImplementedAsLongAttributeAttributeGetterCustom(in
fo); |
| 2020 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2020 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2021 } | 2021 } |
| 2022 | 2022 |
| 2023 static void customImplementedAsLongAttributeAttributeSetterCallback(v8::Local<v8
::String>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& i
nfo) | 2023 static void customImplementedAsLongAttributeAttributeSetterCallback(v8::Local<v8
::String>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& i
nfo) |
| 2024 { | 2024 { |
| 2025 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 2025 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 2026 V8TestObjectPython::customImplementedAsLongAttributeAttributeSetterCustom(js
Value, info); | 2026 V8TestObjectPython::customImplementedAsLongAttributeAttributeSetterCustom(js
Value, info); |
| 2027 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2027 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2028 } | 2028 } |
| 2029 | 2029 |
| 2030 static void testInterfacePythonAttributeAttributeGetter(const v8::PropertyCallba
ckInfo<v8::Value>& info) | 2030 static void testInterfacePythonAttributeAttributeGetter(const v8::PropertyCallba
ckInfo<v8::Value>& info) |
| 2031 { | 2031 { |
| 2032 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2032 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2033 v8SetReturnValueFast(info, imp->testInterfacePythonAttribute(), imp); | 2033 v8SetReturnValueFast(info, imp->testInterfacePythonAttribute(), imp); |
| 2034 } | 2034 } |
| 2035 | 2035 |
| 2036 static void testInterfacePythonAttributeAttributeGetterCallback(v8::Local<v8::St
ring>, const v8::PropertyCallbackInfo<v8::Value>& info) | 2036 static void testInterfacePythonAttributeAttributeGetterCallback(v8::Local<v8::St
ring>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 2037 { | 2037 { |
| 2038 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 2038 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 2039 TestObjectPythonV8Internal::testInterfacePythonAttributeAttributeGetter(info
); | 2039 TestObjectPythonV8Internal::testInterfacePythonAttributeAttributeGetter(info
); |
| 2040 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2040 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2041 } | 2041 } |
| 2042 | 2042 |
| 2043 static void testInterfacePythonAttributeAttributeSetter(v8::Local<v8::Value> jsV
alue, const v8::PropertyCallbackInfo<void>& info) | 2043 static void testInterfacePythonAttributeAttributeSetter(v8::Local<v8::Value> jsV
alue, const v8::PropertyCallbackInfo<void>& info) |
| 2044 { | 2044 { |
| 2045 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2045 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2046 V8TRYCATCH_VOID(TestInterfacePythonImplementation*, cppValue, V8TestInterfac
ePython::hasInstance(jsValue, info.GetIsolate(), worldType(info.GetIsolate())) ?
V8TestInterfacePython::toNative(v8::Handle<v8::Object>::Cast(jsValue)) : 0); | 2046 V8TRYCATCH_VOID(TestInterfacePythonImplementation*, cppValue, V8TestInterfac
ePython::hasInstance(jsValue, info.GetIsolate(), worldType(info.GetIsolate())) ?
V8TestInterfacePython::toNative(v8::Handle<v8::Object>::Cast(jsValue)) : 0); |
| 2047 imp->setTestInterfacePythonAttribute(WTF::getPtr(cppValue)); | 2047 imp->setTestInterfacePythonAttribute(WTF::getPtr(cppValue)); |
| 2048 } | 2048 } |
| 2049 | 2049 |
| 2050 static void testInterfacePythonAttributeAttributeSetterCallback(v8::Local<v8::St
ring>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 2050 static void testInterfacePythonAttributeAttributeSetterCallback(v8::Local<v8::St
ring>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 2051 { | 2051 { |
| 2052 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 2052 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 2053 TestObjectPythonV8Internal::testInterfacePythonAttributeAttributeSetter(jsVa
lue, info); | 2053 TestObjectPythonV8Internal::testInterfacePythonAttributeAttributeSetter(jsVa
lue, info); |
| 2054 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2054 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2055 } | 2055 } |
| 2056 | 2056 |
| 2057 static void customGetterImplementedAsLongAttributeAttributeGetterCallback(v8::Lo
cal<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) | 2057 static void customGetterImplementedAsLongAttributeAttributeGetterCallback(v8::Lo
cal<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 2058 { | 2058 { |
| 2059 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 2059 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 2060 V8TestObjectPython::customGetterImplementedAsLongAttributeAttributeGetterCus
tom(info); | 2060 V8TestObjectPython::customGetterImplementedAsLongAttributeAttributeGetterCus
tom(info); |
| 2061 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2061 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2062 } | 2062 } |
| 2063 | 2063 |
| 2064 static void customGetterImplementedAsLongAttributeAttributeSetter(v8::Local<v8::
Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 2064 static void customGetterImplementedAsLongAttributeAttributeSetter(v8::Local<v8::
Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 2065 { | 2065 { |
| 2066 ExceptionState exceptionState(ExceptionState::SetterContext, "customGetterIm
plementedAsLongAttribute", "TestObjectPython", info.Holder(), info.GetIsolate())
; | 2066 ExceptionState exceptionState(ExceptionState::SetterContext, "customGetterIm
plementedAsLongAttribute", "TestObjectPython", info.Holder(), info.GetIsolate())
; |
| 2067 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2067 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2068 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); | 2068 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); |
| 2069 imp->setImplementedAsNameWithCustomGetter(cppValue); | 2069 imp->setImplementedAsNameWithCustomGetter(cppValue); |
| 2070 } | 2070 } |
| 2071 | 2071 |
| 2072 static void customGetterImplementedAsLongAttributeAttributeSetterCallback(v8::Lo
cal<v8::String>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<vo
id>& info) | 2072 static void customGetterImplementedAsLongAttributeAttributeSetterCallback(v8::Lo
cal<v8::String>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<vo
id>& info) |
| 2073 { | 2073 { |
| 2074 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 2074 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 2075 TestObjectPythonV8Internal::customGetterImplementedAsLongAttributeAttributeS
etter(jsValue, info); | 2075 TestObjectPythonV8Internal::customGetterImplementedAsLongAttributeAttributeS
etter(jsValue, info); |
| 2076 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2076 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2077 } | 2077 } |
| 2078 | 2078 |
| 2079 static void customSetterImplementedAsLongAttributeAttributeGetter(const v8::Prop
ertyCallbackInfo<v8::Value>& info) | 2079 static void customSetterImplementedAsLongAttributeAttributeGetter(const v8::Prop
ertyCallbackInfo<v8::Value>& info) |
| 2080 { | 2080 { |
| 2081 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2081 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2082 v8SetReturnValueInt(info, imp->implementedAsNameWithCustomGetter()); | 2082 v8SetReturnValueInt(info, imp->implementedAsNameWithCustomGetter()); |
| 2083 } | 2083 } |
| 2084 | 2084 |
| 2085 static void customSetterImplementedAsLongAttributeAttributeGetterCallback(v8::Lo
cal<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) | 2085 static void customSetterImplementedAsLongAttributeAttributeGetterCallback(v8::Lo
cal<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 2086 { | 2086 { |
| 2087 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 2087 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 2088 TestObjectPythonV8Internal::customSetterImplementedAsLongAttributeAttributeG
etter(info); | 2088 TestObjectPythonV8Internal::customSetterImplementedAsLongAttributeAttributeG
etter(info); |
| 2089 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2089 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2090 } | 2090 } |
| 2091 | 2091 |
| 2092 static void customSetterImplementedAsLongAttributeAttributeSetterCallback(v8::Lo
cal<v8::String>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<vo
id>& info) | 2092 static void customSetterImplementedAsLongAttributeAttributeSetterCallback(v8::Lo
cal<v8::String>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<vo
id>& info) |
| 2093 { | 2093 { |
| 2094 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 2094 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 2095 V8TestObjectPython::customSetterImplementedAsLongAttributeAttributeSetterCus
tom(jsValue, info); | 2095 V8TestObjectPython::customSetterImplementedAsLongAttributeAttributeSetterCus
tom(jsValue, info); |
| 2096 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2096 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2097 } | 2097 } |
| 2098 | 2098 |
| 2099 static void measureAsLongAttributeAttributeGetter(const v8::PropertyCallbackInfo
<v8::Value>& info) | 2099 static void measureAsLongAttributeAttributeGetter(const v8::PropertyCallbackInfo
<v8::Value>& info) |
| 2100 { | 2100 { |
| 2101 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2101 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2102 v8SetReturnValueInt(info, imp->measureAsLongAttribute()); | 2102 v8SetReturnValueInt(info, imp->measureAsLongAttribute()); |
| 2103 } | 2103 } |
| 2104 | 2104 |
| 2105 static void measureAsLongAttributeAttributeGetterCallback(v8::Local<v8::String>,
const v8::PropertyCallbackInfo<v8::Value>& info) | 2105 static void measureAsLongAttributeAttributeGetterCallback(v8::Local<v8::String>,
const v8::PropertyCallbackInfo<v8::Value>& info) |
| 2106 { | 2106 { |
| 2107 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 2107 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 2108 UseCounter::count(activeExecutionContext(), UseCounter::TestFeature); | 2108 UseCounter::count(activeExecutionContext(), UseCounter::TestFeature); |
| 2109 TestObjectPythonV8Internal::measureAsLongAttributeAttributeGetter(info); | 2109 TestObjectPythonV8Internal::measureAsLongAttributeAttributeGetter(info); |
| 2110 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2110 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2111 } | 2111 } |
| 2112 | 2112 |
| 2113 static void measureAsLongAttributeAttributeSetter(v8::Local<v8::Value> jsValue,
const v8::PropertyCallbackInfo<void>& info) | 2113 static void measureAsLongAttributeAttributeSetter(v8::Local<v8::Value> jsValue,
const v8::PropertyCallbackInfo<void>& info) |
| 2114 { | 2114 { |
| 2115 ExceptionState exceptionState(ExceptionState::SetterContext, "measureAsLongA
ttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); | 2115 ExceptionState exceptionState(ExceptionState::SetterContext, "measureAsLongA
ttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 2116 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2116 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2117 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); | 2117 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); |
| 2118 imp->setMeasureAsLongAttribute(cppValue); | 2118 imp->setMeasureAsLongAttribute(cppValue); |
| 2119 } | 2119 } |
| 2120 | 2120 |
| 2121 static void measureAsLongAttributeAttributeSetterCallback(v8::Local<v8::String>,
v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 2121 static void measureAsLongAttributeAttributeSetterCallback(v8::Local<v8::String>,
v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 2122 { | 2122 { |
| 2123 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 2123 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 2124 UseCounter::count(activeExecutionContext(), UseCounter::TestFeature); | 2124 UseCounter::count(activeExecutionContext(), UseCounter::TestFeature); |
| 2125 TestObjectPythonV8Internal::measureAsLongAttributeAttributeSetter(jsValue, i
nfo); | 2125 TestObjectPythonV8Internal::measureAsLongAttributeAttributeSetter(jsValue, i
nfo); |
| 2126 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2126 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2127 } | 2127 } |
| 2128 | 2128 |
| 2129 static void notEnumerableLongAttributeAttributeGetter(const v8::PropertyCallback
Info<v8::Value>& info) | 2129 static void notEnumerableLongAttributeAttributeGetter(const v8::PropertyCallback
Info<v8::Value>& info) |
| 2130 { | 2130 { |
| 2131 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2131 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2132 v8SetReturnValueInt(info, imp->notEnumerableLongAttribute()); | 2132 v8SetReturnValueInt(info, imp->notEnumerableLongAttribute()); |
| 2133 } | 2133 } |
| 2134 | 2134 |
| 2135 static void notEnumerableLongAttributeAttributeGetterCallback(v8::Local<v8::Stri
ng>, const v8::PropertyCallbackInfo<v8::Value>& info) | 2135 static void notEnumerableLongAttributeAttributeGetterCallback(v8::Local<v8::Stri
ng>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 2136 { | 2136 { |
| 2137 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 2137 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 2138 TestObjectPythonV8Internal::notEnumerableLongAttributeAttributeGetter(info); | 2138 TestObjectPythonV8Internal::notEnumerableLongAttributeAttributeGetter(info); |
| 2139 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2139 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2140 } | 2140 } |
| 2141 | 2141 |
| 2142 static void notEnumerableLongAttributeAttributeSetter(v8::Local<v8::Value> jsVal
ue, const v8::PropertyCallbackInfo<void>& info) | 2142 static void notEnumerableLongAttributeAttributeSetter(v8::Local<v8::Value> jsVal
ue, const v8::PropertyCallbackInfo<void>& info) |
| 2143 { | 2143 { |
| 2144 ExceptionState exceptionState(ExceptionState::SetterContext, "notEnumerableL
ongAttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); | 2144 ExceptionState exceptionState(ExceptionState::SetterContext, "notEnumerableL
ongAttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 2145 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2145 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2146 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); | 2146 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); |
| 2147 imp->setNotEnumerableLongAttribute(cppValue); | 2147 imp->setNotEnumerableLongAttribute(cppValue); |
| 2148 } | 2148 } |
| 2149 | 2149 |
| 2150 static void notEnumerableLongAttributeAttributeSetterCallback(v8::Local<v8::Stri
ng>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 2150 static void notEnumerableLongAttributeAttributeSetterCallback(v8::Local<v8::Stri
ng>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 2151 { | 2151 { |
| 2152 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 2152 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 2153 TestObjectPythonV8Internal::notEnumerableLongAttributeAttributeSetter(jsValu
e, info); | 2153 TestObjectPythonV8Internal::notEnumerableLongAttributeAttributeSetter(jsValu
e, info); |
| 2154 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2154 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2155 } | 2155 } |
| 2156 | 2156 |
| 2157 static void perContextEnabledLongAttributeAttributeGetter(const v8::PropertyCall
backInfo<v8::Value>& info) | 2157 static void perContextEnabledLongAttributeAttributeGetter(const v8::PropertyCall
backInfo<v8::Value>& info) |
| 2158 { | 2158 { |
| 2159 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2159 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2160 v8SetReturnValueInt(info, imp->perContextEnabledLongAttribute()); | 2160 v8SetReturnValueInt(info, imp->perContextEnabledLongAttribute()); |
| 2161 } | 2161 } |
| 2162 | 2162 |
| 2163 static void perContextEnabledLongAttributeAttributeGetterCallback(v8::Local<v8::
String>, const v8::PropertyCallbackInfo<v8::Value>& info) | 2163 static void perContextEnabledLongAttributeAttributeGetterCallback(v8::Local<v8::
String>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 2164 { | 2164 { |
| 2165 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 2165 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 2166 TestObjectPythonV8Internal::perContextEnabledLongAttributeAttributeGetter(in
fo); | 2166 TestObjectPythonV8Internal::perContextEnabledLongAttributeAttributeGetter(in
fo); |
| 2167 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2167 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2168 } | 2168 } |
| 2169 | 2169 |
| 2170 static void perContextEnabledLongAttributeAttributeSetter(v8::Local<v8::Value> j
sValue, const v8::PropertyCallbackInfo<void>& info) | 2170 static void perContextEnabledLongAttributeAttributeSetter(v8::Local<v8::Value> j
sValue, const v8::PropertyCallbackInfo<void>& info) |
| 2171 { | 2171 { |
| 2172 ExceptionState exceptionState(ExceptionState::SetterContext, "perContextEnab
ledLongAttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); | 2172 ExceptionState exceptionState(ExceptionState::SetterContext, "perContextEnab
ledLongAttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 2173 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2173 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2174 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); | 2174 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); |
| 2175 imp->setPerContextEnabledLongAttribute(cppValue); | 2175 imp->setPerContextEnabledLongAttribute(cppValue); |
| 2176 } | 2176 } |
| 2177 | 2177 |
| 2178 static void perContextEnabledLongAttributeAttributeSetterCallback(v8::Local<v8::
String>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& inf
o) | 2178 static void perContextEnabledLongAttributeAttributeSetterCallback(v8::Local<v8::
String>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& inf
o) |
| 2179 { | 2179 { |
| 2180 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 2180 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 2181 TestObjectPythonV8Internal::perContextEnabledLongAttributeAttributeSetter(js
Value, info); | 2181 TestObjectPythonV8Internal::perContextEnabledLongAttributeAttributeSetter(js
Value, info); |
| 2182 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2182 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2183 } | 2183 } |
| 2184 | 2184 |
| 2185 static void perWorldBindingsLongAttributeAttributeGetter(const v8::PropertyCallb
ackInfo<v8::Value>& info) | 2185 static void perWorldBindingsLongAttributeAttributeGetter(const v8::PropertyCallb
ackInfo<v8::Value>& info) |
| 2186 { | 2186 { |
| 2187 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2187 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2188 v8SetReturnValueInt(info, imp->perWorldBindingsLongAttribute()); | 2188 v8SetReturnValueInt(info, imp->perWorldBindingsLongAttribute()); |
| 2189 } | 2189 } |
| 2190 | 2190 |
| 2191 static void perWorldBindingsLongAttributeAttributeGetterCallback(v8::Local<v8::S
tring>, const v8::PropertyCallbackInfo<v8::Value>& info) | 2191 static void perWorldBindingsLongAttributeAttributeGetterCallback(v8::Local<v8::S
tring>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 2192 { | 2192 { |
| 2193 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 2193 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 2194 TestObjectPythonV8Internal::perWorldBindingsLongAttributeAttributeGetter(inf
o); | 2194 TestObjectPythonV8Internal::perWorldBindingsLongAttributeAttributeGetter(inf
o); |
| 2195 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2195 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2196 } | 2196 } |
| 2197 | 2197 |
| 2198 static void perWorldBindingsLongAttributeAttributeSetter(v8::Local<v8::Value> js
Value, const v8::PropertyCallbackInfo<void>& info) | 2198 static void perWorldBindingsLongAttributeAttributeSetter(v8::Local<v8::Value> js
Value, const v8::PropertyCallbackInfo<void>& info) |
| 2199 { | 2199 { |
| 2200 ExceptionState exceptionState(ExceptionState::SetterContext, "perWorldBindin
gsLongAttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); | 2200 ExceptionState exceptionState(ExceptionState::SetterContext, "perWorldBindin
gsLongAttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 2201 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2201 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2202 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); | 2202 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); |
| 2203 imp->setPerWorldBindingsLongAttribute(cppValue); | 2203 imp->setPerWorldBindingsLongAttribute(cppValue); |
| 2204 } | 2204 } |
| 2205 | 2205 |
| 2206 static void perWorldBindingsLongAttributeAttributeSetterCallback(v8::Local<v8::S
tring>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info
) | 2206 static void perWorldBindingsLongAttributeAttributeSetterCallback(v8::Local<v8::S
tring>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info
) |
| 2207 { | 2207 { |
| 2208 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 2208 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 2209 TestObjectPythonV8Internal::perWorldBindingsLongAttributeAttributeSetter(jsV
alue, info); | 2209 TestObjectPythonV8Internal::perWorldBindingsLongAttributeAttributeSetter(jsV
alue, info); |
| 2210 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2210 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2211 } | 2211 } |
| 2212 | 2212 |
| 2213 static void perWorldBindingsLongAttributeAttributeGetterForMainWorld(const v8::P
ropertyCallbackInfo<v8::Value>& info) | 2213 static void perWorldBindingsLongAttributeAttributeGetterForMainWorld(const v8::P
ropertyCallbackInfo<v8::Value>& info) |
| 2214 { | 2214 { |
| 2215 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2215 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2216 v8SetReturnValueInt(info, imp->perWorldBindingsLongAttribute()); | 2216 v8SetReturnValueInt(info, imp->perWorldBindingsLongAttribute()); |
| 2217 } | 2217 } |
| 2218 | 2218 |
| 2219 static void perWorldBindingsLongAttributeAttributeGetterCallbackForMainWorld(v8:
:Local<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) | 2219 static void perWorldBindingsLongAttributeAttributeGetterCallbackForMainWorld(v8:
:Local<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 2220 { | 2220 { |
| 2221 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 2221 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 2222 TestObjectPythonV8Internal::perWorldBindingsLongAttributeAttributeGetterForM
ainWorld(info); | 2222 TestObjectPythonV8Internal::perWorldBindingsLongAttributeAttributeGetterForM
ainWorld(info); |
| 2223 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2223 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2224 } | 2224 } |
| 2225 | 2225 |
| 2226 static void perWorldBindingsLongAttributeAttributeSetterForMainWorld(v8::Local<v
8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 2226 static void perWorldBindingsLongAttributeAttributeSetterForMainWorld(v8::Local<v
8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 2227 { | 2227 { |
| 2228 ExceptionState exceptionState(ExceptionState::SetterContext, "perWorldBindin
gsLongAttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); | 2228 ExceptionState exceptionState(ExceptionState::SetterContext, "perWorldBindin
gsLongAttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 2229 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2229 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2230 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); | 2230 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); |
| 2231 imp->setPerWorldBindingsLongAttribute(cppValue); | 2231 imp->setPerWorldBindingsLongAttribute(cppValue); |
| 2232 } | 2232 } |
| 2233 | 2233 |
| 2234 static void perWorldBindingsLongAttributeAttributeSetterCallbackForMainWorld(v8:
:Local<v8::String>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo
<void>& info) | 2234 static void perWorldBindingsLongAttributeAttributeSetterCallbackForMainWorld(v8:
:Local<v8::String>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo
<void>& info) |
| 2235 { | 2235 { |
| 2236 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 2236 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 2237 TestObjectPythonV8Internal::perWorldBindingsLongAttributeAttributeSetterForM
ainWorld(jsValue, info); | 2237 TestObjectPythonV8Internal::perWorldBindingsLongAttributeAttributeSetterForM
ainWorld(jsValue, info); |
| 2238 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2238 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2239 } | 2239 } |
| 2240 | 2240 |
| 2241 static void perWorldBindingsReadonlyLongAttributeAttributeGetter(const v8::Prope
rtyCallbackInfo<v8::Value>& info) | 2241 static void perWorldBindingsReadonlyLongAttributeAttributeGetter(const v8::Prope
rtyCallbackInfo<v8::Value>& info) |
| 2242 { | 2242 { |
| 2243 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2243 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2244 v8SetReturnValueInt(info, imp->perWorldBindingsReadonlyLongAttribute()); | 2244 v8SetReturnValueInt(info, imp->perWorldBindingsReadonlyLongAttribute()); |
| 2245 } | 2245 } |
| 2246 | 2246 |
| 2247 static void perWorldBindingsReadonlyLongAttributeAttributeGetterCallback(v8::Loc
al<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) | 2247 static void perWorldBindingsReadonlyLongAttributeAttributeGetterCallback(v8::Loc
al<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 2248 { | 2248 { |
| 2249 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 2249 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 2250 TestObjectPythonV8Internal::perWorldBindingsReadonlyLongAttributeAttributeGe
tter(info); | 2250 TestObjectPythonV8Internal::perWorldBindingsReadonlyLongAttributeAttributeGe
tter(info); |
| 2251 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2251 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2252 } | 2252 } |
| 2253 | 2253 |
| 2254 static void perWorldBindingsReadonlyLongAttributeAttributeGetterForMainWorld(con
st v8::PropertyCallbackInfo<v8::Value>& info) | 2254 static void perWorldBindingsReadonlyLongAttributeAttributeGetterForMainWorld(con
st v8::PropertyCallbackInfo<v8::Value>& info) |
| 2255 { | 2255 { |
| 2256 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2256 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2257 v8SetReturnValueInt(info, imp->perWorldBindingsReadonlyLongAttribute()); | 2257 v8SetReturnValueInt(info, imp->perWorldBindingsReadonlyLongAttribute()); |
| 2258 } | 2258 } |
| 2259 | 2259 |
| 2260 static void perWorldBindingsReadonlyLongAttributeAttributeGetterCallbackForMainW
orld(v8::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) | 2260 static void perWorldBindingsReadonlyLongAttributeAttributeGetterCallbackForMainW
orld(v8::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 2261 { | 2261 { |
| 2262 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 2262 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 2263 TestObjectPythonV8Internal::perWorldBindingsReadonlyLongAttributeAttributeGe
tterForMainWorld(info); | 2263 TestObjectPythonV8Internal::perWorldBindingsReadonlyLongAttributeAttributeGe
tterForMainWorld(info); |
| 2264 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2264 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2265 } | 2265 } |
| 2266 | 2266 |
| 2267 static void activityLoggingAccessPerWorldBindingsLongAttributeAttributeGetter(co
nst v8::PropertyCallbackInfo<v8::Value>& info) | 2267 static void activityLoggingAccessPerWorldBindingsLongAttributeAttributeGetter(co
nst v8::PropertyCallbackInfo<v8::Value>& info) |
| 2268 { | 2268 { |
| 2269 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2269 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2270 v8SetReturnValueInt(info, imp->activityLoggingAccessPerWorldBindingsLongAttr
ibute()); | 2270 v8SetReturnValueInt(info, imp->activityLoggingAccessPerWorldBindingsLongAttr
ibute()); |
| 2271 } | 2271 } |
| 2272 | 2272 |
| 2273 static void activityLoggingAccessPerWorldBindingsLongAttributeAttributeGetterCal
lback(v8::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) | 2273 static void activityLoggingAccessPerWorldBindingsLongAttributeAttributeGetterCal
lback(v8::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 2274 { | 2274 { |
| 2275 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 2275 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 2276 V8PerContextData* contextData = V8PerContextData::from(info.GetIsolate()->Ge
tCurrentContext()); | 2276 V8PerContextData* contextData = V8PerContextData::from(info.GetIsolate()->Ge
tCurrentContext()); |
| 2277 if (contextData && contextData->activityLogger()) | 2277 if (contextData && contextData->activityLogger()) |
| 2278 contextData->activityLogger()->log("TestObjectPython.activityLoggingAcce
ssPerWorldBindingsLongAttribute", 0, 0, "Getter"); | 2278 contextData->activityLogger()->log("TestObjectPython.activityLoggingAcce
ssPerWorldBindingsLongAttribute", 0, 0, "Getter"); |
| 2279 TestObjectPythonV8Internal::activityLoggingAccessPerWorldBindingsLongAttribu
teAttributeGetter(info); | 2279 TestObjectPythonV8Internal::activityLoggingAccessPerWorldBindingsLongAttribu
teAttributeGetter(info); |
| 2280 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2280 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2281 } | 2281 } |
| 2282 | 2282 |
| 2283 static void activityLoggingAccessPerWorldBindingsLongAttributeAttributeSetter(v8
::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 2283 static void activityLoggingAccessPerWorldBindingsLongAttributeAttributeSetter(v8
::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 2284 { | 2284 { |
| 2285 ExceptionState exceptionState(ExceptionState::SetterContext, "activityLoggin
gAccessPerWorldBindingsLongAttribute", "TestObjectPython", info.Holder(), info.G
etIsolate()); | 2285 ExceptionState exceptionState(ExceptionState::SetterContext, "activityLoggin
gAccessPerWorldBindingsLongAttribute", "TestObjectPython", info.Holder(), info.G
etIsolate()); |
| 2286 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2286 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2287 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); | 2287 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); |
| 2288 imp->setActivityLoggingAccessPerWorldBindingsLongAttribute(cppValue); | 2288 imp->setActivityLoggingAccessPerWorldBindingsLongAttribute(cppValue); |
| 2289 } | 2289 } |
| 2290 | 2290 |
| 2291 static void activityLoggingAccessPerWorldBindingsLongAttributeAttributeSetterCal
lback(v8::Local<v8::String>, v8::Local<v8::Value> jsValue, const v8::PropertyCal
lbackInfo<void>& info) | 2291 static void activityLoggingAccessPerWorldBindingsLongAttributeAttributeSetterCal
lback(v8::Local<v8::String>, v8::Local<v8::Value> jsValue, const v8::PropertyCal
lbackInfo<void>& info) |
| 2292 { | 2292 { |
| 2293 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 2293 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 2294 V8PerContextData* contextData = V8PerContextData::from(info.GetIsolate()->Ge
tCurrentContext()); | 2294 V8PerContextData* contextData = V8PerContextData::from(info.GetIsolate()->Ge
tCurrentContext()); |
| 2295 if (contextData && contextData->activityLogger()) { | 2295 if (contextData && contextData->activityLogger()) { |
| 2296 v8::Handle<v8::Value> loggerArg[] = { jsValue }; | 2296 v8::Handle<v8::Value> loggerArg[] = { jsValue }; |
| 2297 contextData->activityLogger()->log("TestObjectPython.activityLoggingAcce
ssPerWorldBindingsLongAttribute", 1, &loggerArg[0], "Setter"); | 2297 contextData->activityLogger()->log("TestObjectPython.activityLoggingAcce
ssPerWorldBindingsLongAttribute", 1, &loggerArg[0], "Setter"); |
| 2298 } | 2298 } |
| 2299 TestObjectPythonV8Internal::activityLoggingAccessPerWorldBindingsLongAttribu
teAttributeSetter(jsValue, info); | 2299 TestObjectPythonV8Internal::activityLoggingAccessPerWorldBindingsLongAttribu
teAttributeSetter(jsValue, info); |
| 2300 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2300 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2301 } | 2301 } |
| 2302 | 2302 |
| 2303 static void activityLoggingAccessPerWorldBindingsLongAttributeAttributeGetterFor
MainWorld(const v8::PropertyCallbackInfo<v8::Value>& info) | 2303 static void activityLoggingAccessPerWorldBindingsLongAttributeAttributeGetterFor
MainWorld(const v8::PropertyCallbackInfo<v8::Value>& info) |
| 2304 { | 2304 { |
| 2305 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2305 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2306 v8SetReturnValueInt(info, imp->activityLoggingAccessPerWorldBindingsLongAttr
ibute()); | 2306 v8SetReturnValueInt(info, imp->activityLoggingAccessPerWorldBindingsLongAttr
ibute()); |
| 2307 } | 2307 } |
| 2308 | 2308 |
| 2309 static void activityLoggingAccessPerWorldBindingsLongAttributeAttributeGetterCal
lbackForMainWorld(v8::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Valu
e>& info) | 2309 static void activityLoggingAccessPerWorldBindingsLongAttributeAttributeGetterCal
lbackForMainWorld(v8::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Valu
e>& info) |
| 2310 { | 2310 { |
| 2311 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 2311 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 2312 V8PerContextData* contextData = V8PerContextData::from(info.GetIsolate()->Ge
tCurrentContext()); | 2312 V8PerContextData* contextData = V8PerContextData::from(info.GetIsolate()->Ge
tCurrentContext()); |
| 2313 if (contextData && contextData->activityLogger()) | 2313 if (contextData && contextData->activityLogger()) |
| 2314 contextData->activityLogger()->log("TestObjectPython.activityLoggingAcce
ssPerWorldBindingsLongAttribute", 0, 0, "Getter"); | 2314 contextData->activityLogger()->log("TestObjectPython.activityLoggingAcce
ssPerWorldBindingsLongAttribute", 0, 0, "Getter"); |
| 2315 TestObjectPythonV8Internal::activityLoggingAccessPerWorldBindingsLongAttribu
teAttributeGetterForMainWorld(info); | 2315 TestObjectPythonV8Internal::activityLoggingAccessPerWorldBindingsLongAttribu
teAttributeGetterForMainWorld(info); |
| 2316 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2316 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2317 } | 2317 } |
| 2318 | 2318 |
| 2319 static void activityLoggingAccessPerWorldBindingsLongAttributeAttributeSetterFor
MainWorld(v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& in
fo) | 2319 static void activityLoggingAccessPerWorldBindingsLongAttributeAttributeSetterFor
MainWorld(v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& in
fo) |
| 2320 { | 2320 { |
| 2321 ExceptionState exceptionState(ExceptionState::SetterContext, "activityLoggin
gAccessPerWorldBindingsLongAttribute", "TestObjectPython", info.Holder(), info.G
etIsolate()); | 2321 ExceptionState exceptionState(ExceptionState::SetterContext, "activityLoggin
gAccessPerWorldBindingsLongAttribute", "TestObjectPython", info.Holder(), info.G
etIsolate()); |
| 2322 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2322 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2323 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); | 2323 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); |
| 2324 imp->setActivityLoggingAccessPerWorldBindingsLongAttribute(cppValue); | 2324 imp->setActivityLoggingAccessPerWorldBindingsLongAttribute(cppValue); |
| 2325 } | 2325 } |
| 2326 | 2326 |
| 2327 static void activityLoggingAccessPerWorldBindingsLongAttributeAttributeSetterCal
lbackForMainWorld(v8::Local<v8::String>, v8::Local<v8::Value> jsValue, const v8:
:PropertyCallbackInfo<void>& info) | 2327 static void activityLoggingAccessPerWorldBindingsLongAttributeAttributeSetterCal
lbackForMainWorld(v8::Local<v8::String>, v8::Local<v8::Value> jsValue, const v8:
:PropertyCallbackInfo<void>& info) |
| 2328 { | 2328 { |
| 2329 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 2329 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 2330 V8PerContextData* contextData = V8PerContextData::from(info.GetIsolate()->Ge
tCurrentContext()); | 2330 V8PerContextData* contextData = V8PerContextData::from(info.GetIsolate()->Ge
tCurrentContext()); |
| 2331 if (contextData && contextData->activityLogger()) { | 2331 if (contextData && contextData->activityLogger()) { |
| 2332 v8::Handle<v8::Value> loggerArg[] = { jsValue }; | 2332 v8::Handle<v8::Value> loggerArg[] = { jsValue }; |
| 2333 contextData->activityLogger()->log("TestObjectPython.activityLoggingAcce
ssPerWorldBindingsLongAttribute", 1, &loggerArg[0], "Setter"); | 2333 contextData->activityLogger()->log("TestObjectPython.activityLoggingAcce
ssPerWorldBindingsLongAttribute", 1, &loggerArg[0], "Setter"); |
| 2334 } | 2334 } |
| 2335 TestObjectPythonV8Internal::activityLoggingAccessPerWorldBindingsLongAttribu
teAttributeSetterForMainWorld(jsValue, info); | 2335 TestObjectPythonV8Internal::activityLoggingAccessPerWorldBindingsLongAttribu
teAttributeSetterForMainWorld(jsValue, info); |
| 2336 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2336 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2337 } | 2337 } |
| 2338 | 2338 |
| 2339 static void activityLoggingAccessForIsolatedWorldsPerWorldBindingsLongAttributeA
ttributeGetter(const v8::PropertyCallbackInfo<v8::Value>& info) | 2339 static void activityLoggingAccessForIsolatedWorldsPerWorldBindingsLongAttributeA
ttributeGetter(const v8::PropertyCallbackInfo<v8::Value>& info) |
| 2340 { | 2340 { |
| 2341 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2341 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2342 v8SetReturnValueInt(info, imp->activityLoggingAccessForIsolatedWorldsPerWorl
dBindingsLongAttribute()); | 2342 v8SetReturnValueInt(info, imp->activityLoggingAccessForIsolatedWorldsPerWorl
dBindingsLongAttribute()); |
| 2343 } | 2343 } |
| 2344 | 2344 |
| 2345 static void activityLoggingAccessForIsolatedWorldsPerWorldBindingsLongAttributeA
ttributeGetterCallback(v8::Local<v8::String>, const v8::PropertyCallbackInfo<v8:
:Value>& info) | 2345 static void activityLoggingAccessForIsolatedWorldsPerWorldBindingsLongAttributeA
ttributeGetterCallback(v8::Local<v8::String>, const v8::PropertyCallbackInfo<v8:
:Value>& info) |
| 2346 { | 2346 { |
| 2347 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 2347 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 2348 V8PerContextData* contextData = V8PerContextData::from(info.GetIsolate()->Ge
tCurrentContext()); | 2348 V8PerContextData* contextData = V8PerContextData::from(info.GetIsolate()->Ge
tCurrentContext()); |
| 2349 if (contextData && contextData->activityLogger()) | 2349 if (contextData && contextData->activityLogger()) |
| 2350 contextData->activityLogger()->log("TestObjectPython.activityLoggingAcce
ssForIsolatedWorldsPerWorldBindingsLongAttribute", 0, 0, "Getter"); | 2350 contextData->activityLogger()->log("TestObjectPython.activityLoggingAcce
ssForIsolatedWorldsPerWorldBindingsLongAttribute", 0, 0, "Getter"); |
| 2351 TestObjectPythonV8Internal::activityLoggingAccessForIsolatedWorldsPerWorldBi
ndingsLongAttributeAttributeGetter(info); | 2351 TestObjectPythonV8Internal::activityLoggingAccessForIsolatedWorldsPerWorldBi
ndingsLongAttributeAttributeGetter(info); |
| 2352 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2352 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2353 } | 2353 } |
| 2354 | 2354 |
| 2355 static void activityLoggingAccessForIsolatedWorldsPerWorldBindingsLongAttributeA
ttributeSetter(v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void
>& info) | 2355 static void activityLoggingAccessForIsolatedWorldsPerWorldBindingsLongAttributeA
ttributeSetter(v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void
>& info) |
| 2356 { | 2356 { |
| 2357 ExceptionState exceptionState(ExceptionState::SetterContext, "activityLoggin
gAccessForIsolatedWorldsPerWorldBindingsLongAttribute", "TestObjectPython", info
.Holder(), info.GetIsolate()); | 2357 ExceptionState exceptionState(ExceptionState::SetterContext, "activityLoggin
gAccessForIsolatedWorldsPerWorldBindingsLongAttribute", "TestObjectPython", info
.Holder(), info.GetIsolate()); |
| 2358 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2358 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2359 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); | 2359 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); |
| 2360 imp->setActivityLoggingAccessForIsolatedWorldsPerWorldBindingsLongAttribute(
cppValue); | 2360 imp->setActivityLoggingAccessForIsolatedWorldsPerWorldBindingsLongAttribute(
cppValue); |
| 2361 } | 2361 } |
| 2362 | 2362 |
| 2363 static void activityLoggingAccessForIsolatedWorldsPerWorldBindingsLongAttributeA
ttributeSetterCallback(v8::Local<v8::String>, v8::Local<v8::Value> jsValue, cons
t v8::PropertyCallbackInfo<void>& info) | 2363 static void activityLoggingAccessForIsolatedWorldsPerWorldBindingsLongAttributeA
ttributeSetterCallback(v8::Local<v8::String>, v8::Local<v8::Value> jsValue, cons
t v8::PropertyCallbackInfo<void>& info) |
| 2364 { | 2364 { |
| 2365 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 2365 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 2366 V8PerContextData* contextData = V8PerContextData::from(info.GetIsolate()->Ge
tCurrentContext()); | 2366 V8PerContextData* contextData = V8PerContextData::from(info.GetIsolate()->Ge
tCurrentContext()); |
| 2367 if (contextData && contextData->activityLogger()) { | 2367 if (contextData && contextData->activityLogger()) { |
| 2368 v8::Handle<v8::Value> loggerArg[] = { jsValue }; | 2368 v8::Handle<v8::Value> loggerArg[] = { jsValue }; |
| 2369 contextData->activityLogger()->log("TestObjectPython.activityLoggingAcce
ssForIsolatedWorldsPerWorldBindingsLongAttribute", 1, &loggerArg[0], "Setter"); | 2369 contextData->activityLogger()->log("TestObjectPython.activityLoggingAcce
ssForIsolatedWorldsPerWorldBindingsLongAttribute", 1, &loggerArg[0], "Setter"); |
| 2370 } | 2370 } |
| 2371 TestObjectPythonV8Internal::activityLoggingAccessForIsolatedWorldsPerWorldBi
ndingsLongAttributeAttributeSetter(jsValue, info); | 2371 TestObjectPythonV8Internal::activityLoggingAccessForIsolatedWorldsPerWorldBi
ndingsLongAttributeAttributeSetter(jsValue, info); |
| 2372 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2372 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2373 } | 2373 } |
| 2374 | 2374 |
| 2375 static void activityLoggingAccessForIsolatedWorldsPerWorldBindingsLongAttributeA
ttributeGetterForMainWorld(const v8::PropertyCallbackInfo<v8::Value>& info) | 2375 static void activityLoggingAccessForIsolatedWorldsPerWorldBindingsLongAttributeA
ttributeGetterForMainWorld(const v8::PropertyCallbackInfo<v8::Value>& info) |
| 2376 { | 2376 { |
| 2377 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2377 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2378 v8SetReturnValueInt(info, imp->activityLoggingAccessForIsolatedWorldsPerWorl
dBindingsLongAttribute()); | 2378 v8SetReturnValueInt(info, imp->activityLoggingAccessForIsolatedWorldsPerWorl
dBindingsLongAttribute()); |
| 2379 } | 2379 } |
| 2380 | 2380 |
| 2381 static void activityLoggingAccessForIsolatedWorldsPerWorldBindingsLongAttributeA
ttributeGetterCallbackForMainWorld(v8::Local<v8::String>, const v8::PropertyCall
backInfo<v8::Value>& info) | 2381 static void activityLoggingAccessForIsolatedWorldsPerWorldBindingsLongAttributeA
ttributeGetterCallbackForMainWorld(v8::Local<v8::String>, const v8::PropertyCall
backInfo<v8::Value>& info) |
| 2382 { | 2382 { |
| 2383 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 2383 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 2384 TestObjectPythonV8Internal::activityLoggingAccessForIsolatedWorldsPerWorldBi
ndingsLongAttributeAttributeGetterForMainWorld(info); | 2384 TestObjectPythonV8Internal::activityLoggingAccessForIsolatedWorldsPerWorldBi
ndingsLongAttributeAttributeGetterForMainWorld(info); |
| 2385 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2385 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2386 } | 2386 } |
| 2387 | 2387 |
| 2388 static void activityLoggingAccessForIsolatedWorldsPerWorldBindingsLongAttributeA
ttributeSetterForMainWorld(v8::Local<v8::Value> jsValue, const v8::PropertyCallb
ackInfo<void>& info) | 2388 static void activityLoggingAccessForIsolatedWorldsPerWorldBindingsLongAttributeA
ttributeSetterForMainWorld(v8::Local<v8::Value> jsValue, const v8::PropertyCallb
ackInfo<void>& info) |
| 2389 { | 2389 { |
| 2390 ExceptionState exceptionState(ExceptionState::SetterContext, "activityLoggin
gAccessForIsolatedWorldsPerWorldBindingsLongAttribute", "TestObjectPython", info
.Holder(), info.GetIsolate()); | 2390 ExceptionState exceptionState(ExceptionState::SetterContext, "activityLoggin
gAccessForIsolatedWorldsPerWorldBindingsLongAttribute", "TestObjectPython", info
.Holder(), info.GetIsolate()); |
| 2391 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2391 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2392 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); | 2392 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); |
| 2393 imp->setActivityLoggingAccessForIsolatedWorldsPerWorldBindingsLongAttribute(
cppValue); | 2393 imp->setActivityLoggingAccessForIsolatedWorldsPerWorldBindingsLongAttribute(
cppValue); |
| 2394 } | 2394 } |
| 2395 | 2395 |
| 2396 static void activityLoggingAccessForIsolatedWorldsPerWorldBindingsLongAttributeA
ttributeSetterCallbackForMainWorld(v8::Local<v8::String>, v8::Local<v8::Value> j
sValue, const v8::PropertyCallbackInfo<void>& info) | 2396 static void activityLoggingAccessForIsolatedWorldsPerWorldBindingsLongAttributeA
ttributeSetterCallbackForMainWorld(v8::Local<v8::String>, v8::Local<v8::Value> j
sValue, const v8::PropertyCallbackInfo<void>& info) |
| 2397 { | 2397 { |
| 2398 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 2398 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 2399 TestObjectPythonV8Internal::activityLoggingAccessForIsolatedWorldsPerWorldBi
ndingsLongAttributeAttributeSetterForMainWorld(jsValue, info); | 2399 TestObjectPythonV8Internal::activityLoggingAccessForIsolatedWorldsPerWorldBi
ndingsLongAttributeAttributeSetterForMainWorld(jsValue, info); |
| 2400 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2400 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2401 } | 2401 } |
| 2402 | 2402 |
| 2403 static void activityLoggingGetterPerWorldBindingsLongAttributeAttributeGetter(co
nst v8::PropertyCallbackInfo<v8::Value>& info) | 2403 static void activityLoggingGetterPerWorldBindingsLongAttributeAttributeGetter(co
nst v8::PropertyCallbackInfo<v8::Value>& info) |
| 2404 { | 2404 { |
| 2405 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2405 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2406 v8SetReturnValueInt(info, imp->activityLoggingGetterPerWorldBindingsLongAttr
ibute()); | 2406 v8SetReturnValueInt(info, imp->activityLoggingGetterPerWorldBindingsLongAttr
ibute()); |
| 2407 } | 2407 } |
| 2408 | 2408 |
| 2409 static void activityLoggingGetterPerWorldBindingsLongAttributeAttributeGetterCal
lback(v8::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) | 2409 static void activityLoggingGetterPerWorldBindingsLongAttributeAttributeGetterCal
lback(v8::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 2410 { | 2410 { |
| 2411 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 2411 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 2412 V8PerContextData* contextData = V8PerContextData::from(info.GetIsolate()->Ge
tCurrentContext()); | 2412 V8PerContextData* contextData = V8PerContextData::from(info.GetIsolate()->Ge
tCurrentContext()); |
| 2413 if (contextData && contextData->activityLogger()) | 2413 if (contextData && contextData->activityLogger()) |
| 2414 contextData->activityLogger()->log("TestObjectPython.activityLoggingGett
erPerWorldBindingsLongAttribute", 0, 0, "Getter"); | 2414 contextData->activityLogger()->log("TestObjectPython.activityLoggingGett
erPerWorldBindingsLongAttribute", 0, 0, "Getter"); |
| 2415 TestObjectPythonV8Internal::activityLoggingGetterPerWorldBindingsLongAttribu
teAttributeGetter(info); | 2415 TestObjectPythonV8Internal::activityLoggingGetterPerWorldBindingsLongAttribu
teAttributeGetter(info); |
| 2416 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2416 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2417 } | 2417 } |
| 2418 | 2418 |
| 2419 static void activityLoggingGetterPerWorldBindingsLongAttributeAttributeSetter(v8
::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 2419 static void activityLoggingGetterPerWorldBindingsLongAttributeAttributeSetter(v8
::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 2420 { | 2420 { |
| 2421 ExceptionState exceptionState(ExceptionState::SetterContext, "activityLoggin
gGetterPerWorldBindingsLongAttribute", "TestObjectPython", info.Holder(), info.G
etIsolate()); | 2421 ExceptionState exceptionState(ExceptionState::SetterContext, "activityLoggin
gGetterPerWorldBindingsLongAttribute", "TestObjectPython", info.Holder(), info.G
etIsolate()); |
| 2422 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2422 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2423 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); | 2423 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); |
| 2424 imp->setActivityLoggingGetterPerWorldBindingsLongAttribute(cppValue); | 2424 imp->setActivityLoggingGetterPerWorldBindingsLongAttribute(cppValue); |
| 2425 } | 2425 } |
| 2426 | 2426 |
| 2427 static void activityLoggingGetterPerWorldBindingsLongAttributeAttributeSetterCal
lback(v8::Local<v8::String>, v8::Local<v8::Value> jsValue, const v8::PropertyCal
lbackInfo<void>& info) | 2427 static void activityLoggingGetterPerWorldBindingsLongAttributeAttributeSetterCal
lback(v8::Local<v8::String>, v8::Local<v8::Value> jsValue, const v8::PropertyCal
lbackInfo<void>& info) |
| 2428 { | 2428 { |
| 2429 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 2429 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 2430 TestObjectPythonV8Internal::activityLoggingGetterPerWorldBindingsLongAttribu
teAttributeSetter(jsValue, info); | 2430 TestObjectPythonV8Internal::activityLoggingGetterPerWorldBindingsLongAttribu
teAttributeSetter(jsValue, info); |
| 2431 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2431 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2432 } | 2432 } |
| 2433 | 2433 |
| 2434 static void activityLoggingGetterPerWorldBindingsLongAttributeAttributeGetterFor
MainWorld(const v8::PropertyCallbackInfo<v8::Value>& info) | 2434 static void activityLoggingGetterPerWorldBindingsLongAttributeAttributeGetterFor
MainWorld(const v8::PropertyCallbackInfo<v8::Value>& info) |
| 2435 { | 2435 { |
| 2436 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2436 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2437 v8SetReturnValueInt(info, imp->activityLoggingGetterPerWorldBindingsLongAttr
ibute()); | 2437 v8SetReturnValueInt(info, imp->activityLoggingGetterPerWorldBindingsLongAttr
ibute()); |
| 2438 } | 2438 } |
| 2439 | 2439 |
| 2440 static void activityLoggingGetterPerWorldBindingsLongAttributeAttributeGetterCal
lbackForMainWorld(v8::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Valu
e>& info) | 2440 static void activityLoggingGetterPerWorldBindingsLongAttributeAttributeGetterCal
lbackForMainWorld(v8::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Valu
e>& info) |
| 2441 { | 2441 { |
| 2442 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 2442 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 2443 V8PerContextData* contextData = V8PerContextData::from(info.GetIsolate()->Ge
tCurrentContext()); | 2443 V8PerContextData* contextData = V8PerContextData::from(info.GetIsolate()->Ge
tCurrentContext()); |
| 2444 if (contextData && contextData->activityLogger()) | 2444 if (contextData && contextData->activityLogger()) |
| 2445 contextData->activityLogger()->log("TestObjectPython.activityLoggingGett
erPerWorldBindingsLongAttribute", 0, 0, "Getter"); | 2445 contextData->activityLogger()->log("TestObjectPython.activityLoggingGett
erPerWorldBindingsLongAttribute", 0, 0, "Getter"); |
| 2446 TestObjectPythonV8Internal::activityLoggingGetterPerWorldBindingsLongAttribu
teAttributeGetterForMainWorld(info); | 2446 TestObjectPythonV8Internal::activityLoggingGetterPerWorldBindingsLongAttribu
teAttributeGetterForMainWorld(info); |
| 2447 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2447 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2448 } | 2448 } |
| 2449 | 2449 |
| 2450 static void activityLoggingGetterPerWorldBindingsLongAttributeAttributeSetterFor
MainWorld(v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& in
fo) | 2450 static void activityLoggingGetterPerWorldBindingsLongAttributeAttributeSetterFor
MainWorld(v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& in
fo) |
| 2451 { | 2451 { |
| 2452 ExceptionState exceptionState(ExceptionState::SetterContext, "activityLoggin
gGetterPerWorldBindingsLongAttribute", "TestObjectPython", info.Holder(), info.G
etIsolate()); | 2452 ExceptionState exceptionState(ExceptionState::SetterContext, "activityLoggin
gGetterPerWorldBindingsLongAttribute", "TestObjectPython", info.Holder(), info.G
etIsolate()); |
| 2453 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2453 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2454 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); | 2454 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); |
| 2455 imp->setActivityLoggingGetterPerWorldBindingsLongAttribute(cppValue); | 2455 imp->setActivityLoggingGetterPerWorldBindingsLongAttribute(cppValue); |
| 2456 } | 2456 } |
| 2457 | 2457 |
| 2458 static void activityLoggingGetterPerWorldBindingsLongAttributeAttributeSetterCal
lbackForMainWorld(v8::Local<v8::String>, v8::Local<v8::Value> jsValue, const v8:
:PropertyCallbackInfo<void>& info) | 2458 static void activityLoggingGetterPerWorldBindingsLongAttributeAttributeSetterCal
lbackForMainWorld(v8::Local<v8::String>, v8::Local<v8::Value> jsValue, const v8:
:PropertyCallbackInfo<void>& info) |
| 2459 { | 2459 { |
| 2460 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 2460 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 2461 TestObjectPythonV8Internal::activityLoggingGetterPerWorldBindingsLongAttribu
teAttributeSetterForMainWorld(jsValue, info); | 2461 TestObjectPythonV8Internal::activityLoggingGetterPerWorldBindingsLongAttribu
teAttributeSetterForMainWorld(jsValue, info); |
| 2462 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2462 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2463 } | 2463 } |
| 2464 | 2464 |
| 2465 static void activityLoggingGetterForIsolatedWorldsPerWorldBindingsLongAttributeA
ttributeGetter(const v8::PropertyCallbackInfo<v8::Value>& info) | 2465 static void activityLoggingGetterForIsolatedWorldsPerWorldBindingsLongAttributeA
ttributeGetter(const v8::PropertyCallbackInfo<v8::Value>& info) |
| 2466 { | 2466 { |
| 2467 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2467 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2468 v8SetReturnValueInt(info, imp->activityLoggingGetterForIsolatedWorldsPerWorl
dBindingsLongAttribute()); | 2468 v8SetReturnValueInt(info, imp->activityLoggingGetterForIsolatedWorldsPerWorl
dBindingsLongAttribute()); |
| 2469 } | 2469 } |
| 2470 | 2470 |
| 2471 static void activityLoggingGetterForIsolatedWorldsPerWorldBindingsLongAttributeA
ttributeGetterCallback(v8::Local<v8::String>, const v8::PropertyCallbackInfo<v8:
:Value>& info) | 2471 static void activityLoggingGetterForIsolatedWorldsPerWorldBindingsLongAttributeA
ttributeGetterCallback(v8::Local<v8::String>, const v8::PropertyCallbackInfo<v8:
:Value>& info) |
| 2472 { | 2472 { |
| 2473 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 2473 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 2474 V8PerContextData* contextData = V8PerContextData::from(info.GetIsolate()->Ge
tCurrentContext()); | 2474 V8PerContextData* contextData = V8PerContextData::from(info.GetIsolate()->Ge
tCurrentContext()); |
| 2475 if (contextData && contextData->activityLogger()) | 2475 if (contextData && contextData->activityLogger()) |
| 2476 contextData->activityLogger()->log("TestObjectPython.activityLoggingGett
erForIsolatedWorldsPerWorldBindingsLongAttribute", 0, 0, "Getter"); | 2476 contextData->activityLogger()->log("TestObjectPython.activityLoggingGett
erForIsolatedWorldsPerWorldBindingsLongAttribute", 0, 0, "Getter"); |
| 2477 TestObjectPythonV8Internal::activityLoggingGetterForIsolatedWorldsPerWorldBi
ndingsLongAttributeAttributeGetter(info); | 2477 TestObjectPythonV8Internal::activityLoggingGetterForIsolatedWorldsPerWorldBi
ndingsLongAttributeAttributeGetter(info); |
| 2478 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2478 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2479 } | 2479 } |
| 2480 | 2480 |
| 2481 static void activityLoggingGetterForIsolatedWorldsPerWorldBindingsLongAttributeA
ttributeSetter(v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void
>& info) | 2481 static void activityLoggingGetterForIsolatedWorldsPerWorldBindingsLongAttributeA
ttributeSetter(v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void
>& info) |
| 2482 { | 2482 { |
| 2483 ExceptionState exceptionState(ExceptionState::SetterContext, "activityLoggin
gGetterForIsolatedWorldsPerWorldBindingsLongAttribute", "TestObjectPython", info
.Holder(), info.GetIsolate()); | 2483 ExceptionState exceptionState(ExceptionState::SetterContext, "activityLoggin
gGetterForIsolatedWorldsPerWorldBindingsLongAttribute", "TestObjectPython", info
.Holder(), info.GetIsolate()); |
| 2484 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2484 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2485 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); | 2485 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); |
| 2486 imp->setActivityLoggingGetterForIsolatedWorldsPerWorldBindingsLongAttribute(
cppValue); | 2486 imp->setActivityLoggingGetterForIsolatedWorldsPerWorldBindingsLongAttribute(
cppValue); |
| 2487 } | 2487 } |
| 2488 | 2488 |
| 2489 static void activityLoggingGetterForIsolatedWorldsPerWorldBindingsLongAttributeA
ttributeSetterCallback(v8::Local<v8::String>, v8::Local<v8::Value> jsValue, cons
t v8::PropertyCallbackInfo<void>& info) | 2489 static void activityLoggingGetterForIsolatedWorldsPerWorldBindingsLongAttributeA
ttributeSetterCallback(v8::Local<v8::String>, v8::Local<v8::Value> jsValue, cons
t v8::PropertyCallbackInfo<void>& info) |
| 2490 { | 2490 { |
| 2491 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 2491 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 2492 TestObjectPythonV8Internal::activityLoggingGetterForIsolatedWorldsPerWorldBi
ndingsLongAttributeAttributeSetter(jsValue, info); | 2492 TestObjectPythonV8Internal::activityLoggingGetterForIsolatedWorldsPerWorldBi
ndingsLongAttributeAttributeSetter(jsValue, info); |
| 2493 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2493 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2494 } | 2494 } |
| 2495 | 2495 |
| 2496 static void activityLoggingGetterForIsolatedWorldsPerWorldBindingsLongAttributeA
ttributeGetterForMainWorld(const v8::PropertyCallbackInfo<v8::Value>& info) | 2496 static void activityLoggingGetterForIsolatedWorldsPerWorldBindingsLongAttributeA
ttributeGetterForMainWorld(const v8::PropertyCallbackInfo<v8::Value>& info) |
| 2497 { | 2497 { |
| 2498 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2498 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2499 v8SetReturnValueInt(info, imp->activityLoggingGetterForIsolatedWorldsPerWorl
dBindingsLongAttribute()); | 2499 v8SetReturnValueInt(info, imp->activityLoggingGetterForIsolatedWorldsPerWorl
dBindingsLongAttribute()); |
| 2500 } | 2500 } |
| 2501 | 2501 |
| 2502 static void activityLoggingGetterForIsolatedWorldsPerWorldBindingsLongAttributeA
ttributeGetterCallbackForMainWorld(v8::Local<v8::String>, const v8::PropertyCall
backInfo<v8::Value>& info) | 2502 static void activityLoggingGetterForIsolatedWorldsPerWorldBindingsLongAttributeA
ttributeGetterCallbackForMainWorld(v8::Local<v8::String>, const v8::PropertyCall
backInfo<v8::Value>& info) |
| 2503 { | 2503 { |
| 2504 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 2504 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 2505 TestObjectPythonV8Internal::activityLoggingGetterForIsolatedWorldsPerWorldBi
ndingsLongAttributeAttributeGetterForMainWorld(info); | 2505 TestObjectPythonV8Internal::activityLoggingGetterForIsolatedWorldsPerWorldBi
ndingsLongAttributeAttributeGetterForMainWorld(info); |
| 2506 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2506 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2507 } | 2507 } |
| 2508 | 2508 |
| 2509 static void activityLoggingGetterForIsolatedWorldsPerWorldBindingsLongAttributeA
ttributeSetterForMainWorld(v8::Local<v8::Value> jsValue, const v8::PropertyCallb
ackInfo<void>& info) | 2509 static void activityLoggingGetterForIsolatedWorldsPerWorldBindingsLongAttributeA
ttributeSetterForMainWorld(v8::Local<v8::Value> jsValue, const v8::PropertyCallb
ackInfo<void>& info) |
| 2510 { | 2510 { |
| 2511 ExceptionState exceptionState(ExceptionState::SetterContext, "activityLoggin
gGetterForIsolatedWorldsPerWorldBindingsLongAttribute", "TestObjectPython", info
.Holder(), info.GetIsolate()); | 2511 ExceptionState exceptionState(ExceptionState::SetterContext, "activityLoggin
gGetterForIsolatedWorldsPerWorldBindingsLongAttribute", "TestObjectPython", info
.Holder(), info.GetIsolate()); |
| 2512 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2512 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2513 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); | 2513 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); |
| 2514 imp->setActivityLoggingGetterForIsolatedWorldsPerWorldBindingsLongAttribute(
cppValue); | 2514 imp->setActivityLoggingGetterForIsolatedWorldsPerWorldBindingsLongAttribute(
cppValue); |
| 2515 } | 2515 } |
| 2516 | 2516 |
| 2517 static void activityLoggingGetterForIsolatedWorldsPerWorldBindingsLongAttributeA
ttributeSetterCallbackForMainWorld(v8::Local<v8::String>, v8::Local<v8::Value> j
sValue, const v8::PropertyCallbackInfo<void>& info) | 2517 static void activityLoggingGetterForIsolatedWorldsPerWorldBindingsLongAttributeA
ttributeSetterCallbackForMainWorld(v8::Local<v8::String>, v8::Local<v8::Value> j
sValue, const v8::PropertyCallbackInfo<void>& info) |
| 2518 { | 2518 { |
| 2519 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 2519 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 2520 TestObjectPythonV8Internal::activityLoggingGetterForIsolatedWorldsPerWorldBi
ndingsLongAttributeAttributeSetterForMainWorld(jsValue, info); | 2520 TestObjectPythonV8Internal::activityLoggingGetterForIsolatedWorldsPerWorldBi
ndingsLongAttributeAttributeSetterForMainWorld(jsValue, info); |
| 2521 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2521 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2522 } | 2522 } |
| 2523 | 2523 |
| 2524 static void raisesExceptionLongAttributeAttributeGetter(const v8::PropertyCallba
ckInfo<v8::Value>& info) | 2524 static void raisesExceptionLongAttributeAttributeGetter(const v8::PropertyCallba
ckInfo<v8::Value>& info) |
| 2525 { | 2525 { |
| 2526 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2526 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2527 ExceptionState exceptionState(ExceptionState::GetterContext, "raisesExceptio
nLongAttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); | 2527 ExceptionState exceptionState(ExceptionState::GetterContext, "raisesExceptio
nLongAttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 2528 int jsValue = imp->raisesExceptionLongAttribute(exceptionState); | 2528 int jsValue = imp->raisesExceptionLongAttribute(exceptionState); |
| 2529 if (UNLIKELY(exceptionState.throwIfNeeded())) | 2529 if (UNLIKELY(exceptionState.throwIfNeeded())) |
| 2530 return; | 2530 return; |
| 2531 v8SetReturnValueInt(info, jsValue); | 2531 v8SetReturnValueInt(info, jsValue); |
| 2532 } | 2532 } |
| 2533 | 2533 |
| 2534 static void raisesExceptionLongAttributeAttributeGetterCallback(v8::Local<v8::St
ring>, const v8::PropertyCallbackInfo<v8::Value>& info) | 2534 static void raisesExceptionLongAttributeAttributeGetterCallback(v8::Local<v8::St
ring>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 2535 { | 2535 { |
| 2536 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 2536 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 2537 TestObjectPythonV8Internal::raisesExceptionLongAttributeAttributeGetter(info
); | 2537 TestObjectPythonV8Internal::raisesExceptionLongAttributeAttributeGetter(info
); |
| 2538 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2538 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2539 } | 2539 } |
| 2540 | 2540 |
| 2541 static void raisesExceptionLongAttributeAttributeSetter(v8::Local<v8::Value> jsV
alue, const v8::PropertyCallbackInfo<void>& info) | 2541 static void raisesExceptionLongAttributeAttributeSetter(v8::Local<v8::Value> jsV
alue, const v8::PropertyCallbackInfo<void>& info) |
| 2542 { | 2542 { |
| 2543 ExceptionState exceptionState(ExceptionState::SetterContext, "raisesExceptio
nLongAttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); | 2543 ExceptionState exceptionState(ExceptionState::SetterContext, "raisesExceptio
nLongAttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 2544 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2544 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2545 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); | 2545 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); |
| 2546 imp->setRaisesExceptionLongAttribute(cppValue, exceptionState); | 2546 imp->setRaisesExceptionLongAttribute(cppValue, exceptionState); |
| 2547 exceptionState.throwIfNeeded(); | 2547 exceptionState.throwIfNeeded(); |
| 2548 } | 2548 } |
| 2549 | 2549 |
| 2550 static void raisesExceptionLongAttributeAttributeSetterCallback(v8::Local<v8::St
ring>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 2550 static void raisesExceptionLongAttributeAttributeSetterCallback(v8::Local<v8::St
ring>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 2551 { | 2551 { |
| 2552 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 2552 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 2553 TestObjectPythonV8Internal::raisesExceptionLongAttributeAttributeSetter(jsVa
lue, info); | 2553 TestObjectPythonV8Internal::raisesExceptionLongAttributeAttributeSetter(jsVa
lue, info); |
| 2554 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2554 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2555 } | 2555 } |
| 2556 | 2556 |
| 2557 static void reflectTestInterfaceAttributeAttributeGetter(const v8::PropertyCallb
ackInfo<v8::Value>& info) | 2557 static void reflectTestInterfaceAttributeAttributeGetter(const v8::PropertyCallb
ackInfo<v8::Value>& info) |
| 2558 { | 2558 { |
| 2559 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2559 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2560 v8SetReturnValueFast(info, imp->fastGetAttribute(HTMLNames::reflecttestinter
faceattributeAttr), imp); | 2560 v8SetReturnValueFast(info, imp->fastGetAttribute(HTMLNames::reflecttestinter
faceattributeAttr), imp); |
| 2561 } | 2561 } |
| 2562 | 2562 |
| 2563 static void reflectTestInterfaceAttributeAttributeGetterCallback(v8::Local<v8::S
tring>, const v8::PropertyCallbackInfo<v8::Value>& info) | 2563 static void reflectTestInterfaceAttributeAttributeGetterCallback(v8::Local<v8::S
tring>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 2564 { | 2564 { |
| 2565 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 2565 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 2566 TestObjectPythonV8Internal::reflectTestInterfaceAttributeAttributeGetter(inf
o); | 2566 TestObjectPythonV8Internal::reflectTestInterfaceAttributeAttributeGetter(inf
o); |
| 2567 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2567 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2568 } | 2568 } |
| 2569 | 2569 |
| 2570 static void reflectTestInterfaceAttributeAttributeSetter(v8::Local<v8::Value> js
Value, const v8::PropertyCallbackInfo<void>& info) | 2570 static void reflectTestInterfaceAttributeAttributeSetter(v8::Local<v8::Value> js
Value, const v8::PropertyCallbackInfo<void>& info) |
| 2571 { | 2571 { |
| 2572 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2572 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2573 V8TRYCATCH_VOID(TestInterface*, cppValue, V8TestInterface::hasInstance(jsVal
ue, info.GetIsolate(), worldType(info.GetIsolate())) ? V8TestInterface::toNative
(v8::Handle<v8::Object>::Cast(jsValue)) : 0); | 2573 V8TRYCATCH_VOID(TestInterface*, cppValue, V8TestInterface::hasInstance(jsVal
ue, info.GetIsolate(), worldType(info.GetIsolate())) ? V8TestInterface::toNative
(v8::Handle<v8::Object>::Cast(jsValue)) : 0); |
| 2574 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; | 2574 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; |
| 2575 imp->setAttribute(HTMLNames::reflecttestinterfaceattributeAttr, WTF::getPtr(
cppValue)); | 2575 imp->setAttribute(HTMLNames::reflecttestinterfaceattributeAttr, WTF::getPtr(
cppValue)); |
| 2576 } | 2576 } |
| 2577 | 2577 |
| 2578 static void reflectTestInterfaceAttributeAttributeSetterCallback(v8::Local<v8::S
tring>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info
) | 2578 static void reflectTestInterfaceAttributeAttributeSetterCallback(v8::Local<v8::S
tring>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info
) |
| 2579 { | 2579 { |
| 2580 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 2580 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 2581 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; | 2581 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; |
| 2582 TestObjectPythonV8Internal::reflectTestInterfaceAttributeAttributeSetter(jsV
alue, info); | 2582 TestObjectPythonV8Internal::reflectTestInterfaceAttributeAttributeSetter(jsV
alue, info); |
| 2583 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2583 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2584 } | 2584 } |
| 2585 | 2585 |
| 2586 static void reflectReflectedNameAttributeTestAttributeAttributeGetter(const v8::
PropertyCallbackInfo<v8::Value>& info) | 2586 static void reflectReflectedNameAttributeTestAttributeAttributeGetter(const v8::
PropertyCallbackInfo<v8::Value>& info) |
| 2587 { | 2587 { |
| 2588 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2588 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2589 v8SetReturnValueFast(info, imp->fastGetAttribute(HTMLNames::reflectedNameAtt
ributeAttr), imp); | 2589 v8SetReturnValueFast(info, imp->fastGetAttribute(HTMLNames::reflectedNameAtt
ributeAttr), imp); |
| 2590 } | 2590 } |
| 2591 | 2591 |
| 2592 static void reflectReflectedNameAttributeTestAttributeAttributeGetterCallback(v8
::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) | 2592 static void reflectReflectedNameAttributeTestAttributeAttributeGetterCallback(v8
::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 2593 { | 2593 { |
| 2594 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 2594 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 2595 TestObjectPythonV8Internal::reflectReflectedNameAttributeTestAttributeAttrib
uteGetter(info); | 2595 TestObjectPythonV8Internal::reflectReflectedNameAttributeTestAttributeAttrib
uteGetter(info); |
| 2596 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2596 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2597 } | 2597 } |
| 2598 | 2598 |
| 2599 static void reflectReflectedNameAttributeTestAttributeAttributeSetter(v8::Local<
v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 2599 static void reflectReflectedNameAttributeTestAttributeAttributeSetter(v8::Local<
v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 2600 { | 2600 { |
| 2601 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2601 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2602 V8TRYCATCH_VOID(TestInterface*, cppValue, V8TestInterface::hasInstance(jsVal
ue, info.GetIsolate(), worldType(info.GetIsolate())) ? V8TestInterface::toNative
(v8::Handle<v8::Object>::Cast(jsValue)) : 0); | 2602 V8TRYCATCH_VOID(TestInterface*, cppValue, V8TestInterface::hasInstance(jsVal
ue, info.GetIsolate(), worldType(info.GetIsolate())) ? V8TestInterface::toNative
(v8::Handle<v8::Object>::Cast(jsValue)) : 0); |
| 2603 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; | 2603 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; |
| 2604 imp->setAttribute(HTMLNames::reflectedNameAttributeAttr, WTF::getPtr(cppValu
e)); | 2604 imp->setAttribute(HTMLNames::reflectedNameAttributeAttr, WTF::getPtr(cppValu
e)); |
| 2605 } | 2605 } |
| 2606 | 2606 |
| 2607 static void reflectReflectedNameAttributeTestAttributeAttributeSetterCallback(v8
::Local<v8::String>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInf
o<void>& info) | 2607 static void reflectReflectedNameAttributeTestAttributeAttributeSetterCallback(v8
::Local<v8::String>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInf
o<void>& info) |
| 2608 { | 2608 { |
| 2609 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 2609 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 2610 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; | 2610 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; |
| 2611 TestObjectPythonV8Internal::reflectReflectedNameAttributeTestAttributeAttrib
uteSetter(jsValue, info); | 2611 TestObjectPythonV8Internal::reflectReflectedNameAttributeTestAttributeAttrib
uteSetter(jsValue, info); |
| 2612 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2612 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2613 } | 2613 } |
| 2614 | 2614 |
| 2615 static void reflectBooleanAttributeAttributeGetter(const v8::PropertyCallbackInf
o<v8::Value>& info) | 2615 static void reflectBooleanAttributeAttributeGetter(const v8::PropertyCallbackInf
o<v8::Value>& info) |
| 2616 { | 2616 { |
| 2617 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2617 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2618 v8SetReturnValueBool(info, imp->fastHasAttribute(HTMLNames::reflectbooleanat
tributeAttr)); | 2618 v8SetReturnValueBool(info, imp->fastHasAttribute(HTMLNames::reflectbooleanat
tributeAttr)); |
| 2619 } | 2619 } |
| 2620 | 2620 |
| 2621 static void reflectBooleanAttributeAttributeGetterCallback(v8::Local<v8::String>
, const v8::PropertyCallbackInfo<v8::Value>& info) | 2621 static void reflectBooleanAttributeAttributeGetterCallback(v8::Local<v8::String>
, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 2622 { | 2622 { |
| 2623 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 2623 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 2624 TestObjectPythonV8Internal::reflectBooleanAttributeAttributeGetter(info); | 2624 TestObjectPythonV8Internal::reflectBooleanAttributeAttributeGetter(info); |
| 2625 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2625 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2626 } | 2626 } |
| 2627 | 2627 |
| 2628 static void reflectBooleanAttributeAttributeSetter(v8::Local<v8::Value> jsValue,
const v8::PropertyCallbackInfo<void>& info) | 2628 static void reflectBooleanAttributeAttributeSetter(v8::Local<v8::Value> jsValue,
const v8::PropertyCallbackInfo<void>& info) |
| 2629 { | 2629 { |
| 2630 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2630 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2631 V8TRYCATCH_VOID(bool, cppValue, jsValue->BooleanValue()); | 2631 V8TRYCATCH_VOID(bool, cppValue, jsValue->BooleanValue()); |
| 2632 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; | 2632 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; |
| 2633 imp->setBooleanAttribute(HTMLNames::reflectbooleanattributeAttr, cppValue); | 2633 imp->setBooleanAttribute(HTMLNames::reflectbooleanattributeAttr, cppValue); |
| 2634 } | 2634 } |
| 2635 | 2635 |
| 2636 static void reflectBooleanAttributeAttributeSetterCallback(v8::Local<v8::String>
, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 2636 static void reflectBooleanAttributeAttributeSetterCallback(v8::Local<v8::String>
, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 2637 { | 2637 { |
| 2638 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 2638 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 2639 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; | 2639 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; |
| 2640 TestObjectPythonV8Internal::reflectBooleanAttributeAttributeSetter(jsValue,
info); | 2640 TestObjectPythonV8Internal::reflectBooleanAttributeAttributeSetter(jsValue,
info); |
| 2641 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2641 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2642 } | 2642 } |
| 2643 | 2643 |
| 2644 static void reflectLongAttributeAttributeGetter(const v8::PropertyCallbackInfo<v
8::Value>& info) | 2644 static void reflectLongAttributeAttributeGetter(const v8::PropertyCallbackInfo<v
8::Value>& info) |
| 2645 { | 2645 { |
| 2646 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2646 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2647 v8SetReturnValueInt(info, imp->getIntegralAttribute(HTMLNames::reflectlongat
tributeAttr)); | 2647 v8SetReturnValueInt(info, imp->getIntegralAttribute(HTMLNames::reflectlongat
tributeAttr)); |
| 2648 } | 2648 } |
| 2649 | 2649 |
| 2650 static void reflectLongAttributeAttributeGetterCallback(v8::Local<v8::String>, c
onst v8::PropertyCallbackInfo<v8::Value>& info) | 2650 static void reflectLongAttributeAttributeGetterCallback(v8::Local<v8::String>, c
onst v8::PropertyCallbackInfo<v8::Value>& info) |
| 2651 { | 2651 { |
| 2652 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 2652 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 2653 TestObjectPythonV8Internal::reflectLongAttributeAttributeGetter(info); | 2653 TestObjectPythonV8Internal::reflectLongAttributeAttributeGetter(info); |
| 2654 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2654 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2655 } | 2655 } |
| 2656 | 2656 |
| 2657 static void reflectLongAttributeAttributeSetter(v8::Local<v8::Value> jsValue, co
nst v8::PropertyCallbackInfo<void>& info) | 2657 static void reflectLongAttributeAttributeSetter(v8::Local<v8::Value> jsValue, co
nst v8::PropertyCallbackInfo<void>& info) |
| 2658 { | 2658 { |
| 2659 ExceptionState exceptionState(ExceptionState::SetterContext, "reflectLongAtt
ribute", "TestObjectPython", info.Holder(), info.GetIsolate()); | 2659 ExceptionState exceptionState(ExceptionState::SetterContext, "reflectLongAtt
ribute", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 2660 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2660 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2661 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); | 2661 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); |
| 2662 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; | 2662 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; |
| 2663 imp->setIntegralAttribute(HTMLNames::reflectlongattributeAttr, cppValue); | 2663 imp->setIntegralAttribute(HTMLNames::reflectlongattributeAttr, cppValue); |
| 2664 } | 2664 } |
| 2665 | 2665 |
| 2666 static void reflectLongAttributeAttributeSetterCallback(v8::Local<v8::String>, v
8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 2666 static void reflectLongAttributeAttributeSetterCallback(v8::Local<v8::String>, v
8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 2667 { | 2667 { |
| 2668 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 2668 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 2669 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; | 2669 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; |
| 2670 TestObjectPythonV8Internal::reflectLongAttributeAttributeSetter(jsValue, inf
o); | 2670 TestObjectPythonV8Internal::reflectLongAttributeAttributeSetter(jsValue, inf
o); |
| 2671 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2671 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2672 } | 2672 } |
| 2673 | 2673 |
| 2674 static void reflectUnsignedShortAttributeAttributeGetter(const v8::PropertyCallb
ackInfo<v8::Value>& info) | 2674 static void reflectUnsignedShortAttributeAttributeGetter(const v8::PropertyCallb
ackInfo<v8::Value>& info) |
| 2675 { | 2675 { |
| 2676 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2676 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2677 v8SetReturnValueUnsigned(info, std::max(0, imp->fastGetAttribute(HTMLNames::
reflectunsignedshortattributeAttr))); | 2677 v8SetReturnValueUnsigned(info, std::max(0, imp->fastGetAttribute(HTMLNames::
reflectunsignedshortattributeAttr))); |
| 2678 } | 2678 } |
| 2679 | 2679 |
| 2680 static void reflectUnsignedShortAttributeAttributeGetterCallback(v8::Local<v8::S
tring>, const v8::PropertyCallbackInfo<v8::Value>& info) | 2680 static void reflectUnsignedShortAttributeAttributeGetterCallback(v8::Local<v8::S
tring>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 2681 { | 2681 { |
| 2682 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 2682 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 2683 TestObjectPythonV8Internal::reflectUnsignedShortAttributeAttributeGetter(inf
o); | 2683 TestObjectPythonV8Internal::reflectUnsignedShortAttributeAttributeGetter(inf
o); |
| 2684 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2684 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2685 } | 2685 } |
| 2686 | 2686 |
| 2687 static void reflectUnsignedShortAttributeAttributeSetter(v8::Local<v8::Value> js
Value, const v8::PropertyCallbackInfo<void>& info) | 2687 static void reflectUnsignedShortAttributeAttributeSetter(v8::Local<v8::Value> js
Value, const v8::PropertyCallbackInfo<void>& info) |
| 2688 { | 2688 { |
| 2689 ExceptionState exceptionState(ExceptionState::SetterContext, "reflectUnsigne
dShortAttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); | 2689 ExceptionState exceptionState(ExceptionState::SetterContext, "reflectUnsigne
dShortAttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 2690 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2690 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2691 V8TRYCATCH_EXCEPTION_VOID(unsigned, cppValue, toUInt16(jsValue, exceptionSta
te), exceptionState); | 2691 V8TRYCATCH_EXCEPTION_VOID(unsigned, cppValue, toUInt16(jsValue, exceptionSta
te), exceptionState); |
| 2692 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; | 2692 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; |
| 2693 imp->setAttribute(HTMLNames::reflectunsignedshortattributeAttr, cppValue); | 2693 imp->setAttribute(HTMLNames::reflectunsignedshortattributeAttr, cppValue); |
| 2694 } | 2694 } |
| 2695 | 2695 |
| 2696 static void reflectUnsignedShortAttributeAttributeSetterCallback(v8::Local<v8::S
tring>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info
) | 2696 static void reflectUnsignedShortAttributeAttributeSetterCallback(v8::Local<v8::S
tring>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info
) |
| 2697 { | 2697 { |
| 2698 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 2698 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 2699 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; | 2699 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; |
| 2700 TestObjectPythonV8Internal::reflectUnsignedShortAttributeAttributeSetter(jsV
alue, info); | 2700 TestObjectPythonV8Internal::reflectUnsignedShortAttributeAttributeSetter(jsV
alue, info); |
| 2701 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2701 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2702 } | 2702 } |
| 2703 | 2703 |
| 2704 static void reflectUnsignedLongAttributeAttributeGetter(const v8::PropertyCallba
ckInfo<v8::Value>& info) | 2704 static void reflectUnsignedLongAttributeAttributeGetter(const v8::PropertyCallba
ckInfo<v8::Value>& info) |
| 2705 { | 2705 { |
| 2706 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2706 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2707 v8SetReturnValueUnsigned(info, std::max(0, imp->getIntegralAttribute(HTMLNam
es::reflectunsignedlongattributeAttr))); | 2707 v8SetReturnValueUnsigned(info, std::max(0, imp->getIntegralAttribute(HTMLNam
es::reflectunsignedlongattributeAttr))); |
| 2708 } | 2708 } |
| 2709 | 2709 |
| 2710 static void reflectUnsignedLongAttributeAttributeGetterCallback(v8::Local<v8::St
ring>, const v8::PropertyCallbackInfo<v8::Value>& info) | 2710 static void reflectUnsignedLongAttributeAttributeGetterCallback(v8::Local<v8::St
ring>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 2711 { | 2711 { |
| 2712 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 2712 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 2713 TestObjectPythonV8Internal::reflectUnsignedLongAttributeAttributeGetter(info
); | 2713 TestObjectPythonV8Internal::reflectUnsignedLongAttributeAttributeGetter(info
); |
| 2714 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2714 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2715 } | 2715 } |
| 2716 | 2716 |
| 2717 static void reflectUnsignedLongAttributeAttributeSetter(v8::Local<v8::Value> jsV
alue, const v8::PropertyCallbackInfo<void>& info) | 2717 static void reflectUnsignedLongAttributeAttributeSetter(v8::Local<v8::Value> jsV
alue, const v8::PropertyCallbackInfo<void>& info) |
| 2718 { | 2718 { |
| 2719 ExceptionState exceptionState(ExceptionState::SetterContext, "reflectUnsigne
dLongAttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); | 2719 ExceptionState exceptionState(ExceptionState::SetterContext, "reflectUnsigne
dLongAttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 2720 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2720 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2721 V8TRYCATCH_EXCEPTION_VOID(unsigned, cppValue, toUInt32(jsValue, exceptionSta
te), exceptionState); | 2721 V8TRYCATCH_EXCEPTION_VOID(unsigned, cppValue, toUInt32(jsValue, exceptionSta
te), exceptionState); |
| 2722 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; | 2722 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; |
| 2723 imp->setUnsignedIntegralAttribute(HTMLNames::reflectunsignedlongattributeAtt
r, cppValue); | 2723 imp->setUnsignedIntegralAttribute(HTMLNames::reflectunsignedlongattributeAtt
r, cppValue); |
| 2724 } | 2724 } |
| 2725 | 2725 |
| 2726 static void reflectUnsignedLongAttributeAttributeSetterCallback(v8::Local<v8::St
ring>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 2726 static void reflectUnsignedLongAttributeAttributeSetterCallback(v8::Local<v8::St
ring>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 2727 { | 2727 { |
| 2728 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 2728 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 2729 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; | 2729 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; |
| 2730 TestObjectPythonV8Internal::reflectUnsignedLongAttributeAttributeSetter(jsVa
lue, info); | 2730 TestObjectPythonV8Internal::reflectUnsignedLongAttributeAttributeSetter(jsVa
lue, info); |
| 2731 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2731 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2732 } | 2732 } |
| 2733 | 2733 |
| 2734 static void idAttributeGetter(const v8::PropertyCallbackInfo<v8::Value>& info) | 2734 static void idAttributeGetter(const v8::PropertyCallbackInfo<v8::Value>& info) |
| 2735 { | 2735 { |
| 2736 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2736 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2737 v8SetReturnValueString(info, imp->getIdAttribute(), info.GetIsolate()); | 2737 v8SetReturnValueString(info, imp->getIdAttribute(), info.GetIsolate()); |
| 2738 } | 2738 } |
| 2739 | 2739 |
| 2740 static void idAttributeGetterCallback(v8::Local<v8::String>, const v8::PropertyC
allbackInfo<v8::Value>& info) | 2740 static void idAttributeGetterCallback(v8::Local<v8::String>, const v8::PropertyC
allbackInfo<v8::Value>& info) |
| 2741 { | 2741 { |
| 2742 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 2742 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 2743 TestObjectPythonV8Internal::idAttributeGetter(info); | 2743 TestObjectPythonV8Internal::idAttributeGetter(info); |
| 2744 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2744 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2745 } | 2745 } |
| 2746 | 2746 |
| 2747 static void idAttributeSetter(v8::Local<v8::Value> jsValue, const v8::PropertyCa
llbackInfo<void>& info) | 2747 static void idAttributeSetter(v8::Local<v8::Value> jsValue, const v8::PropertyCa
llbackInfo<void>& info) |
| 2748 { | 2748 { |
| 2749 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2749 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2750 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, cppValue, jsValue); | 2750 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, cppValue, jsValue); |
| 2751 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; | 2751 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; |
| 2752 imp->setAttribute(HTMLNames::idAttr, cppValue); | 2752 imp->setAttribute(HTMLNames::idAttr, cppValue); |
| 2753 } | 2753 } |
| 2754 | 2754 |
| 2755 static void idAttributeSetterCallback(v8::Local<v8::String>, v8::Local<v8::Value
> jsValue, const v8::PropertyCallbackInfo<void>& info) | 2755 static void idAttributeSetterCallback(v8::Local<v8::String>, v8::Local<v8::Value
> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 2756 { | 2756 { |
| 2757 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 2757 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 2758 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; | 2758 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; |
| 2759 TestObjectPythonV8Internal::idAttributeSetter(jsValue, info); | 2759 TestObjectPythonV8Internal::idAttributeSetter(jsValue, info); |
| 2760 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2760 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2761 } | 2761 } |
| 2762 | 2762 |
| 2763 static void nameAttributeGetter(const v8::PropertyCallbackInfo<v8::Value>& info) | 2763 static void nameAttributeGetter(const v8::PropertyCallbackInfo<v8::Value>& info) |
| 2764 { | 2764 { |
| 2765 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2765 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2766 v8SetReturnValueString(info, imp->getNameAttribute(), info.GetIsolate()); | 2766 v8SetReturnValueString(info, imp->getNameAttribute(), info.GetIsolate()); |
| 2767 } | 2767 } |
| 2768 | 2768 |
| 2769 static void nameAttributeGetterCallback(v8::Local<v8::String>, const v8::Propert
yCallbackInfo<v8::Value>& info) | 2769 static void nameAttributeGetterCallback(v8::Local<v8::String>, const v8::Propert
yCallbackInfo<v8::Value>& info) |
| 2770 { | 2770 { |
| 2771 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 2771 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 2772 TestObjectPythonV8Internal::nameAttributeGetter(info); | 2772 TestObjectPythonV8Internal::nameAttributeGetter(info); |
| 2773 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2773 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2774 } | 2774 } |
| 2775 | 2775 |
| 2776 static void nameAttributeSetter(v8::Local<v8::Value> jsValue, const v8::Property
CallbackInfo<void>& info) | 2776 static void nameAttributeSetter(v8::Local<v8::Value> jsValue, const v8::Property
CallbackInfo<void>& info) |
| 2777 { | 2777 { |
| 2778 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2778 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2779 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, cppValue, jsValue); | 2779 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, cppValue, jsValue); |
| 2780 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; | 2780 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; |
| 2781 imp->setAttribute(HTMLNames::nameAttr, cppValue); | 2781 imp->setAttribute(HTMLNames::nameAttr, cppValue); |
| 2782 } | 2782 } |
| 2783 | 2783 |
| 2784 static void nameAttributeSetterCallback(v8::Local<v8::String>, v8::Local<v8::Val
ue> jsValue, const v8::PropertyCallbackInfo<void>& info) | 2784 static void nameAttributeSetterCallback(v8::Local<v8::String>, v8::Local<v8::Val
ue> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 2785 { | 2785 { |
| 2786 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 2786 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 2787 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; | 2787 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; |
| 2788 TestObjectPythonV8Internal::nameAttributeSetter(jsValue, info); | 2788 TestObjectPythonV8Internal::nameAttributeSetter(jsValue, info); |
| 2789 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2789 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2790 } | 2790 } |
| 2791 | 2791 |
| 2792 static void classAttributeGetter(const v8::PropertyCallbackInfo<v8::Value>& info
) | 2792 static void classAttributeGetter(const v8::PropertyCallbackInfo<v8::Value>& info
) |
| 2793 { | 2793 { |
| 2794 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2794 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2795 v8SetReturnValueString(info, imp->getClassAttribute(), info.GetIsolate()); | 2795 v8SetReturnValueString(info, imp->getClassAttribute(), info.GetIsolate()); |
| 2796 } | 2796 } |
| 2797 | 2797 |
| 2798 static void classAttributeGetterCallback(v8::Local<v8::String>, const v8::Proper
tyCallbackInfo<v8::Value>& info) | 2798 static void classAttributeGetterCallback(v8::Local<v8::String>, const v8::Proper
tyCallbackInfo<v8::Value>& info) |
| 2799 { | 2799 { |
| 2800 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 2800 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 2801 TestObjectPythonV8Internal::classAttributeGetter(info); | 2801 TestObjectPythonV8Internal::classAttributeGetter(info); |
| 2802 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2802 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2803 } | 2803 } |
| 2804 | 2804 |
| 2805 static void classAttributeSetter(v8::Local<v8::Value> jsValue, const v8::Propert
yCallbackInfo<void>& info) | 2805 static void classAttributeSetter(v8::Local<v8::Value> jsValue, const v8::Propert
yCallbackInfo<void>& info) |
| 2806 { | 2806 { |
| 2807 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2807 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2808 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, cppValue, jsValue); | 2808 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, cppValue, jsValue); |
| 2809 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; | 2809 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; |
| 2810 imp->setAttribute(HTMLNames::classAttr, cppValue); | 2810 imp->setAttribute(HTMLNames::classAttr, cppValue); |
| 2811 } | 2811 } |
| 2812 | 2812 |
| 2813 static void classAttributeSetterCallback(v8::Local<v8::String>, v8::Local<v8::Va
lue> jsValue, const v8::PropertyCallbackInfo<void>& info) | 2813 static void classAttributeSetterCallback(v8::Local<v8::String>, v8::Local<v8::Va
lue> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 2814 { | 2814 { |
| 2815 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 2815 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 2816 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; | 2816 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; |
| 2817 TestObjectPythonV8Internal::classAttributeSetter(jsValue, info); | 2817 TestObjectPythonV8Internal::classAttributeSetter(jsValue, info); |
| 2818 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2818 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2819 } | 2819 } |
| 2820 | 2820 |
| 2821 static void reflectedIdAttributeGetter(const v8::PropertyCallbackInfo<v8::Value>
& info) | 2821 static void reflectedIdAttributeGetter(const v8::PropertyCallbackInfo<v8::Value>
& info) |
| 2822 { | 2822 { |
| 2823 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2823 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2824 v8SetReturnValueString(info, imp->getIdAttribute(), info.GetIsolate()); | 2824 v8SetReturnValueString(info, imp->getIdAttribute(), info.GetIsolate()); |
| 2825 } | 2825 } |
| 2826 | 2826 |
| 2827 static void reflectedIdAttributeGetterCallback(v8::Local<v8::String>, const v8::
PropertyCallbackInfo<v8::Value>& info) | 2827 static void reflectedIdAttributeGetterCallback(v8::Local<v8::String>, const v8::
PropertyCallbackInfo<v8::Value>& info) |
| 2828 { | 2828 { |
| 2829 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 2829 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 2830 TestObjectPythonV8Internal::reflectedIdAttributeGetter(info); | 2830 TestObjectPythonV8Internal::reflectedIdAttributeGetter(info); |
| 2831 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2831 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2832 } | 2832 } |
| 2833 | 2833 |
| 2834 static void reflectedIdAttributeSetter(v8::Local<v8::Value> jsValue, const v8::P
ropertyCallbackInfo<void>& info) | 2834 static void reflectedIdAttributeSetter(v8::Local<v8::Value> jsValue, const v8::P
ropertyCallbackInfo<void>& info) |
| 2835 { | 2835 { |
| 2836 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2836 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2837 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, cppValue, jsValue); | 2837 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, cppValue, jsValue); |
| 2838 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; | 2838 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; |
| 2839 imp->setAttribute(HTMLNames::idAttr, cppValue); | 2839 imp->setAttribute(HTMLNames::idAttr, cppValue); |
| 2840 } | 2840 } |
| 2841 | 2841 |
| 2842 static void reflectedIdAttributeSetterCallback(v8::Local<v8::String>, v8::Local<
v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 2842 static void reflectedIdAttributeSetterCallback(v8::Local<v8::String>, v8::Local<
v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 2843 { | 2843 { |
| 2844 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 2844 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 2845 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; | 2845 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; |
| 2846 TestObjectPythonV8Internal::reflectedIdAttributeSetter(jsValue, info); | 2846 TestObjectPythonV8Internal::reflectedIdAttributeSetter(jsValue, info); |
| 2847 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2847 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2848 } | 2848 } |
| 2849 | 2849 |
| 2850 static void reflectedNameAttributeGetter(const v8::PropertyCallbackInfo<v8::Valu
e>& info) | 2850 static void reflectedNameAttributeGetter(const v8::PropertyCallbackInfo<v8::Valu
e>& info) |
| 2851 { | 2851 { |
| 2852 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2852 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2853 v8SetReturnValueString(info, imp->getNameAttribute(), info.GetIsolate()); | 2853 v8SetReturnValueString(info, imp->getNameAttribute(), info.GetIsolate()); |
| 2854 } | 2854 } |
| 2855 | 2855 |
| 2856 static void reflectedNameAttributeGetterCallback(v8::Local<v8::String>, const v8
::PropertyCallbackInfo<v8::Value>& info) | 2856 static void reflectedNameAttributeGetterCallback(v8::Local<v8::String>, const v8
::PropertyCallbackInfo<v8::Value>& info) |
| 2857 { | 2857 { |
| 2858 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 2858 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 2859 TestObjectPythonV8Internal::reflectedNameAttributeGetter(info); | 2859 TestObjectPythonV8Internal::reflectedNameAttributeGetter(info); |
| 2860 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2860 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2861 } | 2861 } |
| 2862 | 2862 |
| 2863 static void reflectedNameAttributeSetter(v8::Local<v8::Value> jsValue, const v8:
:PropertyCallbackInfo<void>& info) | 2863 static void reflectedNameAttributeSetter(v8::Local<v8::Value> jsValue, const v8:
:PropertyCallbackInfo<void>& info) |
| 2864 { | 2864 { |
| 2865 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2865 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2866 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, cppValue, jsValue); | 2866 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, cppValue, jsValue); |
| 2867 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; | 2867 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; |
| 2868 imp->setAttribute(HTMLNames::nameAttr, cppValue); | 2868 imp->setAttribute(HTMLNames::nameAttr, cppValue); |
| 2869 } | 2869 } |
| 2870 | 2870 |
| 2871 static void reflectedNameAttributeSetterCallback(v8::Local<v8::String>, v8::Loca
l<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 2871 static void reflectedNameAttributeSetterCallback(v8::Local<v8::String>, v8::Loca
l<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 2872 { | 2872 { |
| 2873 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 2873 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 2874 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; | 2874 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; |
| 2875 TestObjectPythonV8Internal::reflectedNameAttributeSetter(jsValue, info); | 2875 TestObjectPythonV8Internal::reflectedNameAttributeSetter(jsValue, info); |
| 2876 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2876 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2877 } | 2877 } |
| 2878 | 2878 |
| 2879 static void reflectedClassAttributeGetter(const v8::PropertyCallbackInfo<v8::Val
ue>& info) | 2879 static void reflectedClassAttributeGetter(const v8::PropertyCallbackInfo<v8::Val
ue>& info) |
| 2880 { | 2880 { |
| 2881 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2881 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2882 v8SetReturnValueString(info, imp->getClassAttribute(), info.GetIsolate()); | 2882 v8SetReturnValueString(info, imp->getClassAttribute(), info.GetIsolate()); |
| 2883 } | 2883 } |
| 2884 | 2884 |
| 2885 static void reflectedClassAttributeGetterCallback(v8::Local<v8::String>, const v
8::PropertyCallbackInfo<v8::Value>& info) | 2885 static void reflectedClassAttributeGetterCallback(v8::Local<v8::String>, const v
8::PropertyCallbackInfo<v8::Value>& info) |
| 2886 { | 2886 { |
| 2887 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 2887 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 2888 TestObjectPythonV8Internal::reflectedClassAttributeGetter(info); | 2888 TestObjectPythonV8Internal::reflectedClassAttributeGetter(info); |
| 2889 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2889 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2890 } | 2890 } |
| 2891 | 2891 |
| 2892 static void reflectedClassAttributeSetter(v8::Local<v8::Value> jsValue, const v8
::PropertyCallbackInfo<void>& info) | 2892 static void reflectedClassAttributeSetter(v8::Local<v8::Value> jsValue, const v8
::PropertyCallbackInfo<void>& info) |
| 2893 { | 2893 { |
| 2894 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2894 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2895 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, cppValue, jsValue); | 2895 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, cppValue, jsValue); |
| 2896 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; | 2896 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; |
| 2897 imp->setAttribute(HTMLNames::classAttr, cppValue); | 2897 imp->setAttribute(HTMLNames::classAttr, cppValue); |
| 2898 } | 2898 } |
| 2899 | 2899 |
| 2900 static void reflectedClassAttributeSetterCallback(v8::Local<v8::String>, v8::Loc
al<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 2900 static void reflectedClassAttributeSetterCallback(v8::Local<v8::String>, v8::Loc
al<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 2901 { | 2901 { |
| 2902 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 2902 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 2903 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; | 2903 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; |
| 2904 TestObjectPythonV8Internal::reflectedClassAttributeSetter(jsValue, info); | 2904 TestObjectPythonV8Internal::reflectedClassAttributeSetter(jsValue, info); |
| 2905 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2905 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2906 } | 2906 } |
| 2907 | 2907 |
| 2908 static void replaceableReadonlyLongAttributeAttributeGetter(const v8::PropertyCa
llbackInfo<v8::Value>& info) | 2908 static void replaceableReadonlyLongAttributeAttributeGetter(const v8::PropertyCa
llbackInfo<v8::Value>& info) |
| 2909 { | 2909 { |
| 2910 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2910 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2911 v8SetReturnValueInt(info, imp->replaceableReadonlyLongAttribute()); | 2911 v8SetReturnValueInt(info, imp->replaceableReadonlyLongAttribute()); |
| 2912 } | 2912 } |
| 2913 | 2913 |
| 2914 static void replaceableReadonlyLongAttributeAttributeGetterCallback(v8::Local<v8
::String>, const v8::PropertyCallbackInfo<v8::Value>& info) | 2914 static void replaceableReadonlyLongAttributeAttributeGetterCallback(v8::Local<v8
::String>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 2915 { | 2915 { |
| 2916 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 2916 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 2917 TestObjectPythonV8Internal::replaceableReadonlyLongAttributeAttributeGetter(
info); | 2917 TestObjectPythonV8Internal::replaceableReadonlyLongAttributeAttributeGetter(
info); |
| 2918 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2918 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2919 } | 2919 } |
| 2920 | 2920 |
| 2921 static void runtimeEnabledLongAttributeAttributeGetter(const v8::PropertyCallbac
kInfo<v8::Value>& info) | 2921 static void runtimeEnabledLongAttributeAttributeGetter(const v8::PropertyCallbac
kInfo<v8::Value>& info) |
| 2922 { | 2922 { |
| 2923 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2923 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2924 v8SetReturnValueInt(info, imp->runtimeEnabledLongAttribute()); | 2924 v8SetReturnValueInt(info, imp->runtimeEnabledLongAttribute()); |
| 2925 } | 2925 } |
| 2926 | 2926 |
| 2927 static void runtimeEnabledLongAttributeAttributeGetterCallback(v8::Local<v8::Str
ing>, const v8::PropertyCallbackInfo<v8::Value>& info) | 2927 static void runtimeEnabledLongAttributeAttributeGetterCallback(v8::Local<v8::Str
ing>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 2928 { | 2928 { |
| 2929 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 2929 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 2930 TestObjectPythonV8Internal::runtimeEnabledLongAttributeAttributeGetter(info)
; | 2930 TestObjectPythonV8Internal::runtimeEnabledLongAttributeAttributeGetter(info)
; |
| 2931 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2931 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2932 } | 2932 } |
| 2933 | 2933 |
| 2934 static void runtimeEnabledLongAttributeAttributeSetter(v8::Local<v8::Value> jsVa
lue, const v8::PropertyCallbackInfo<void>& info) | 2934 static void runtimeEnabledLongAttributeAttributeSetter(v8::Local<v8::Value> jsVa
lue, const v8::PropertyCallbackInfo<void>& info) |
| 2935 { | 2935 { |
| 2936 ExceptionState exceptionState(ExceptionState::SetterContext, "runtimeEnabled
LongAttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); | 2936 ExceptionState exceptionState(ExceptionState::SetterContext, "runtimeEnabled
LongAttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 2937 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2937 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2938 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); | 2938 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); |
| 2939 imp->setRuntimeEnabledLongAttribute(cppValue); | 2939 imp->setRuntimeEnabledLongAttribute(cppValue); |
| 2940 } | 2940 } |
| 2941 | 2941 |
| 2942 static void runtimeEnabledLongAttributeAttributeSetterCallback(v8::Local<v8::Str
ing>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 2942 static void runtimeEnabledLongAttributeAttributeSetterCallback(v8::Local<v8::Str
ing>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 2943 { | 2943 { |
| 2944 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 2944 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 2945 TestObjectPythonV8Internal::runtimeEnabledLongAttributeAttributeSetter(jsVal
ue, info); | 2945 TestObjectPythonV8Internal::runtimeEnabledLongAttributeAttributeSetter(jsVal
ue, info); |
| 2946 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2946 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2947 } | 2947 } |
| 2948 | 2948 |
| 2949 #if ENABLE(CONDITION) | 2949 #if ENABLE(CONDITION) |
| 2950 static void conditionalRuntimeEnabledLongAttributeAttributeGetter(const v8::Prop
ertyCallbackInfo<v8::Value>& info) | 2950 static void conditionalRuntimeEnabledLongAttributeAttributeGetter(const v8::Prop
ertyCallbackInfo<v8::Value>& info) |
| 2951 { | 2951 { |
| 2952 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2952 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2953 v8SetReturnValueInt(info, imp->conditionalRuntimeEnabledLongAttribute()); | 2953 v8SetReturnValueInt(info, imp->conditionalRuntimeEnabledLongAttribute()); |
| 2954 } | 2954 } |
| 2955 #endif // ENABLE(CONDITION) | 2955 #endif // ENABLE(CONDITION) |
| 2956 | 2956 |
| 2957 #if ENABLE(CONDITION) | 2957 #if ENABLE(CONDITION) |
| 2958 static void conditionalRuntimeEnabledLongAttributeAttributeGetterCallback(v8::Lo
cal<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) | 2958 static void conditionalRuntimeEnabledLongAttributeAttributeGetterCallback(v8::Lo
cal<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 2959 { | 2959 { |
| 2960 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 2960 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 2961 TestObjectPythonV8Internal::conditionalRuntimeEnabledLongAttributeAttributeG
etter(info); | 2961 TestObjectPythonV8Internal::conditionalRuntimeEnabledLongAttributeAttributeG
etter(info); |
| 2962 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2962 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2963 } | 2963 } |
| 2964 #endif // ENABLE(CONDITION) | 2964 #endif // ENABLE(CONDITION) |
| 2965 | 2965 |
| 2966 #if ENABLE(CONDITION) | 2966 #if ENABLE(CONDITION) |
| 2967 static void conditionalRuntimeEnabledLongAttributeAttributeSetter(v8::Local<v8::
Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 2967 static void conditionalRuntimeEnabledLongAttributeAttributeSetter(v8::Local<v8::
Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 2968 { | 2968 { |
| 2969 ExceptionState exceptionState(ExceptionState::SetterContext, "conditionalRun
timeEnabledLongAttribute", "TestObjectPython", info.Holder(), info.GetIsolate())
; | 2969 ExceptionState exceptionState(ExceptionState::SetterContext, "conditionalRun
timeEnabledLongAttribute", "TestObjectPython", info.Holder(), info.GetIsolate())
; |
| 2970 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2970 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2971 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); | 2971 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); |
| 2972 imp->setConditionalRuntimeEnabledLongAttribute(cppValue); | 2972 imp->setConditionalRuntimeEnabledLongAttribute(cppValue); |
| 2973 } | 2973 } |
| 2974 #endif // ENABLE(CONDITION) | 2974 #endif // ENABLE(CONDITION) |
| 2975 | 2975 |
| 2976 #if ENABLE(CONDITION) | 2976 #if ENABLE(CONDITION) |
| 2977 static void conditionalRuntimeEnabledLongAttributeAttributeSetterCallback(v8::Lo
cal<v8::String>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<vo
id>& info) | 2977 static void conditionalRuntimeEnabledLongAttributeAttributeSetterCallback(v8::Lo
cal<v8::String>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<vo
id>& info) |
| 2978 { | 2978 { |
| 2979 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 2979 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 2980 TestObjectPythonV8Internal::conditionalRuntimeEnabledLongAttributeAttributeS
etter(jsValue, info); | 2980 TestObjectPythonV8Internal::conditionalRuntimeEnabledLongAttributeAttributeS
etter(jsValue, info); |
| 2981 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2981 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2982 } | 2982 } |
| 2983 #endif // ENABLE(CONDITION) | 2983 #endif // ENABLE(CONDITION) |
| 2984 | 2984 |
| 2985 static void setterCallWithActiveWindowAndFirstWindowStringAttributeAttributeGett
er(const v8::PropertyCallbackInfo<v8::Value>& info) | 2985 static void setterCallWithActiveWindowAndFirstWindowStringAttributeAttributeGett
er(const v8::PropertyCallbackInfo<v8::Value>& info) |
| 2986 { | 2986 { |
| 2987 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 2987 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 2988 v8SetReturnValueString(info, imp->setterCallWithActiveWindowAndFirstWindowSt
ringAttribute(), info.GetIsolate()); | 2988 v8SetReturnValueString(info, imp->setterCallWithActiveWindowAndFirstWindowSt
ringAttribute(), info.GetIsolate()); |
| 2989 } | 2989 } |
| 2990 | 2990 |
| 2991 static void setterCallWithActiveWindowAndFirstWindowStringAttributeAttributeGett
erCallback(v8::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& inf
o) | 2991 static void setterCallWithActiveWindowAndFirstWindowStringAttributeAttributeGett
erCallback(v8::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& inf
o) |
| 2992 { | 2992 { |
| 2993 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 2993 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 2994 TestObjectPythonV8Internal::setterCallWithActiveWindowAndFirstWindowStringAt
tributeAttributeGetter(info); | 2994 TestObjectPythonV8Internal::setterCallWithActiveWindowAndFirstWindowStringAt
tributeAttributeGetter(info); |
| 2995 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 2995 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 2996 } | 2996 } |
| 2997 | 2997 |
| 2998 static void setterCallWithActiveWindowAndFirstWindowStringAttributeAttributeSett
er(v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 2998 static void setterCallWithActiveWindowAndFirstWindowStringAttributeAttributeSett
er(v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 2999 { | 2999 { |
| 3000 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3000 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3001 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, cppValue, jsValue); | 3001 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, cppValue, jsValue); |
| 3002 imp->setSetterCallWithActiveWindowAndFirstWindowStringAttribute(activeDOMWin
dow(), firstDOMWindow(), cppValue); | 3002 imp->setSetterCallWithActiveWindowAndFirstWindowStringAttribute(activeDOMWin
dow(), firstDOMWindow(), cppValue); |
| 3003 } | 3003 } |
| 3004 | 3004 |
| 3005 static void setterCallWithActiveWindowAndFirstWindowStringAttributeAttributeSett
erCallback(v8::Local<v8::String>, v8::Local<v8::Value> jsValue, const v8::Proper
tyCallbackInfo<void>& info) | 3005 static void setterCallWithActiveWindowAndFirstWindowStringAttributeAttributeSett
erCallback(v8::Local<v8::String>, v8::Local<v8::Value> jsValue, const v8::Proper
tyCallbackInfo<void>& info) |
| 3006 { | 3006 { |
| 3007 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 3007 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 3008 TestObjectPythonV8Internal::setterCallWithActiveWindowAndFirstWindowStringAt
tributeAttributeSetter(jsValue, info); | 3008 TestObjectPythonV8Internal::setterCallWithActiveWindowAndFirstWindowStringAt
tributeAttributeSetter(jsValue, info); |
| 3009 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3009 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3010 } | 3010 } |
| 3011 | 3011 |
| 3012 static void setterRaisesExceptionLongAttributeAttributeGetter(const v8::Property
CallbackInfo<v8::Value>& info) | 3012 static void setterRaisesExceptionLongAttributeAttributeGetter(const v8::Property
CallbackInfo<v8::Value>& info) |
| 3013 { | 3013 { |
| 3014 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3014 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3015 v8SetReturnValueInt(info, imp->setterRaisesExceptionLongAttribute()); | 3015 v8SetReturnValueInt(info, imp->setterRaisesExceptionLongAttribute()); |
| 3016 } | 3016 } |
| 3017 | 3017 |
| 3018 static void setterRaisesExceptionLongAttributeAttributeGetterCallback(v8::Local<
v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) | 3018 static void setterRaisesExceptionLongAttributeAttributeGetterCallback(v8::Local<
v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 3019 { | 3019 { |
| 3020 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 3020 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 3021 TestObjectPythonV8Internal::setterRaisesExceptionLongAttributeAttributeGette
r(info); | 3021 TestObjectPythonV8Internal::setterRaisesExceptionLongAttributeAttributeGette
r(info); |
| 3022 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3022 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3023 } | 3023 } |
| 3024 | 3024 |
| 3025 static void setterRaisesExceptionLongAttributeAttributeSetter(v8::Local<v8::Valu
e> jsValue, const v8::PropertyCallbackInfo<void>& info) | 3025 static void setterRaisesExceptionLongAttributeAttributeSetter(v8::Local<v8::Valu
e> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 3026 { | 3026 { |
| 3027 ExceptionState exceptionState(ExceptionState::SetterContext, "setterRaisesEx
ceptionLongAttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); | 3027 ExceptionState exceptionState(ExceptionState::SetterContext, "setterRaisesEx
ceptionLongAttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 3028 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3028 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3029 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); | 3029 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); |
| 3030 imp->setSetterRaisesExceptionLongAttribute(cppValue, exceptionState); | 3030 imp->setSetterRaisesExceptionLongAttribute(cppValue, exceptionState); |
| 3031 exceptionState.throwIfNeeded(); | 3031 exceptionState.throwIfNeeded(); |
| 3032 } | 3032 } |
| 3033 | 3033 |
| 3034 static void setterRaisesExceptionLongAttributeAttributeSetterCallback(v8::Local<
v8::String>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>&
info) | 3034 static void setterRaisesExceptionLongAttributeAttributeSetterCallback(v8::Local<
v8::String>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>&
info) |
| 3035 { | 3035 { |
| 3036 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 3036 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 3037 TestObjectPythonV8Internal::setterRaisesExceptionLongAttributeAttributeSette
r(jsValue, info); | 3037 TestObjectPythonV8Internal::setterRaisesExceptionLongAttributeAttributeSette
r(jsValue, info); |
| 3038 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3038 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3039 } | 3039 } |
| 3040 | 3040 |
| 3041 static void strictTypeCheckingFloatAttributeAttributeGetter(const v8::PropertyCa
llbackInfo<v8::Value>& info) | 3041 static void strictTypeCheckingFloatAttributeAttributeGetter(const v8::PropertyCa
llbackInfo<v8::Value>& info) |
| 3042 { | 3042 { |
| 3043 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3043 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3044 v8SetReturnValue(info, imp->strictTypeCheckingFloatAttribute()); | 3044 v8SetReturnValue(info, imp->strictTypeCheckingFloatAttribute()); |
| 3045 } | 3045 } |
| 3046 | 3046 |
| 3047 static void strictTypeCheckingFloatAttributeAttributeGetterCallback(v8::Local<v8
::String>, const v8::PropertyCallbackInfo<v8::Value>& info) | 3047 static void strictTypeCheckingFloatAttributeAttributeGetterCallback(v8::Local<v8
::String>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 3048 { | 3048 { |
| 3049 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 3049 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 3050 TestObjectPythonV8Internal::strictTypeCheckingFloatAttributeAttributeGetter(
info); | 3050 TestObjectPythonV8Internal::strictTypeCheckingFloatAttributeAttributeGetter(
info); |
| 3051 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3051 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3052 } | 3052 } |
| 3053 | 3053 |
| 3054 static void strictTypeCheckingFloatAttributeAttributeSetter(v8::Local<v8::Value>
jsValue, const v8::PropertyCallbackInfo<void>& info) | 3054 static void strictTypeCheckingFloatAttributeAttributeSetter(v8::Local<v8::Value>
jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 3055 { | 3055 { |
| 3056 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3056 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3057 V8TRYCATCH_VOID(float, cppValue, static_cast<float>(jsValue->NumberValue()))
; | 3057 V8TRYCATCH_VOID(float, cppValue, static_cast<float>(jsValue->NumberValue()))
; |
| 3058 imp->setStrictTypeCheckingFloatAttribute(cppValue); | 3058 imp->setStrictTypeCheckingFloatAttribute(cppValue); |
| 3059 } | 3059 } |
| 3060 | 3060 |
| 3061 static void strictTypeCheckingFloatAttributeAttributeSetterCallback(v8::Local<v8
::String>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& i
nfo) | 3061 static void strictTypeCheckingFloatAttributeAttributeSetterCallback(v8::Local<v8
::String>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& i
nfo) |
| 3062 { | 3062 { |
| 3063 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 3063 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 3064 TestObjectPythonV8Internal::strictTypeCheckingFloatAttributeAttributeSetter(
jsValue, info); | 3064 TestObjectPythonV8Internal::strictTypeCheckingFloatAttributeAttributeSetter(
jsValue, info); |
| 3065 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3065 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3066 } | 3066 } |
| 3067 | 3067 |
| 3068 static void strictTypeCheckingTestInterfaceAttributeAttributeGetter(const v8::Pr
opertyCallbackInfo<v8::Value>& info) | 3068 static void strictTypeCheckingTestInterfaceAttributeAttributeGetter(const v8::Pr
opertyCallbackInfo<v8::Value>& info) |
| 3069 { | 3069 { |
| 3070 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3070 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3071 v8SetReturnValueFast(info, imp->strictTypeCheckingTestInterfaceAttribute(),
imp); | 3071 v8SetReturnValueFast(info, imp->strictTypeCheckingTestInterfaceAttribute(),
imp); |
| 3072 } | 3072 } |
| 3073 | 3073 |
| 3074 static void strictTypeCheckingTestInterfaceAttributeAttributeGetterCallback(v8::
Local<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) | 3074 static void strictTypeCheckingTestInterfaceAttributeAttributeGetterCallback(v8::
Local<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 3075 { | 3075 { |
| 3076 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 3076 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 3077 TestObjectPythonV8Internal::strictTypeCheckingTestInterfaceAttributeAttribut
eGetter(info); | 3077 TestObjectPythonV8Internal::strictTypeCheckingTestInterfaceAttributeAttribut
eGetter(info); |
| 3078 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3078 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3079 } | 3079 } |
| 3080 | 3080 |
| 3081 static void strictTypeCheckingTestInterfaceAttributeAttributeSetter(v8::Local<v8
::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 3081 static void strictTypeCheckingTestInterfaceAttributeAttributeSetter(v8::Local<v8
::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 3082 { | 3082 { |
| 3083 ExceptionState exceptionState(ExceptionState::SetterContext, "strictTypeChec
kingTestInterfaceAttribute", "TestObjectPython", info.Holder(), info.GetIsolate(
)); | 3083 ExceptionState exceptionState(ExceptionState::SetterContext, "strictTypeChec
kingTestInterfaceAttribute", "TestObjectPython", info.Holder(), info.GetIsolate(
)); |
| 3084 if (!isUndefinedOrNull(jsValue) && !V8TestInterface::hasInstance(jsValue, in
fo.GetIsolate(), worldType(info.GetIsolate()))) { | 3084 if (!isUndefinedOrNull(jsValue) && !V8TestInterface::hasInstance(jsValue, in
fo.GetIsolate(), worldType(info.GetIsolate()))) { |
| 3085 exceptionState.throwTypeError("The provided value is not of type 'TestIn
terface'."); | 3085 exceptionState.throwTypeError("The provided value is not of type 'TestIn
terface'."); |
| 3086 exceptionState.throwIfNeeded(); | 3086 exceptionState.throwIfNeeded(); |
| 3087 return; | 3087 return; |
| 3088 } | 3088 } |
| 3089 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3089 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3090 V8TRYCATCH_VOID(TestInterface*, cppValue, V8TestInterface::hasInstance(jsVal
ue, info.GetIsolate(), worldType(info.GetIsolate())) ? V8TestInterface::toNative
(v8::Handle<v8::Object>::Cast(jsValue)) : 0); | 3090 V8TRYCATCH_VOID(TestInterface*, cppValue, V8TestInterface::hasInstance(jsVal
ue, info.GetIsolate(), worldType(info.GetIsolate())) ? V8TestInterface::toNative
(v8::Handle<v8::Object>::Cast(jsValue)) : 0); |
| 3091 imp->setStrictTypeCheckingTestInterfaceAttribute(WTF::getPtr(cppValue)); | 3091 imp->setStrictTypeCheckingTestInterfaceAttribute(WTF::getPtr(cppValue)); |
| 3092 } | 3092 } |
| 3093 | 3093 |
| 3094 static void strictTypeCheckingTestInterfaceAttributeAttributeSetterCallback(v8::
Local<v8::String>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<
void>& info) | 3094 static void strictTypeCheckingTestInterfaceAttributeAttributeSetterCallback(v8::
Local<v8::String>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<
void>& info) |
| 3095 { | 3095 { |
| 3096 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 3096 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 3097 TestObjectPythonV8Internal::strictTypeCheckingTestInterfaceAttributeAttribut
eSetter(jsValue, info); | 3097 TestObjectPythonV8Internal::strictTypeCheckingTestInterfaceAttributeAttribut
eSetter(jsValue, info); |
| 3098 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3098 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3099 } | 3099 } |
| 3100 | 3100 |
| 3101 static void treatNullAsNullStringStringAttributeAttributeGetter(const v8::Proper
tyCallbackInfo<v8::Value>& info) | 3101 static void treatNullAsNullStringStringAttributeAttributeGetter(const v8::Proper
tyCallbackInfo<v8::Value>& info) |
| 3102 { | 3102 { |
| 3103 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3103 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3104 v8SetReturnValueString(info, imp->treatNullAsNullStringStringAttribute(), in
fo.GetIsolate()); | 3104 v8SetReturnValueString(info, imp->treatNullAsNullStringStringAttribute(), in
fo.GetIsolate()); |
| 3105 } | 3105 } |
| 3106 | 3106 |
| 3107 static void treatNullAsNullStringStringAttributeAttributeGetterCallback(v8::Loca
l<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) | 3107 static void treatNullAsNullStringStringAttributeAttributeGetterCallback(v8::Loca
l<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 3108 { | 3108 { |
| 3109 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 3109 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 3110 TestObjectPythonV8Internal::treatNullAsNullStringStringAttributeAttributeGet
ter(info); | 3110 TestObjectPythonV8Internal::treatNullAsNullStringStringAttributeAttributeGet
ter(info); |
| 3111 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3111 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3112 } | 3112 } |
| 3113 | 3113 |
| 3114 static void treatNullAsNullStringStringAttributeAttributeSetter(v8::Local<v8::Va
lue> jsValue, const v8::PropertyCallbackInfo<void>& info) | 3114 static void treatNullAsNullStringStringAttributeAttributeSetter(v8::Local<v8::Va
lue> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 3115 { | 3115 { |
| 3116 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3116 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3117 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<WithNullCheck>, cppVal
ue, jsValue); | 3117 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<WithNullCheck>, cppVal
ue, jsValue); |
| 3118 imp->setTreatNullAsNullStringStringAttribute(cppValue); | 3118 imp->setTreatNullAsNullStringStringAttribute(cppValue); |
| 3119 } | 3119 } |
| 3120 | 3120 |
| 3121 static void treatNullAsNullStringStringAttributeAttributeSetterCallback(v8::Loca
l<v8::String>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void
>& info) | 3121 static void treatNullAsNullStringStringAttributeAttributeSetterCallback(v8::Loca
l<v8::String>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void
>& info) |
| 3122 { | 3122 { |
| 3123 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 3123 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 3124 TestObjectPythonV8Internal::treatNullAsNullStringStringAttributeAttributeSet
ter(jsValue, info); | 3124 TestObjectPythonV8Internal::treatNullAsNullStringStringAttributeAttributeSet
ter(jsValue, info); |
| 3125 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3125 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3126 } | 3126 } |
| 3127 | 3127 |
| 3128 static void treatReturnedNullStringAsNullStringAttributeAttributeGetter(const v8
::PropertyCallbackInfo<v8::Value>& info) | 3128 static void treatReturnedNullStringAsNullStringAttributeAttributeGetter(const v8
::PropertyCallbackInfo<v8::Value>& info) |
| 3129 { | 3129 { |
| 3130 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3130 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3131 v8SetReturnValueStringOrNull(info, imp->treatReturnedNullStringAsNullStringA
ttribute(), info.GetIsolate()); | 3131 v8SetReturnValueStringOrNull(info, imp->treatReturnedNullStringAsNullStringA
ttribute(), info.GetIsolate()); |
| 3132 } | 3132 } |
| 3133 | 3133 |
| 3134 static void treatReturnedNullStringAsNullStringAttributeAttributeGetterCallback(
v8::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) | 3134 static void treatReturnedNullStringAsNullStringAttributeAttributeGetterCallback(
v8::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 3135 { | 3135 { |
| 3136 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 3136 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 3137 TestObjectPythonV8Internal::treatReturnedNullStringAsNullStringAttributeAttr
ibuteGetter(info); | 3137 TestObjectPythonV8Internal::treatReturnedNullStringAsNullStringAttributeAttr
ibuteGetter(info); |
| 3138 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3138 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3139 } | 3139 } |
| 3140 | 3140 |
| 3141 static void treatReturnedNullStringAsNullStringAttributeAttributeSetter(v8::Loca
l<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 3141 static void treatReturnedNullStringAsNullStringAttributeAttributeSetter(v8::Loca
l<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 3142 { | 3142 { |
| 3143 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3143 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3144 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, cppValue, jsValue); | 3144 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, cppValue, jsValue); |
| 3145 imp->setTreatReturnedNullStringAsNullStringAttribute(cppValue); | 3145 imp->setTreatReturnedNullStringAsNullStringAttribute(cppValue); |
| 3146 } | 3146 } |
| 3147 | 3147 |
| 3148 static void treatReturnedNullStringAsNullStringAttributeAttributeSetterCallback(
v8::Local<v8::String>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackI
nfo<void>& info) | 3148 static void treatReturnedNullStringAsNullStringAttributeAttributeSetterCallback(
v8::Local<v8::String>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackI
nfo<void>& info) |
| 3149 { | 3149 { |
| 3150 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 3150 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 3151 TestObjectPythonV8Internal::treatReturnedNullStringAsNullStringAttributeAttr
ibuteSetter(jsValue, info); | 3151 TestObjectPythonV8Internal::treatReturnedNullStringAsNullStringAttributeAttr
ibuteSetter(jsValue, info); |
| 3152 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3152 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3153 } | 3153 } |
| 3154 | 3154 |
| 3155 static void treatReturnedNullStringAsUndefinedStringAttributeAttributeGetter(con
st v8::PropertyCallbackInfo<v8::Value>& info) | 3155 static void treatReturnedNullStringAsUndefinedStringAttributeAttributeGetter(con
st v8::PropertyCallbackInfo<v8::Value>& info) |
| 3156 { | 3156 { |
| 3157 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3157 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3158 v8SetReturnValueStringOrUndefined(info, imp->treatReturnedNullStringAsUndefi
nedStringAttribute(), info.GetIsolate()); | 3158 v8SetReturnValueStringOrUndefined(info, imp->treatReturnedNullStringAsUndefi
nedStringAttribute(), info.GetIsolate()); |
| 3159 } | 3159 } |
| 3160 | 3160 |
| 3161 static void treatReturnedNullStringAsUndefinedStringAttributeAttributeGetterCall
back(v8::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) | 3161 static void treatReturnedNullStringAsUndefinedStringAttributeAttributeGetterCall
back(v8::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 3162 { | 3162 { |
| 3163 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 3163 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 3164 TestObjectPythonV8Internal::treatReturnedNullStringAsUndefinedStringAttribut
eAttributeGetter(info); | 3164 TestObjectPythonV8Internal::treatReturnedNullStringAsUndefinedStringAttribut
eAttributeGetter(info); |
| 3165 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3165 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3166 } | 3166 } |
| 3167 | 3167 |
| 3168 static void treatReturnedNullStringAsUndefinedStringAttributeAttributeSetter(v8:
:Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 3168 static void treatReturnedNullStringAsUndefinedStringAttributeAttributeSetter(v8:
:Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 3169 { | 3169 { |
| 3170 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3170 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3171 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, cppValue, jsValue); | 3171 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, cppValue, jsValue); |
| 3172 imp->setTreatReturnedNullStringAsUndefinedStringAttribute(cppValue); | 3172 imp->setTreatReturnedNullStringAsUndefinedStringAttribute(cppValue); |
| 3173 } | 3173 } |
| 3174 | 3174 |
| 3175 static void treatReturnedNullStringAsUndefinedStringAttributeAttributeSetterCall
back(v8::Local<v8::String>, v8::Local<v8::Value> jsValue, const v8::PropertyCall
backInfo<void>& info) | 3175 static void treatReturnedNullStringAsUndefinedStringAttributeAttributeSetterCall
back(v8::Local<v8::String>, v8::Local<v8::Value> jsValue, const v8::PropertyCall
backInfo<void>& info) |
| 3176 { | 3176 { |
| 3177 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 3177 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 3178 TestObjectPythonV8Internal::treatReturnedNullStringAsUndefinedStringAttribut
eAttributeSetter(jsValue, info); | 3178 TestObjectPythonV8Internal::treatReturnedNullStringAsUndefinedStringAttribut
eAttributeSetter(jsValue, info); |
| 3179 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3179 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3180 } | 3180 } |
| 3181 | 3181 |
| 3182 static void urlStringAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8:
:Value>& info) | 3182 static void urlStringAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8:
:Value>& info) |
| 3183 { | 3183 { |
| 3184 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3184 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3185 v8SetReturnValueString(info, imp->getURLAttribute(HTMLNames::urlstringattrib
uteAttr), info.GetIsolate()); | 3185 v8SetReturnValueString(info, imp->getURLAttribute(HTMLNames::urlstringattrib
uteAttr), info.GetIsolate()); |
| 3186 } | 3186 } |
| 3187 | 3187 |
| 3188 static void urlStringAttributeAttributeGetterCallback(v8::Local<v8::String>, con
st v8::PropertyCallbackInfo<v8::Value>& info) | 3188 static void urlStringAttributeAttributeGetterCallback(v8::Local<v8::String>, con
st v8::PropertyCallbackInfo<v8::Value>& info) |
| 3189 { | 3189 { |
| 3190 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 3190 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 3191 TestObjectPythonV8Internal::urlStringAttributeAttributeGetter(info); | 3191 TestObjectPythonV8Internal::urlStringAttributeAttributeGetter(info); |
| 3192 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3192 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3193 } | 3193 } |
| 3194 | 3194 |
| 3195 static void urlStringAttributeAttributeSetter(v8::Local<v8::Value> jsValue, cons
t v8::PropertyCallbackInfo<void>& info) | 3195 static void urlStringAttributeAttributeSetter(v8::Local<v8::Value> jsValue, cons
t v8::PropertyCallbackInfo<void>& info) |
| 3196 { | 3196 { |
| 3197 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3197 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3198 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, cppValue, jsValue); | 3198 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, cppValue, jsValue); |
| 3199 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; | 3199 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; |
| 3200 imp->setAttribute(HTMLNames::urlstringattributeAttr, cppValue); | 3200 imp->setAttribute(HTMLNames::urlstringattributeAttr, cppValue); |
| 3201 } | 3201 } |
| 3202 | 3202 |
| 3203 static void urlStringAttributeAttributeSetterCallback(v8::Local<v8::String>, v8:
:Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 3203 static void urlStringAttributeAttributeSetterCallback(v8::Local<v8::String>, v8:
:Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 3204 { | 3204 { |
| 3205 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 3205 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 3206 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; | 3206 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; |
| 3207 TestObjectPythonV8Internal::urlStringAttributeAttributeSetter(jsValue, info)
; | 3207 TestObjectPythonV8Internal::urlStringAttributeAttributeSetter(jsValue, info)
; |
| 3208 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3208 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3209 } | 3209 } |
| 3210 | 3210 |
| 3211 static void urlStringAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8:
:Value>& info) | 3211 static void urlStringAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8:
:Value>& info) |
| 3212 { | 3212 { |
| 3213 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3213 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3214 v8SetReturnValueString(info, imp->getURLAttribute(HTMLNames::ReflectUrlAttri
buteAttr), info.GetIsolate()); | 3214 v8SetReturnValueString(info, imp->getURLAttribute(HTMLNames::ReflectUrlAttri
buteAttr), info.GetIsolate()); |
| 3215 } | 3215 } |
| 3216 | 3216 |
| 3217 static void urlStringAttributeAttributeGetterCallback(v8::Local<v8::String>, con
st v8::PropertyCallbackInfo<v8::Value>& info) | 3217 static void urlStringAttributeAttributeGetterCallback(v8::Local<v8::String>, con
st v8::PropertyCallbackInfo<v8::Value>& info) |
| 3218 { | 3218 { |
| 3219 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 3219 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 3220 TestObjectPythonV8Internal::urlStringAttributeAttributeGetter(info); | 3220 TestObjectPythonV8Internal::urlStringAttributeAttributeGetter(info); |
| 3221 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3221 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3222 } | 3222 } |
| 3223 | 3223 |
| 3224 static void urlStringAttributeAttributeSetter(v8::Local<v8::Value> jsValue, cons
t v8::PropertyCallbackInfo<void>& info) | 3224 static void urlStringAttributeAttributeSetter(v8::Local<v8::Value> jsValue, cons
t v8::PropertyCallbackInfo<void>& info) |
| 3225 { | 3225 { |
| 3226 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3226 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3227 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, cppValue, jsValue); | 3227 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, cppValue, jsValue); |
| 3228 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; | 3228 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; |
| 3229 imp->setAttribute(HTMLNames::ReflectUrlAttributeAttr, cppValue); | 3229 imp->setAttribute(HTMLNames::ReflectUrlAttributeAttr, cppValue); |
| 3230 } | 3230 } |
| 3231 | 3231 |
| 3232 static void urlStringAttributeAttributeSetterCallback(v8::Local<v8::String>, v8:
:Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 3232 static void urlStringAttributeAttributeSetterCallback(v8::Local<v8::String>, v8:
:Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 3233 { | 3233 { |
| 3234 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 3234 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 3235 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; | 3235 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; |
| 3236 TestObjectPythonV8Internal::urlStringAttributeAttributeSetter(jsValue, info)
; | 3236 TestObjectPythonV8Internal::urlStringAttributeAttributeSetter(jsValue, info)
; |
| 3237 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3237 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3238 } | 3238 } |
| 3239 | 3239 |
| 3240 static void unforgeableLongAttributeAttributeGetter(const v8::PropertyCallbackIn
fo<v8::Value>& info) | 3240 static void unforgeableLongAttributeAttributeGetter(const v8::PropertyCallbackIn
fo<v8::Value>& info) |
| 3241 { | 3241 { |
| 3242 v8::Handle<v8::Object> holder = info.This()->FindInstanceInPrototypeChain(V8
TestObjectPython::domTemplate(info.GetIsolate(), worldType(info.GetIsolate()))); | 3242 v8::Handle<v8::Object> holder = info.This()->FindInstanceInPrototypeChain(V8
TestObjectPython::domTemplate(info.GetIsolate(), worldType(info.GetIsolate()))); |
| 3243 if (holder.IsEmpty()) | 3243 if (holder.IsEmpty()) |
| 3244 return; | 3244 return; |
| 3245 TestObjectPython* imp = V8TestObjectPython::toNative(holder); | 3245 TestObjectPython* imp = V8TestObjectPython::toNative(holder); |
| 3246 v8SetReturnValueInt(info, imp->unforgeableLongAttribute()); | 3246 v8SetReturnValueInt(info, imp->unforgeableLongAttribute()); |
| 3247 } | 3247 } |
| 3248 | 3248 |
| 3249 static void unforgeableLongAttributeAttributeGetterCallback(v8::Local<v8::String
>, const v8::PropertyCallbackInfo<v8::Value>& info) | 3249 static void unforgeableLongAttributeAttributeGetterCallback(v8::Local<v8::String
>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 3250 { | 3250 { |
| 3251 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 3251 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 3252 TestObjectPythonV8Internal::unforgeableLongAttributeAttributeGetter(info); | 3252 TestObjectPythonV8Internal::unforgeableLongAttributeAttributeGetter(info); |
| 3253 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3253 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3254 } | 3254 } |
| 3255 | 3255 |
| 3256 static void unforgeableLongAttributeAttributeSetter(v8::Local<v8::Value> jsValue
, const v8::PropertyCallbackInfo<void>& info) | 3256 static void unforgeableLongAttributeAttributeSetter(v8::Local<v8::Value> jsValue
, const v8::PropertyCallbackInfo<void>& info) |
| 3257 { | 3257 { |
| 3258 ExceptionState exceptionState(ExceptionState::SetterContext, "unforgeableLon
gAttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); | 3258 ExceptionState exceptionState(ExceptionState::SetterContext, "unforgeableLon
gAttribute", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 3259 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3259 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3260 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); | 3260 V8TRYCATCH_EXCEPTION_VOID(int, cppValue, toInt32(jsValue, exceptionState), e
xceptionState); |
| 3261 imp->setUnforgeableLongAttribute(cppValue); | 3261 imp->setUnforgeableLongAttribute(cppValue); |
| 3262 } | 3262 } |
| 3263 | 3263 |
| 3264 static void unforgeableLongAttributeAttributeSetterCallback(v8::Local<v8::String
>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 3264 static void unforgeableLongAttributeAttributeSetterCallback(v8::Local<v8::String
>, v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 3265 { | 3265 { |
| 3266 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 3266 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 3267 TestObjectPythonV8Internal::unforgeableLongAttributeAttributeSetter(jsValue,
info); | 3267 TestObjectPythonV8Internal::unforgeableLongAttributeAttributeSetter(jsValue,
info); |
| 3268 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3268 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3269 } | 3269 } |
| 3270 | 3270 |
| 3271 static void anotherStringAttributeAttributeGetter(const v8::PropertyCallbackInfo
<v8::Value>& info) | 3271 static void anotherStringAttributeAttributeGetter(const v8::PropertyCallbackInfo
<v8::Value>& info) |
| 3272 { | 3272 { |
| 3273 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3273 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3274 v8SetReturnValueString(info, imp->fastGetAttribute(HTMLNames::ReflectUrlAttr
ibuteAsAStringAttr), info.GetIsolate()); | 3274 v8SetReturnValueString(info, imp->fastGetAttribute(HTMLNames::ReflectUrlAttr
ibuteAsAStringAttr), info.GetIsolate()); |
| 3275 } | 3275 } |
| 3276 | 3276 |
| 3277 static void anotherStringAttributeAttributeGetterCallback(v8::Local<v8::String>,
const v8::PropertyCallbackInfo<v8::Value>& info) | 3277 static void anotherStringAttributeAttributeGetterCallback(v8::Local<v8::String>,
const v8::PropertyCallbackInfo<v8::Value>& info) |
| 3278 { | 3278 { |
| 3279 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 3279 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 3280 TestObjectPythonV8Internal::anotherStringAttributeAttributeGetter(info); | 3280 TestObjectPythonV8Internal::anotherStringAttributeAttributeGetter(info); |
| 3281 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3281 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3282 } | 3282 } |
| 3283 | 3283 |
| 3284 static void anotherStringAttributeAttributeSetter(v8::Local<v8::Value> jsValue,
const v8::PropertyCallbackInfo<void>& info) | 3284 static void anotherStringAttributeAttributeSetter(v8::Local<v8::Value> jsValue,
const v8::PropertyCallbackInfo<void>& info) |
| 3285 { | 3285 { |
| 3286 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3286 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3287 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, cppValue, jsValue); | 3287 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, cppValue, jsValue); |
| 3288 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; | 3288 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; |
| 3289 imp->setAttribute(HTMLNames::ReflectUrlAttributeAsAStringAttr, cppValue); | 3289 imp->setAttribute(HTMLNames::ReflectUrlAttributeAsAStringAttr, cppValue); |
| 3290 } | 3290 } |
| 3291 | 3291 |
| 3292 static void anotherStringAttributeAttributeSetterCallback(v8::Local<v8::String>,
v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) | 3292 static void anotherStringAttributeAttributeSetterCallback(v8::Local<v8::String>,
v8::Local<v8::Value> jsValue, const v8::PropertyCallbackInfo<void>& info) |
| 3293 { | 3293 { |
| 3294 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 3294 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 3295 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; | 3295 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; |
| 3296 TestObjectPythonV8Internal::anotherStringAttributeAttributeSetter(jsValue, i
nfo); | 3296 TestObjectPythonV8Internal::anotherStringAttributeAttributeSetter(jsValue, i
nfo); |
| 3297 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3297 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3298 } | 3298 } |
| 3299 | 3299 |
| 3300 static void TestObjectPythonConstructorGetter(v8::Local<v8::String>, const v8::P
ropertyCallbackInfo<v8::Value>& info) | 3300 static void TestObjectPythonConstructorGetter(v8::Local<v8::String>, const v8::P
ropertyCallbackInfo<v8::Value>& info) |
| 3301 { | 3301 { |
| 3302 v8::Handle<v8::Value> data = info.Data(); | 3302 v8::Handle<v8::Value> data = info.Data(); |
| 3303 ASSERT(data->IsExternal()); | 3303 ASSERT(data->IsExternal()); |
| 3304 V8PerContextData* perContextData = V8PerContextData::from(info.Holder()->Cre
ationContext()); | 3304 V8PerContextData* perContextData = V8PerContextData::from(info.Holder()->Cre
ationContext()); |
| 3305 if (!perContextData) | 3305 if (!perContextData) |
| 3306 return; | 3306 return; |
| 3307 v8SetReturnValue(info, perContextData->constructorForType(WrapperTypeInfo::u
nwrap(data))); | 3307 v8SetReturnValue(info, perContextData->constructorForType(WrapperTypeInfo::u
nwrap(data))); |
| (...skipping 12 matching lines...) Expand all Loading... |
| 3320 static void voidMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) | 3320 static void voidMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| 3321 { | 3321 { |
| 3322 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3322 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3323 imp->voidMethod(); | 3323 imp->voidMethod(); |
| 3324 } | 3324 } |
| 3325 | 3325 |
| 3326 static void voidMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>&
info) | 3326 static void voidMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>&
info) |
| 3327 { | 3327 { |
| 3328 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 3328 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 3329 TestObjectPythonV8Internal::voidMethodMethod(info); | 3329 TestObjectPythonV8Internal::voidMethodMethod(info); |
| 3330 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3330 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3331 } | 3331 } |
| 3332 | 3332 |
| 3333 static void staticVoidMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& in
fo) | 3333 static void staticVoidMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& in
fo) |
| 3334 { | 3334 { |
| 3335 TestObjectPython::staticVoidMethod(); | 3335 TestObjectPython::staticVoidMethod(); |
| 3336 } | 3336 } |
| 3337 | 3337 |
| 3338 static void staticVoidMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Va
lue>& info) | 3338 static void staticVoidMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Va
lue>& info) |
| 3339 { | 3339 { |
| 3340 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 3340 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 3341 TestObjectPythonV8Internal::staticVoidMethodMethod(info); | 3341 TestObjectPythonV8Internal::staticVoidMethodMethod(info); |
| 3342 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3342 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3343 } | 3343 } |
| 3344 | 3344 |
| 3345 static void dateMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) | 3345 static void dateMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| 3346 { | 3346 { |
| 3347 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3347 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3348 v8SetReturnValue(info, v8DateOrNull(imp->dateMethod(), info.GetIsolate())); | 3348 v8SetReturnValue(info, v8DateOrNull(imp->dateMethod(), info.GetIsolate())); |
| 3349 } | 3349 } |
| 3350 | 3350 |
| 3351 static void dateMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>&
info) | 3351 static void dateMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>&
info) |
| 3352 { | 3352 { |
| 3353 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 3353 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 3354 TestObjectPythonV8Internal::dateMethodMethod(info); | 3354 TestObjectPythonV8Internal::dateMethodMethod(info); |
| 3355 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3355 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3356 } | 3356 } |
| 3357 | 3357 |
| 3358 static void stringMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) | 3358 static void stringMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| 3359 { | 3359 { |
| 3360 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3360 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3361 v8SetReturnValueString(info, imp->stringMethod(), info.GetIsolate()); | 3361 v8SetReturnValueString(info, imp->stringMethod(), info.GetIsolate()); |
| 3362 } | 3362 } |
| 3363 | 3363 |
| 3364 static void stringMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>
& info) | 3364 static void stringMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>
& info) |
| 3365 { | 3365 { |
| 3366 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 3366 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 3367 TestObjectPythonV8Internal::stringMethodMethod(info); | 3367 TestObjectPythonV8Internal::stringMethodMethod(info); |
| 3368 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3368 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3369 } | 3369 } |
| 3370 | 3370 |
| 3371 static void readonlyDOMTimeStampMethodMethod(const v8::FunctionCallbackInfo<v8::
Value>& info) | 3371 static void readonlyDOMTimeStampMethodMethod(const v8::FunctionCallbackInfo<v8::
Value>& info) |
| 3372 { | 3372 { |
| 3373 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3373 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3374 v8SetReturnValue(info, static_cast<double>(imp->readonlyDOMTimeStampMethod()
)); | 3374 v8SetReturnValue(info, static_cast<double>(imp->readonlyDOMTimeStampMethod()
)); |
| 3375 } | 3375 } |
| 3376 | 3376 |
| 3377 static void readonlyDOMTimeStampMethodMethodCallback(const v8::FunctionCallbackI
nfo<v8::Value>& info) | 3377 static void readonlyDOMTimeStampMethodMethodCallback(const v8::FunctionCallbackI
nfo<v8::Value>& info) |
| 3378 { | 3378 { |
| 3379 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 3379 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 3380 TestObjectPythonV8Internal::readonlyDOMTimeStampMethodMethod(info); | 3380 TestObjectPythonV8Internal::readonlyDOMTimeStampMethodMethod(info); |
| 3381 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3381 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3382 } | 3382 } |
| 3383 | 3383 |
| 3384 static void booleanMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) | 3384 static void booleanMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| 3385 { | 3385 { |
| 3386 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3386 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3387 v8SetReturnValueBool(info, imp->booleanMethod()); | 3387 v8SetReturnValueBool(info, imp->booleanMethod()); |
| 3388 } | 3388 } |
| 3389 | 3389 |
| 3390 static void booleanMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value
>& info) | 3390 static void booleanMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value
>& info) |
| 3391 { | 3391 { |
| 3392 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 3392 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 3393 TestObjectPythonV8Internal::booleanMethodMethod(info); | 3393 TestObjectPythonV8Internal::booleanMethodMethod(info); |
| 3394 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3394 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3395 } | 3395 } |
| 3396 | 3396 |
| 3397 static void byteMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) | 3397 static void byteMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| 3398 { | 3398 { |
| 3399 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3399 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3400 v8SetReturnValueInt(info, imp->byteMethod()); | 3400 v8SetReturnValueInt(info, imp->byteMethod()); |
| 3401 } | 3401 } |
| 3402 | 3402 |
| 3403 static void byteMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>&
info) | 3403 static void byteMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>&
info) |
| 3404 { | 3404 { |
| 3405 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 3405 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 3406 TestObjectPythonV8Internal::byteMethodMethod(info); | 3406 TestObjectPythonV8Internal::byteMethodMethod(info); |
| 3407 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3407 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3408 } | 3408 } |
| 3409 | 3409 |
| 3410 static void doubleMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) | 3410 static void doubleMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| 3411 { | 3411 { |
| 3412 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3412 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3413 v8SetReturnValue(info, imp->doubleMethod()); | 3413 v8SetReturnValue(info, imp->doubleMethod()); |
| 3414 } | 3414 } |
| 3415 | 3415 |
| 3416 static void doubleMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>
& info) | 3416 static void doubleMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>
& info) |
| 3417 { | 3417 { |
| 3418 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 3418 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 3419 TestObjectPythonV8Internal::doubleMethodMethod(info); | 3419 TestObjectPythonV8Internal::doubleMethodMethod(info); |
| 3420 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3420 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3421 } | 3421 } |
| 3422 | 3422 |
| 3423 static void floatMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) | 3423 static void floatMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| 3424 { | 3424 { |
| 3425 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3425 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3426 v8SetReturnValue(info, imp->floatMethod()); | 3426 v8SetReturnValue(info, imp->floatMethod()); |
| 3427 } | 3427 } |
| 3428 | 3428 |
| 3429 static void floatMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>&
info) | 3429 static void floatMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>&
info) |
| 3430 { | 3430 { |
| 3431 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 3431 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 3432 TestObjectPythonV8Internal::floatMethodMethod(info); | 3432 TestObjectPythonV8Internal::floatMethodMethod(info); |
| 3433 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3433 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3434 } | 3434 } |
| 3435 | 3435 |
| 3436 static void longMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) | 3436 static void longMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| 3437 { | 3437 { |
| 3438 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3438 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3439 v8SetReturnValueInt(info, imp->longMethod()); | 3439 v8SetReturnValueInt(info, imp->longMethod()); |
| 3440 } | 3440 } |
| 3441 | 3441 |
| 3442 static void longMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>&
info) | 3442 static void longMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>&
info) |
| 3443 { | 3443 { |
| 3444 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 3444 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 3445 TestObjectPythonV8Internal::longMethodMethod(info); | 3445 TestObjectPythonV8Internal::longMethodMethod(info); |
| 3446 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3446 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3447 } | 3447 } |
| 3448 | 3448 |
| 3449 static void longLongMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info
) | 3449 static void longLongMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info
) |
| 3450 { | 3450 { |
| 3451 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3451 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3452 v8SetReturnValue(info, static_cast<double>(imp->longLongMethod())); | 3452 v8SetReturnValue(info, static_cast<double>(imp->longLongMethod())); |
| 3453 } | 3453 } |
| 3454 | 3454 |
| 3455 static void longLongMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Valu
e>& info) | 3455 static void longLongMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Valu
e>& info) |
| 3456 { | 3456 { |
| 3457 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 3457 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 3458 TestObjectPythonV8Internal::longLongMethodMethod(info); | 3458 TestObjectPythonV8Internal::longLongMethodMethod(info); |
| 3459 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3459 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3460 } | 3460 } |
| 3461 | 3461 |
| 3462 static void octetMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) | 3462 static void octetMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| 3463 { | 3463 { |
| 3464 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3464 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3465 v8SetReturnValueUnsigned(info, imp->octetMethod()); | 3465 v8SetReturnValueUnsigned(info, imp->octetMethod()); |
| 3466 } | 3466 } |
| 3467 | 3467 |
| 3468 static void octetMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>&
info) | 3468 static void octetMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>&
info) |
| 3469 { | 3469 { |
| 3470 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 3470 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 3471 TestObjectPythonV8Internal::octetMethodMethod(info); | 3471 TestObjectPythonV8Internal::octetMethodMethod(info); |
| 3472 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3472 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3473 } | 3473 } |
| 3474 | 3474 |
| 3475 static void shortMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) | 3475 static void shortMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| 3476 { | 3476 { |
| 3477 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3477 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3478 v8SetReturnValueInt(info, imp->shortMethod()); | 3478 v8SetReturnValueInt(info, imp->shortMethod()); |
| 3479 } | 3479 } |
| 3480 | 3480 |
| 3481 static void shortMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>&
info) | 3481 static void shortMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>&
info) |
| 3482 { | 3482 { |
| 3483 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 3483 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 3484 TestObjectPythonV8Internal::shortMethodMethod(info); | 3484 TestObjectPythonV8Internal::shortMethodMethod(info); |
| 3485 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3485 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3486 } | 3486 } |
| 3487 | 3487 |
| 3488 static void unsignedLongMethodMethod(const v8::FunctionCallbackInfo<v8::Value>&
info) | 3488 static void unsignedLongMethodMethod(const v8::FunctionCallbackInfo<v8::Value>&
info) |
| 3489 { | 3489 { |
| 3490 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3490 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3491 v8SetReturnValueUnsigned(info, imp->unsignedLongMethod()); | 3491 v8SetReturnValueUnsigned(info, imp->unsignedLongMethod()); |
| 3492 } | 3492 } |
| 3493 | 3493 |
| 3494 static void unsignedLongMethodMethodCallback(const v8::FunctionCallbackInfo<v8::
Value>& info) | 3494 static void unsignedLongMethodMethodCallback(const v8::FunctionCallbackInfo<v8::
Value>& info) |
| 3495 { | 3495 { |
| 3496 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 3496 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 3497 TestObjectPythonV8Internal::unsignedLongMethodMethod(info); | 3497 TestObjectPythonV8Internal::unsignedLongMethodMethod(info); |
| 3498 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3498 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3499 } | 3499 } |
| 3500 | 3500 |
| 3501 static void unsignedLongLongMethodMethod(const v8::FunctionCallbackInfo<v8::Valu
e>& info) | 3501 static void unsignedLongLongMethodMethod(const v8::FunctionCallbackInfo<v8::Valu
e>& info) |
| 3502 { | 3502 { |
| 3503 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3503 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3504 v8SetReturnValue(info, static_cast<double>(imp->unsignedLongLongMethod())); | 3504 v8SetReturnValue(info, static_cast<double>(imp->unsignedLongLongMethod())); |
| 3505 } | 3505 } |
| 3506 | 3506 |
| 3507 static void unsignedLongLongMethodMethodCallback(const v8::FunctionCallbackInfo<
v8::Value>& info) | 3507 static void unsignedLongLongMethodMethodCallback(const v8::FunctionCallbackInfo<
v8::Value>& info) |
| 3508 { | 3508 { |
| 3509 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 3509 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 3510 TestObjectPythonV8Internal::unsignedLongLongMethodMethod(info); | 3510 TestObjectPythonV8Internal::unsignedLongLongMethodMethod(info); |
| 3511 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3511 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3512 } | 3512 } |
| 3513 | 3513 |
| 3514 static void unsignedShortMethodMethod(const v8::FunctionCallbackInfo<v8::Value>&
info) | 3514 static void unsignedShortMethodMethod(const v8::FunctionCallbackInfo<v8::Value>&
info) |
| 3515 { | 3515 { |
| 3516 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3516 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3517 v8SetReturnValueUnsigned(info, imp->unsignedShortMethod()); | 3517 v8SetReturnValueUnsigned(info, imp->unsignedShortMethod()); |
| 3518 } | 3518 } |
| 3519 | 3519 |
| 3520 static void unsignedShortMethodMethodCallback(const v8::FunctionCallbackInfo<v8:
:Value>& info) | 3520 static void unsignedShortMethodMethodCallback(const v8::FunctionCallbackInfo<v8:
:Value>& info) |
| 3521 { | 3521 { |
| 3522 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 3522 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 3523 TestObjectPythonV8Internal::unsignedShortMethodMethod(info); | 3523 TestObjectPythonV8Internal::unsignedShortMethodMethod(info); |
| 3524 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3524 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3525 } | 3525 } |
| 3526 | 3526 |
| 3527 static void voidMethodDateArgMethod(const v8::FunctionCallbackInfo<v8::Value>& i
nfo) | 3527 static void voidMethodDateArgMethod(const v8::FunctionCallbackInfo<v8::Value>& i
nfo) |
| 3528 { | 3528 { |
| 3529 if (UNLIKELY(info.Length() < 1)) { | 3529 if (UNLIKELY(info.Length() < 1)) { |
| 3530 throwTypeError(ExceptionMessages::failedToExecute("voidMethodDateArg", "
TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length())), inf
o.GetIsolate()); | 3530 throwTypeError(ExceptionMessages::failedToExecute("voidMethodDateArg", "
TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length())), inf
o.GetIsolate()); |
| 3531 return; | 3531 return; |
| 3532 } | 3532 } |
| 3533 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3533 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3534 V8TRYCATCH_VOID(double, dateArg, toWebCoreDate(info[0])); | 3534 V8TRYCATCH_VOID(double, dateArg, toWebCoreDate(info[0])); |
| 3535 imp->voidMethodDateArg(dateArg); | 3535 imp->voidMethodDateArg(dateArg); |
| 3536 } | 3536 } |
| 3537 | 3537 |
| 3538 static void voidMethodDateArgMethodCallback(const v8::FunctionCallbackInfo<v8::V
alue>& info) | 3538 static void voidMethodDateArgMethodCallback(const v8::FunctionCallbackInfo<v8::V
alue>& info) |
| 3539 { | 3539 { |
| 3540 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 3540 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 3541 TestObjectPythonV8Internal::voidMethodDateArgMethod(info); | 3541 TestObjectPythonV8Internal::voidMethodDateArgMethod(info); |
| 3542 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3542 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3543 } | 3543 } |
| 3544 | 3544 |
| 3545 static void voidMethodStringArgMethod(const v8::FunctionCallbackInfo<v8::Value>&
info) | 3545 static void voidMethodStringArgMethod(const v8::FunctionCallbackInfo<v8::Value>&
info) |
| 3546 { | 3546 { |
| 3547 if (UNLIKELY(info.Length() < 1)) { | 3547 if (UNLIKELY(info.Length() < 1)) { |
| 3548 throwTypeError(ExceptionMessages::failedToExecute("voidMethodStringArg",
"TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length())), i
nfo.GetIsolate()); | 3548 throwTypeError(ExceptionMessages::failedToExecute("voidMethodStringArg",
"TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length())), i
nfo.GetIsolate()); |
| 3549 return; | 3549 return; |
| 3550 } | 3550 } |
| 3551 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3551 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3552 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, stringArg, info[0])
; | 3552 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, stringArg, info[0])
; |
| 3553 imp->voidMethodStringArg(stringArg); | 3553 imp->voidMethodStringArg(stringArg); |
| 3554 } | 3554 } |
| 3555 | 3555 |
| 3556 static void voidMethodStringArgMethodCallback(const v8::FunctionCallbackInfo<v8:
:Value>& info) | 3556 static void voidMethodStringArgMethodCallback(const v8::FunctionCallbackInfo<v8:
:Value>& info) |
| 3557 { | 3557 { |
| 3558 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 3558 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 3559 TestObjectPythonV8Internal::voidMethodStringArgMethod(info); | 3559 TestObjectPythonV8Internal::voidMethodStringArgMethod(info); |
| 3560 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3560 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3561 } | 3561 } |
| 3562 | 3562 |
| 3563 static void voidMethodBooleanArgMethod(const v8::FunctionCallbackInfo<v8::Value>
& info) | 3563 static void voidMethodBooleanArgMethod(const v8::FunctionCallbackInfo<v8::Value>
& info) |
| 3564 { | 3564 { |
| 3565 if (UNLIKELY(info.Length() < 1)) { | 3565 if (UNLIKELY(info.Length() < 1)) { |
| 3566 throwTypeError(ExceptionMessages::failedToExecute("voidMethodBooleanArg"
, "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length())),
info.GetIsolate()); | 3566 throwTypeError(ExceptionMessages::failedToExecute("voidMethodBooleanArg"
, "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length())),
info.GetIsolate()); |
| 3567 return; | 3567 return; |
| 3568 } | 3568 } |
| 3569 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3569 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3570 V8TRYCATCH_VOID(bool, booleanArg, info[0]->BooleanValue()); | 3570 V8TRYCATCH_VOID(bool, booleanArg, info[0]->BooleanValue()); |
| 3571 imp->voidMethodBooleanArg(booleanArg); | 3571 imp->voidMethodBooleanArg(booleanArg); |
| 3572 } | 3572 } |
| 3573 | 3573 |
| 3574 static void voidMethodBooleanArgMethodCallback(const v8::FunctionCallbackInfo<v8
::Value>& info) | 3574 static void voidMethodBooleanArgMethodCallback(const v8::FunctionCallbackInfo<v8
::Value>& info) |
| 3575 { | 3575 { |
| 3576 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 3576 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 3577 TestObjectPythonV8Internal::voidMethodBooleanArgMethod(info); | 3577 TestObjectPythonV8Internal::voidMethodBooleanArgMethod(info); |
| 3578 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3578 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3579 } | 3579 } |
| 3580 | 3580 |
| 3581 static void voidMethodByteArgMethod(const v8::FunctionCallbackInfo<v8::Value>& i
nfo) | 3581 static void voidMethodByteArgMethod(const v8::FunctionCallbackInfo<v8::Value>& i
nfo) |
| 3582 { | 3582 { |
| 3583 ExceptionState exceptionState(ExceptionState::ExecutionContext, "voidMethodB
yteArg", "TestObjectPython", info.Holder(), info.GetIsolate()); | 3583 ExceptionState exceptionState(ExceptionState::ExecutionContext, "voidMethodB
yteArg", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 3584 if (UNLIKELY(info.Length() < 1)) { | 3584 if (UNLIKELY(info.Length() < 1)) { |
| 3585 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); | 3585 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); |
| 3586 exceptionState.throwIfNeeded(); | 3586 exceptionState.throwIfNeeded(); |
| 3587 return; | 3587 return; |
| 3588 } | 3588 } |
| 3589 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3589 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3590 V8TRYCATCH_EXCEPTION_VOID(int, byteArg, toInt8(info[0], exceptionState), exc
eptionState); | 3590 V8TRYCATCH_EXCEPTION_VOID(int, byteArg, toInt8(info[0], exceptionState), exc
eptionState); |
| 3591 imp->voidMethodByteArg(byteArg); | 3591 imp->voidMethodByteArg(byteArg); |
| 3592 } | 3592 } |
| 3593 | 3593 |
| 3594 static void voidMethodByteArgMethodCallback(const v8::FunctionCallbackInfo<v8::V
alue>& info) | 3594 static void voidMethodByteArgMethodCallback(const v8::FunctionCallbackInfo<v8::V
alue>& info) |
| 3595 { | 3595 { |
| 3596 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 3596 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 3597 TestObjectPythonV8Internal::voidMethodByteArgMethod(info); | 3597 TestObjectPythonV8Internal::voidMethodByteArgMethod(info); |
| 3598 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3598 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3599 } | 3599 } |
| 3600 | 3600 |
| 3601 static void voidMethodDoubleArgMethod(const v8::FunctionCallbackInfo<v8::Value>&
info) | 3601 static void voidMethodDoubleArgMethod(const v8::FunctionCallbackInfo<v8::Value>&
info) |
| 3602 { | 3602 { |
| 3603 if (UNLIKELY(info.Length() < 1)) { | 3603 if (UNLIKELY(info.Length() < 1)) { |
| 3604 throwTypeError(ExceptionMessages::failedToExecute("voidMethodDoubleArg",
"TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length())), i
nfo.GetIsolate()); | 3604 throwTypeError(ExceptionMessages::failedToExecute("voidMethodDoubleArg",
"TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length())), i
nfo.GetIsolate()); |
| 3605 return; | 3605 return; |
| 3606 } | 3606 } |
| 3607 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3607 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3608 V8TRYCATCH_VOID(double, doubleArg, static_cast<double>(info[0]->NumberValue(
))); | 3608 V8TRYCATCH_VOID(double, doubleArg, static_cast<double>(info[0]->NumberValue(
))); |
| 3609 imp->voidMethodDoubleArg(doubleArg); | 3609 imp->voidMethodDoubleArg(doubleArg); |
| 3610 } | 3610 } |
| 3611 | 3611 |
| 3612 static void voidMethodDoubleArgMethodCallback(const v8::FunctionCallbackInfo<v8:
:Value>& info) | 3612 static void voidMethodDoubleArgMethodCallback(const v8::FunctionCallbackInfo<v8:
:Value>& info) |
| 3613 { | 3613 { |
| 3614 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 3614 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 3615 TestObjectPythonV8Internal::voidMethodDoubleArgMethod(info); | 3615 TestObjectPythonV8Internal::voidMethodDoubleArgMethod(info); |
| 3616 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3616 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3617 } | 3617 } |
| 3618 | 3618 |
| 3619 static void voidMethodFloatArgMethod(const v8::FunctionCallbackInfo<v8::Value>&
info) | 3619 static void voidMethodFloatArgMethod(const v8::FunctionCallbackInfo<v8::Value>&
info) |
| 3620 { | 3620 { |
| 3621 if (UNLIKELY(info.Length() < 1)) { | 3621 if (UNLIKELY(info.Length() < 1)) { |
| 3622 throwTypeError(ExceptionMessages::failedToExecute("voidMethodFloatArg",
"TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length())), in
fo.GetIsolate()); | 3622 throwTypeError(ExceptionMessages::failedToExecute("voidMethodFloatArg",
"TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length())), in
fo.GetIsolate()); |
| 3623 return; | 3623 return; |
| 3624 } | 3624 } |
| 3625 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3625 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3626 V8TRYCATCH_VOID(float, floatArg, static_cast<float>(info[0]->NumberValue()))
; | 3626 V8TRYCATCH_VOID(float, floatArg, static_cast<float>(info[0]->NumberValue()))
; |
| 3627 imp->voidMethodFloatArg(floatArg); | 3627 imp->voidMethodFloatArg(floatArg); |
| 3628 } | 3628 } |
| 3629 | 3629 |
| 3630 static void voidMethodFloatArgMethodCallback(const v8::FunctionCallbackInfo<v8::
Value>& info) | 3630 static void voidMethodFloatArgMethodCallback(const v8::FunctionCallbackInfo<v8::
Value>& info) |
| 3631 { | 3631 { |
| 3632 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 3632 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 3633 TestObjectPythonV8Internal::voidMethodFloatArgMethod(info); | 3633 TestObjectPythonV8Internal::voidMethodFloatArgMethod(info); |
| 3634 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3634 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3635 } | 3635 } |
| 3636 | 3636 |
| 3637 static void voidMethodLongArgMethod(const v8::FunctionCallbackInfo<v8::Value>& i
nfo) | 3637 static void voidMethodLongArgMethod(const v8::FunctionCallbackInfo<v8::Value>& i
nfo) |
| 3638 { | 3638 { |
| 3639 ExceptionState exceptionState(ExceptionState::ExecutionContext, "voidMethodL
ongArg", "TestObjectPython", info.Holder(), info.GetIsolate()); | 3639 ExceptionState exceptionState(ExceptionState::ExecutionContext, "voidMethodL
ongArg", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 3640 if (UNLIKELY(info.Length() < 1)) { | 3640 if (UNLIKELY(info.Length() < 1)) { |
| 3641 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); | 3641 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); |
| 3642 exceptionState.throwIfNeeded(); | 3642 exceptionState.throwIfNeeded(); |
| 3643 return; | 3643 return; |
| 3644 } | 3644 } |
| 3645 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3645 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3646 V8TRYCATCH_EXCEPTION_VOID(int, longArg, toInt32(info[0], exceptionState), ex
ceptionState); | 3646 V8TRYCATCH_EXCEPTION_VOID(int, longArg, toInt32(info[0], exceptionState), ex
ceptionState); |
| 3647 imp->voidMethodLongArg(longArg); | 3647 imp->voidMethodLongArg(longArg); |
| 3648 } | 3648 } |
| 3649 | 3649 |
| 3650 static void voidMethodLongArgMethodCallback(const v8::FunctionCallbackInfo<v8::V
alue>& info) | 3650 static void voidMethodLongArgMethodCallback(const v8::FunctionCallbackInfo<v8::V
alue>& info) |
| 3651 { | 3651 { |
| 3652 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 3652 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 3653 TestObjectPythonV8Internal::voidMethodLongArgMethod(info); | 3653 TestObjectPythonV8Internal::voidMethodLongArgMethod(info); |
| 3654 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3654 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3655 } | 3655 } |
| 3656 | 3656 |
| 3657 static void voidMethodLongLongArgMethod(const v8::FunctionCallbackInfo<v8::Value
>& info) | 3657 static void voidMethodLongLongArgMethod(const v8::FunctionCallbackInfo<v8::Value
>& info) |
| 3658 { | 3658 { |
| 3659 ExceptionState exceptionState(ExceptionState::ExecutionContext, "voidMethodL
ongLongArg", "TestObjectPython", info.Holder(), info.GetIsolate()); | 3659 ExceptionState exceptionState(ExceptionState::ExecutionContext, "voidMethodL
ongLongArg", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 3660 if (UNLIKELY(info.Length() < 1)) { | 3660 if (UNLIKELY(info.Length() < 1)) { |
| 3661 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); | 3661 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); |
| 3662 exceptionState.throwIfNeeded(); | 3662 exceptionState.throwIfNeeded(); |
| 3663 return; | 3663 return; |
| 3664 } | 3664 } |
| 3665 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3665 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3666 V8TRYCATCH_EXCEPTION_VOID(long long, longLongArg, toInt64(info[0], exception
State), exceptionState); | 3666 V8TRYCATCH_EXCEPTION_VOID(long long, longLongArg, toInt64(info[0], exception
State), exceptionState); |
| 3667 imp->voidMethodLongLongArg(longLongArg); | 3667 imp->voidMethodLongLongArg(longLongArg); |
| 3668 } | 3668 } |
| 3669 | 3669 |
| 3670 static void voidMethodLongLongArgMethodCallback(const v8::FunctionCallbackInfo<v
8::Value>& info) | 3670 static void voidMethodLongLongArgMethodCallback(const v8::FunctionCallbackInfo<v
8::Value>& info) |
| 3671 { | 3671 { |
| 3672 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 3672 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 3673 TestObjectPythonV8Internal::voidMethodLongLongArgMethod(info); | 3673 TestObjectPythonV8Internal::voidMethodLongLongArgMethod(info); |
| 3674 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3674 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3675 } | 3675 } |
| 3676 | 3676 |
| 3677 static void voidMethodOctetArgMethod(const v8::FunctionCallbackInfo<v8::Value>&
info) | 3677 static void voidMethodOctetArgMethod(const v8::FunctionCallbackInfo<v8::Value>&
info) |
| 3678 { | 3678 { |
| 3679 ExceptionState exceptionState(ExceptionState::ExecutionContext, "voidMethodO
ctetArg", "TestObjectPython", info.Holder(), info.GetIsolate()); | 3679 ExceptionState exceptionState(ExceptionState::ExecutionContext, "voidMethodO
ctetArg", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 3680 if (UNLIKELY(info.Length() < 1)) { | 3680 if (UNLIKELY(info.Length() < 1)) { |
| 3681 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); | 3681 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); |
| 3682 exceptionState.throwIfNeeded(); | 3682 exceptionState.throwIfNeeded(); |
| 3683 return; | 3683 return; |
| 3684 } | 3684 } |
| 3685 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3685 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3686 V8TRYCATCH_EXCEPTION_VOID(unsigned, octetArg, toUInt8(info[0], exceptionStat
e), exceptionState); | 3686 V8TRYCATCH_EXCEPTION_VOID(unsigned, octetArg, toUInt8(info[0], exceptionStat
e), exceptionState); |
| 3687 imp->voidMethodOctetArg(octetArg); | 3687 imp->voidMethodOctetArg(octetArg); |
| 3688 } | 3688 } |
| 3689 | 3689 |
| 3690 static void voidMethodOctetArgMethodCallback(const v8::FunctionCallbackInfo<v8::
Value>& info) | 3690 static void voidMethodOctetArgMethodCallback(const v8::FunctionCallbackInfo<v8::
Value>& info) |
| 3691 { | 3691 { |
| 3692 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 3692 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 3693 TestObjectPythonV8Internal::voidMethodOctetArgMethod(info); | 3693 TestObjectPythonV8Internal::voidMethodOctetArgMethod(info); |
| 3694 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3694 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3695 } | 3695 } |
| 3696 | 3696 |
| 3697 static void voidMethodShortArgMethod(const v8::FunctionCallbackInfo<v8::Value>&
info) | 3697 static void voidMethodShortArgMethod(const v8::FunctionCallbackInfo<v8::Value>&
info) |
| 3698 { | 3698 { |
| 3699 ExceptionState exceptionState(ExceptionState::ExecutionContext, "voidMethodS
hortArg", "TestObjectPython", info.Holder(), info.GetIsolate()); | 3699 ExceptionState exceptionState(ExceptionState::ExecutionContext, "voidMethodS
hortArg", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 3700 if (UNLIKELY(info.Length() < 1)) { | 3700 if (UNLIKELY(info.Length() < 1)) { |
| 3701 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); | 3701 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); |
| 3702 exceptionState.throwIfNeeded(); | 3702 exceptionState.throwIfNeeded(); |
| 3703 return; | 3703 return; |
| 3704 } | 3704 } |
| 3705 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3705 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3706 V8TRYCATCH_EXCEPTION_VOID(int, shortArg, toInt16(info[0], exceptionState), e
xceptionState); | 3706 V8TRYCATCH_EXCEPTION_VOID(int, shortArg, toInt16(info[0], exceptionState), e
xceptionState); |
| 3707 imp->voidMethodShortArg(shortArg); | 3707 imp->voidMethodShortArg(shortArg); |
| 3708 } | 3708 } |
| 3709 | 3709 |
| 3710 static void voidMethodShortArgMethodCallback(const v8::FunctionCallbackInfo<v8::
Value>& info) | 3710 static void voidMethodShortArgMethodCallback(const v8::FunctionCallbackInfo<v8::
Value>& info) |
| 3711 { | 3711 { |
| 3712 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 3712 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 3713 TestObjectPythonV8Internal::voidMethodShortArgMethod(info); | 3713 TestObjectPythonV8Internal::voidMethodShortArgMethod(info); |
| 3714 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3714 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3715 } | 3715 } |
| 3716 | 3716 |
| 3717 static void voidMethodUnsignedLongArgMethod(const v8::FunctionCallbackInfo<v8::V
alue>& info) | 3717 static void voidMethodUnsignedLongArgMethod(const v8::FunctionCallbackInfo<v8::V
alue>& info) |
| 3718 { | 3718 { |
| 3719 ExceptionState exceptionState(ExceptionState::ExecutionContext, "voidMethodU
nsignedLongArg", "TestObjectPython", info.Holder(), info.GetIsolate()); | 3719 ExceptionState exceptionState(ExceptionState::ExecutionContext, "voidMethodU
nsignedLongArg", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 3720 if (UNLIKELY(info.Length() < 1)) { | 3720 if (UNLIKELY(info.Length() < 1)) { |
| 3721 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); | 3721 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); |
| 3722 exceptionState.throwIfNeeded(); | 3722 exceptionState.throwIfNeeded(); |
| 3723 return; | 3723 return; |
| 3724 } | 3724 } |
| 3725 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3725 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3726 V8TRYCATCH_EXCEPTION_VOID(unsigned, unsignedLongArg, toUInt32(info[0], excep
tionState), exceptionState); | 3726 V8TRYCATCH_EXCEPTION_VOID(unsigned, unsignedLongArg, toUInt32(info[0], excep
tionState), exceptionState); |
| 3727 imp->voidMethodUnsignedLongArg(unsignedLongArg); | 3727 imp->voidMethodUnsignedLongArg(unsignedLongArg); |
| 3728 } | 3728 } |
| 3729 | 3729 |
| 3730 static void voidMethodUnsignedLongArgMethodCallback(const v8::FunctionCallbackIn
fo<v8::Value>& info) | 3730 static void voidMethodUnsignedLongArgMethodCallback(const v8::FunctionCallbackIn
fo<v8::Value>& info) |
| 3731 { | 3731 { |
| 3732 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 3732 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 3733 TestObjectPythonV8Internal::voidMethodUnsignedLongArgMethod(info); | 3733 TestObjectPythonV8Internal::voidMethodUnsignedLongArgMethod(info); |
| 3734 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3734 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3735 } | 3735 } |
| 3736 | 3736 |
| 3737 static void voidMethodUnsignedLongLongArgMethod(const v8::FunctionCallbackInfo<v
8::Value>& info) | 3737 static void voidMethodUnsignedLongLongArgMethod(const v8::FunctionCallbackInfo<v
8::Value>& info) |
| 3738 { | 3738 { |
| 3739 ExceptionState exceptionState(ExceptionState::ExecutionContext, "voidMethodU
nsignedLongLongArg", "TestObjectPython", info.Holder(), info.GetIsolate()); | 3739 ExceptionState exceptionState(ExceptionState::ExecutionContext, "voidMethodU
nsignedLongLongArg", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 3740 if (UNLIKELY(info.Length() < 1)) { | 3740 if (UNLIKELY(info.Length() < 1)) { |
| 3741 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); | 3741 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); |
| 3742 exceptionState.throwIfNeeded(); | 3742 exceptionState.throwIfNeeded(); |
| 3743 return; | 3743 return; |
| 3744 } | 3744 } |
| 3745 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3745 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3746 V8TRYCATCH_EXCEPTION_VOID(unsigned long long, unsignedLongLongArg, toUInt64(
info[0], exceptionState), exceptionState); | 3746 V8TRYCATCH_EXCEPTION_VOID(unsigned long long, unsignedLongLongArg, toUInt64(
info[0], exceptionState), exceptionState); |
| 3747 imp->voidMethodUnsignedLongLongArg(unsignedLongLongArg); | 3747 imp->voidMethodUnsignedLongLongArg(unsignedLongLongArg); |
| 3748 } | 3748 } |
| 3749 | 3749 |
| 3750 static void voidMethodUnsignedLongLongArgMethodCallback(const v8::FunctionCallba
ckInfo<v8::Value>& info) | 3750 static void voidMethodUnsignedLongLongArgMethodCallback(const v8::FunctionCallba
ckInfo<v8::Value>& info) |
| 3751 { | 3751 { |
| 3752 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 3752 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 3753 TestObjectPythonV8Internal::voidMethodUnsignedLongLongArgMethod(info); | 3753 TestObjectPythonV8Internal::voidMethodUnsignedLongLongArgMethod(info); |
| 3754 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3754 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3755 } | 3755 } |
| 3756 | 3756 |
| 3757 static void voidMethodUnsignedShortArgMethod(const v8::FunctionCallbackInfo<v8::
Value>& info) | 3757 static void voidMethodUnsignedShortArgMethod(const v8::FunctionCallbackInfo<v8::
Value>& info) |
| 3758 { | 3758 { |
| 3759 ExceptionState exceptionState(ExceptionState::ExecutionContext, "voidMethodU
nsignedShortArg", "TestObjectPython", info.Holder(), info.GetIsolate()); | 3759 ExceptionState exceptionState(ExceptionState::ExecutionContext, "voidMethodU
nsignedShortArg", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 3760 if (UNLIKELY(info.Length() < 1)) { | 3760 if (UNLIKELY(info.Length() < 1)) { |
| 3761 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); | 3761 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); |
| 3762 exceptionState.throwIfNeeded(); | 3762 exceptionState.throwIfNeeded(); |
| 3763 return; | 3763 return; |
| 3764 } | 3764 } |
| 3765 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3765 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3766 V8TRYCATCH_EXCEPTION_VOID(unsigned, unsignedShortArg, toUInt16(info[0], exce
ptionState), exceptionState); | 3766 V8TRYCATCH_EXCEPTION_VOID(unsigned, unsignedShortArg, toUInt16(info[0], exce
ptionState), exceptionState); |
| 3767 imp->voidMethodUnsignedShortArg(unsignedShortArg); | 3767 imp->voidMethodUnsignedShortArg(unsignedShortArg); |
| 3768 } | 3768 } |
| 3769 | 3769 |
| 3770 static void voidMethodUnsignedShortArgMethodCallback(const v8::FunctionCallbackI
nfo<v8::Value>& info) | 3770 static void voidMethodUnsignedShortArgMethodCallback(const v8::FunctionCallbackI
nfo<v8::Value>& info) |
| 3771 { | 3771 { |
| 3772 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 3772 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 3773 TestObjectPythonV8Internal::voidMethodUnsignedShortArgMethod(info); | 3773 TestObjectPythonV8Internal::voidMethodUnsignedShortArgMethod(info); |
| 3774 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3774 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3775 } | 3775 } |
| 3776 | 3776 |
| 3777 static void testInterfaceEmptyMethodMethod(const v8::FunctionCallbackInfo<v8::Va
lue>& info) | 3777 static void testInterfaceEmptyMethodMethod(const v8::FunctionCallbackInfo<v8::Va
lue>& info) |
| 3778 { | 3778 { |
| 3779 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3779 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3780 v8SetReturnValue(info, imp->testInterfaceEmptyMethod()); | 3780 v8SetReturnValue(info, imp->testInterfaceEmptyMethod()); |
| 3781 } | 3781 } |
| 3782 | 3782 |
| 3783 static void testInterfaceEmptyMethodMethodCallback(const v8::FunctionCallbackInf
o<v8::Value>& info) | 3783 static void testInterfaceEmptyMethodMethodCallback(const v8::FunctionCallbackInf
o<v8::Value>& info) |
| 3784 { | 3784 { |
| 3785 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 3785 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 3786 TestObjectPythonV8Internal::testInterfaceEmptyMethodMethod(info); | 3786 TestObjectPythonV8Internal::testInterfaceEmptyMethodMethod(info); |
| 3787 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3787 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3788 } | 3788 } |
| 3789 | 3789 |
| 3790 static void voidMethodTestInterfaceEmptyArgMethod(const v8::FunctionCallbackInfo
<v8::Value>& info) | 3790 static void voidMethodTestInterfaceEmptyArgMethod(const v8::FunctionCallbackInfo
<v8::Value>& info) |
| 3791 { | 3791 { |
| 3792 if (UNLIKELY(info.Length() < 1)) { | 3792 if (UNLIKELY(info.Length() < 1)) { |
| 3793 throwTypeError(ExceptionMessages::failedToExecute("voidMethodTestInterfa
ceEmptyArg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.L
ength())), info.GetIsolate()); | 3793 throwTypeError(ExceptionMessages::failedToExecute("voidMethodTestInterfa
ceEmptyArg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.L
ength())), info.GetIsolate()); |
| 3794 return; | 3794 return; |
| 3795 } | 3795 } |
| 3796 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3796 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3797 V8TRYCATCH_VOID(TestInterfaceEmpty*, testInterfaceEmptyArg, V8TestInterfaceE
mpty::hasInstance(info[0], info.GetIsolate(), worldType(info.GetIsolate())) ? V8
TestInterfaceEmpty::toNative(v8::Handle<v8::Object>::Cast(info[0])) : 0); | 3797 V8TRYCATCH_VOID(TestInterfaceEmpty*, testInterfaceEmptyArg, V8TestInterfaceE
mpty::hasInstance(info[0], info.GetIsolate(), worldType(info.GetIsolate())) ? V8
TestInterfaceEmpty::toNative(v8::Handle<v8::Object>::Cast(info[0])) : 0); |
| 3798 imp->voidMethodTestInterfaceEmptyArg(testInterfaceEmptyArg); | 3798 imp->voidMethodTestInterfaceEmptyArg(testInterfaceEmptyArg); |
| 3799 } | 3799 } |
| 3800 | 3800 |
| 3801 static void voidMethodTestInterfaceEmptyArgMethodCallback(const v8::FunctionCall
backInfo<v8::Value>& info) | 3801 static void voidMethodTestInterfaceEmptyArgMethodCallback(const v8::FunctionCall
backInfo<v8::Value>& info) |
| 3802 { | 3802 { |
| 3803 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 3803 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 3804 TestObjectPythonV8Internal::voidMethodTestInterfaceEmptyArgMethod(info); | 3804 TestObjectPythonV8Internal::voidMethodTestInterfaceEmptyArgMethod(info); |
| 3805 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3805 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3806 } | 3806 } |
| 3807 | 3807 |
| 3808 static void voidMethodLongArgTestInterfaceEmptyArgMethod(const v8::FunctionCallb
ackInfo<v8::Value>& info) | 3808 static void voidMethodLongArgTestInterfaceEmptyArgMethod(const v8::FunctionCallb
ackInfo<v8::Value>& info) |
| 3809 { | 3809 { |
| 3810 ExceptionState exceptionState(ExceptionState::ExecutionContext, "voidMethodL
ongArgTestInterfaceEmptyArg", "TestObjectPython", info.Holder(), info.GetIsolate
()); | 3810 ExceptionState exceptionState(ExceptionState::ExecutionContext, "voidMethodL
ongArgTestInterfaceEmptyArg", "TestObjectPython", info.Holder(), info.GetIsolate
()); |
| 3811 if (UNLIKELY(info.Length() < 2)) { | 3811 if (UNLIKELY(info.Length() < 2)) { |
| 3812 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(2, i
nfo.Length())); | 3812 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(2, i
nfo.Length())); |
| 3813 exceptionState.throwIfNeeded(); | 3813 exceptionState.throwIfNeeded(); |
| 3814 return; | 3814 return; |
| 3815 } | 3815 } |
| 3816 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3816 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3817 V8TRYCATCH_EXCEPTION_VOID(int, longArg, toInt32(info[0], exceptionState), ex
ceptionState); | 3817 V8TRYCATCH_EXCEPTION_VOID(int, longArg, toInt32(info[0], exceptionState), ex
ceptionState); |
| 3818 V8TRYCATCH_VOID(TestInterfaceEmpty*, testInterfaceEmptyArg, V8TestInterfaceE
mpty::hasInstance(info[1], info.GetIsolate(), worldType(info.GetIsolate())) ? V8
TestInterfaceEmpty::toNative(v8::Handle<v8::Object>::Cast(info[1])) : 0); | 3818 V8TRYCATCH_VOID(TestInterfaceEmpty*, testInterfaceEmptyArg, V8TestInterfaceE
mpty::hasInstance(info[1], info.GetIsolate(), worldType(info.GetIsolate())) ? V8
TestInterfaceEmpty::toNative(v8::Handle<v8::Object>::Cast(info[1])) : 0); |
| 3819 imp->voidMethodLongArgTestInterfaceEmptyArg(longArg, testInterfaceEmptyArg); | 3819 imp->voidMethodLongArgTestInterfaceEmptyArg(longArg, testInterfaceEmptyArg); |
| 3820 } | 3820 } |
| 3821 | 3821 |
| 3822 static void voidMethodLongArgTestInterfaceEmptyArgMethodCallback(const v8::Funct
ionCallbackInfo<v8::Value>& info) | 3822 static void voidMethodLongArgTestInterfaceEmptyArgMethodCallback(const v8::Funct
ionCallbackInfo<v8::Value>& info) |
| 3823 { | 3823 { |
| 3824 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 3824 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 3825 TestObjectPythonV8Internal::voidMethodLongArgTestInterfaceEmptyArgMethod(inf
o); | 3825 TestObjectPythonV8Internal::voidMethodLongArgTestInterfaceEmptyArgMethod(inf
o); |
| 3826 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3826 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3827 } | 3827 } |
| 3828 | 3828 |
| 3829 static void voidCallbackFunctionMethodMethod(const v8::FunctionCallbackInfo<v8::
Value>& info) | 3829 static void voidCallbackFunctionMethodMethod(const v8::FunctionCallbackInfo<v8::
Value>& info) |
| 3830 { | 3830 { |
| 3831 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3831 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3832 v8SetReturnValue(info, imp->voidCallbackFunctionMethod().v8Value()); | 3832 v8SetReturnValue(info, imp->voidCallbackFunctionMethod().v8Value()); |
| 3833 } | 3833 } |
| 3834 | 3834 |
| 3835 static void voidCallbackFunctionMethodMethodCallback(const v8::FunctionCallbackI
nfo<v8::Value>& info) | 3835 static void voidCallbackFunctionMethodMethodCallback(const v8::FunctionCallbackI
nfo<v8::Value>& info) |
| 3836 { | 3836 { |
| 3837 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 3837 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 3838 TestObjectPythonV8Internal::voidCallbackFunctionMethodMethod(info); | 3838 TestObjectPythonV8Internal::voidCallbackFunctionMethodMethod(info); |
| 3839 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3839 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3840 } | 3840 } |
| 3841 | 3841 |
| 3842 static void anyCallbackFunctionOptionalAnyArgMethodMethod(const v8::FunctionCall
backInfo<v8::Value>& info) | 3842 static void anyCallbackFunctionOptionalAnyArgMethodMethod(const v8::FunctionCall
backInfo<v8::Value>& info) |
| 3843 { | 3843 { |
| 3844 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3844 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3845 v8SetReturnValue(info, imp->anyCallbackFunctionOptionalAnyArgMethod().v8Valu
e()); | 3845 v8SetReturnValue(info, imp->anyCallbackFunctionOptionalAnyArgMethod().v8Valu
e()); |
| 3846 } | 3846 } |
| 3847 | 3847 |
| 3848 static void anyCallbackFunctionOptionalAnyArgMethodMethodCallback(const v8::Func
tionCallbackInfo<v8::Value>& info) | 3848 static void anyCallbackFunctionOptionalAnyArgMethodMethodCallback(const v8::Func
tionCallbackInfo<v8::Value>& info) |
| 3849 { | 3849 { |
| 3850 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 3850 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 3851 TestObjectPythonV8Internal::anyCallbackFunctionOptionalAnyArgMethodMethod(in
fo); | 3851 TestObjectPythonV8Internal::anyCallbackFunctionOptionalAnyArgMethodMethod(in
fo); |
| 3852 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3852 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3853 } | 3853 } |
| 3854 | 3854 |
| 3855 static void voidMethodVoidCallbackFunctionArgMethod(const v8::FunctionCallbackIn
fo<v8::Value>& info) | 3855 static void voidMethodVoidCallbackFunctionArgMethod(const v8::FunctionCallbackIn
fo<v8::Value>& info) |
| 3856 { | 3856 { |
| 3857 if (UNLIKELY(info.Length() < 1)) { | 3857 if (UNLIKELY(info.Length() < 1)) { |
| 3858 throwTypeError(ExceptionMessages::failedToExecute("voidMethodVoidCallbac
kFunctionArg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info
.Length())), info.GetIsolate()); | 3858 throwTypeError(ExceptionMessages::failedToExecute("voidMethodVoidCallbac
kFunctionArg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info
.Length())), info.GetIsolate()); |
| 3859 return; | 3859 return; |
| 3860 } | 3860 } |
| 3861 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3861 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3862 V8TRYCATCH_VOID(ScriptValue, voidCallbackFunctionArg, ScriptValue(info[0], i
nfo.GetIsolate())); | 3862 V8TRYCATCH_VOID(ScriptValue, voidCallbackFunctionArg, ScriptValue(info[0], i
nfo.GetIsolate())); |
| 3863 imp->voidMethodVoidCallbackFunctionArg(voidCallbackFunctionArg); | 3863 imp->voidMethodVoidCallbackFunctionArg(voidCallbackFunctionArg); |
| 3864 } | 3864 } |
| 3865 | 3865 |
| 3866 static void voidMethodVoidCallbackFunctionArgMethodCallback(const v8::FunctionCa
llbackInfo<v8::Value>& info) | 3866 static void voidMethodVoidCallbackFunctionArgMethodCallback(const v8::FunctionCa
llbackInfo<v8::Value>& info) |
| 3867 { | 3867 { |
| 3868 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 3868 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 3869 TestObjectPythonV8Internal::voidMethodVoidCallbackFunctionArgMethod(info); | 3869 TestObjectPythonV8Internal::voidMethodVoidCallbackFunctionArgMethod(info); |
| 3870 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3870 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3871 } | 3871 } |
| 3872 | 3872 |
| 3873 static void voidMethodAnyCallbackFunctionOptionalAnyArgMethod(const v8::Function
CallbackInfo<v8::Value>& info) | 3873 static void voidMethodAnyCallbackFunctionOptionalAnyArgMethod(const v8::Function
CallbackInfo<v8::Value>& info) |
| 3874 { | 3874 { |
| 3875 if (UNLIKELY(info.Length() < 1)) { | 3875 if (UNLIKELY(info.Length() < 1)) { |
| 3876 throwTypeError(ExceptionMessages::failedToExecute("voidMethodAnyCallback
FunctionOptionalAnyArg", "TestObjectPython", ExceptionMessages::notEnoughArgumen
ts(1, info.Length())), info.GetIsolate()); | 3876 throwTypeError(ExceptionMessages::failedToExecute("voidMethodAnyCallback
FunctionOptionalAnyArg", "TestObjectPython", ExceptionMessages::notEnoughArgumen
ts(1, info.Length())), info.GetIsolate()); |
| 3877 return; | 3877 return; |
| 3878 } | 3878 } |
| 3879 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3879 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3880 V8TRYCATCH_VOID(ScriptValue, anyCallbackFunctionOptionalAnyArgArg, ScriptVal
ue(info[0], info.GetIsolate())); | 3880 V8TRYCATCH_VOID(ScriptValue, anyCallbackFunctionOptionalAnyArgArg, ScriptVal
ue(info[0], info.GetIsolate())); |
| 3881 imp->voidMethodAnyCallbackFunctionOptionalAnyArg(anyCallbackFunctionOptional
AnyArgArg); | 3881 imp->voidMethodAnyCallbackFunctionOptionalAnyArg(anyCallbackFunctionOptional
AnyArgArg); |
| 3882 } | 3882 } |
| 3883 | 3883 |
| 3884 static void voidMethodAnyCallbackFunctionOptionalAnyArgMethodCallback(const v8::
FunctionCallbackInfo<v8::Value>& info) | 3884 static void voidMethodAnyCallbackFunctionOptionalAnyArgMethodCallback(const v8::
FunctionCallbackInfo<v8::Value>& info) |
| 3885 { | 3885 { |
| 3886 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 3886 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 3887 TestObjectPythonV8Internal::voidMethodAnyCallbackFunctionOptionalAnyArgMetho
d(info); | 3887 TestObjectPythonV8Internal::voidMethodAnyCallbackFunctionOptionalAnyArgMetho
d(info); |
| 3888 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3888 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3889 } | 3889 } |
| 3890 | 3890 |
| 3891 static void compareHowMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& in
fo) | 3891 static void compareHowMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& in
fo) |
| 3892 { | 3892 { |
| 3893 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3893 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3894 v8SetReturnValue(info, imp->compareHowMethod()); | 3894 v8SetReturnValue(info, imp->compareHowMethod()); |
| 3895 } | 3895 } |
| 3896 | 3896 |
| 3897 static void compareHowMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Va
lue>& info) | 3897 static void compareHowMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Va
lue>& info) |
| 3898 { | 3898 { |
| 3899 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 3899 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 3900 TestObjectPythonV8Internal::compareHowMethodMethod(info); | 3900 TestObjectPythonV8Internal::compareHowMethodMethod(info); |
| 3901 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3901 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3902 } | 3902 } |
| 3903 | 3903 |
| 3904 static void anyMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) | 3904 static void anyMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| 3905 { | 3905 { |
| 3906 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3906 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3907 v8SetReturnValue(info, imp->anyMethod().v8Value()); | 3907 v8SetReturnValue(info, imp->anyMethod().v8Value()); |
| 3908 } | 3908 } |
| 3909 | 3909 |
| 3910 static void anyMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& i
nfo) | 3910 static void anyMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& i
nfo) |
| 3911 { | 3911 { |
| 3912 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 3912 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 3913 TestObjectPythonV8Internal::anyMethodMethod(info); | 3913 TestObjectPythonV8Internal::anyMethodMethod(info); |
| 3914 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3914 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3915 } | 3915 } |
| 3916 | 3916 |
| 3917 static void voidMethodMediaQueryListListenerArgMethod(const v8::FunctionCallback
Info<v8::Value>& info) | 3917 static void voidMethodMediaQueryListListenerArgMethod(const v8::FunctionCallback
Info<v8::Value>& info) |
| 3918 { | 3918 { |
| 3919 if (UNLIKELY(info.Length() < 1)) { | 3919 if (UNLIKELY(info.Length() < 1)) { |
| 3920 throwTypeError(ExceptionMessages::failedToExecute("voidMethodMediaQueryL
istListenerArg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, in
fo.Length())), info.GetIsolate()); | 3920 throwTypeError(ExceptionMessages::failedToExecute("voidMethodMediaQueryL
istListenerArg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, in
fo.Length())), info.GetIsolate()); |
| 3921 return; | 3921 return; |
| 3922 } | 3922 } |
| 3923 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3923 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3924 V8TRYCATCH_VOID(RefPtr<MediaQueryListListener>, mediaQueryListListenerArg, M
ediaQueryListListener::create(ScriptValue(info[0], info.GetIsolate()))); | 3924 V8TRYCATCH_VOID(RefPtr<MediaQueryListListener>, mediaQueryListListenerArg, M
ediaQueryListListener::create(ScriptValue(info[0], info.GetIsolate()))); |
| 3925 imp->voidMethodMediaQueryListListenerArg(mediaQueryListListenerArg); | 3925 imp->voidMethodMediaQueryListListenerArg(mediaQueryListListenerArg); |
| 3926 } | 3926 } |
| 3927 | 3927 |
| 3928 static void voidMethodMediaQueryListListenerArgMethodCallback(const v8::Function
CallbackInfo<v8::Value>& info) | 3928 static void voidMethodMediaQueryListListenerArgMethodCallback(const v8::Function
CallbackInfo<v8::Value>& info) |
| 3929 { | 3929 { |
| 3930 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 3930 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 3931 TestObjectPythonV8Internal::voidMethodMediaQueryListListenerArgMethod(info); | 3931 TestObjectPythonV8Internal::voidMethodMediaQueryListListenerArgMethod(info); |
| 3932 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3932 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3933 } | 3933 } |
| 3934 | 3934 |
| 3935 static void voidMethodCompareHowArgMethod(const v8::FunctionCallbackInfo<v8::Val
ue>& info) | 3935 static void voidMethodCompareHowArgMethod(const v8::FunctionCallbackInfo<v8::Val
ue>& info) |
| 3936 { | 3936 { |
| 3937 if (UNLIKELY(info.Length() < 1)) { | 3937 if (UNLIKELY(info.Length() < 1)) { |
| 3938 throwTypeError(ExceptionMessages::failedToExecute("voidMethodCompareHowA
rg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length())
), info.GetIsolate()); | 3938 throwTypeError(ExceptionMessages::failedToExecute("voidMethodCompareHowA
rg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length())
), info.GetIsolate()); |
| 3939 return; | 3939 return; |
| 3940 } | 3940 } |
| 3941 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3941 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3942 V8TRYCATCH_VOID(Range::CompareHow, compareHowArg, static_cast<Range::Compare
How>(info[0]->Int32Value())); | 3942 V8TRYCATCH_VOID(Range::CompareHow, compareHowArg, static_cast<Range::Compare
How>(info[0]->Int32Value())); |
| 3943 imp->voidMethodCompareHowArg(compareHowArg); | 3943 imp->voidMethodCompareHowArg(compareHowArg); |
| 3944 } | 3944 } |
| 3945 | 3945 |
| 3946 static void voidMethodCompareHowArgMethodCallback(const v8::FunctionCallbackInfo
<v8::Value>& info) | 3946 static void voidMethodCompareHowArgMethodCallback(const v8::FunctionCallbackInfo
<v8::Value>& info) |
| 3947 { | 3947 { |
| 3948 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 3948 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 3949 TestObjectPythonV8Internal::voidMethodCompareHowArgMethod(info); | 3949 TestObjectPythonV8Internal::voidMethodCompareHowArgMethod(info); |
| 3950 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3950 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3951 } | 3951 } |
| 3952 | 3952 |
| 3953 static void voidMethodAnyArgMethod(const v8::FunctionCallbackInfo<v8::Value>& in
fo) | 3953 static void voidMethodAnyArgMethod(const v8::FunctionCallbackInfo<v8::Value>& in
fo) |
| 3954 { | 3954 { |
| 3955 if (UNLIKELY(info.Length() < 1)) { | 3955 if (UNLIKELY(info.Length() < 1)) { |
| 3956 throwTypeError(ExceptionMessages::failedToExecute("voidMethodAnyArg", "T
estObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length())), info
.GetIsolate()); | 3956 throwTypeError(ExceptionMessages::failedToExecute("voidMethodAnyArg", "T
estObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length())), info
.GetIsolate()); |
| 3957 return; | 3957 return; |
| 3958 } | 3958 } |
| 3959 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3959 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3960 V8TRYCATCH_VOID(ScriptValue, anyArg, ScriptValue(info[0], info.GetIsolate())
); | 3960 V8TRYCATCH_VOID(ScriptValue, anyArg, ScriptValue(info[0], info.GetIsolate())
); |
| 3961 imp->voidMethodAnyArg(anyArg); | 3961 imp->voidMethodAnyArg(anyArg); |
| 3962 } | 3962 } |
| 3963 | 3963 |
| 3964 static void voidMethodAnyArgMethodCallback(const v8::FunctionCallbackInfo<v8::Va
lue>& info) | 3964 static void voidMethodAnyArgMethodCallback(const v8::FunctionCallbackInfo<v8::Va
lue>& info) |
| 3965 { | 3965 { |
| 3966 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 3966 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 3967 TestObjectPythonV8Internal::voidMethodAnyArgMethod(info); | 3967 TestObjectPythonV8Internal::voidMethodAnyArgMethod(info); |
| 3968 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3968 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3969 } | 3969 } |
| 3970 | 3970 |
| 3971 static void voidMethodAttrArgMethod(const v8::FunctionCallbackInfo<v8::Value>& i
nfo) | 3971 static void voidMethodAttrArgMethod(const v8::FunctionCallbackInfo<v8::Value>& i
nfo) |
| 3972 { | 3972 { |
| 3973 if (UNLIKELY(info.Length() < 1)) { | 3973 if (UNLIKELY(info.Length() < 1)) { |
| 3974 throwTypeError(ExceptionMessages::failedToExecute("voidMethodAttrArg", "
TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length())), inf
o.GetIsolate()); | 3974 throwTypeError(ExceptionMessages::failedToExecute("voidMethodAttrArg", "
TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length())), inf
o.GetIsolate()); |
| 3975 return; | 3975 return; |
| 3976 } | 3976 } |
| 3977 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3977 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3978 V8TRYCATCH_VOID(Attr*, attrArg, V8Attr::hasInstance(info[0], info.GetIsolate
(), worldType(info.GetIsolate())) ? V8Attr::toNative(v8::Handle<v8::Object>::Cas
t(info[0])) : 0); | 3978 V8TRYCATCH_VOID(Attr*, attrArg, V8Attr::hasInstance(info[0], info.GetIsolate
(), worldType(info.GetIsolate())) ? V8Attr::toNative(v8::Handle<v8::Object>::Cas
t(info[0])) : 0); |
| 3979 imp->voidMethodAttrArg(attrArg); | 3979 imp->voidMethodAttrArg(attrArg); |
| 3980 } | 3980 } |
| 3981 | 3981 |
| 3982 static void voidMethodAttrArgMethodCallback(const v8::FunctionCallbackInfo<v8::V
alue>& info) | 3982 static void voidMethodAttrArgMethodCallback(const v8::FunctionCallbackInfo<v8::V
alue>& info) |
| 3983 { | 3983 { |
| 3984 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 3984 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 3985 TestObjectPythonV8Internal::voidMethodAttrArgMethod(info); | 3985 TestObjectPythonV8Internal::voidMethodAttrArgMethod(info); |
| 3986 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 3986 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 3987 } | 3987 } |
| 3988 | 3988 |
| 3989 static void voidMethodDocumentArgMethod(const v8::FunctionCallbackInfo<v8::Value
>& info) | 3989 static void voidMethodDocumentArgMethod(const v8::FunctionCallbackInfo<v8::Value
>& info) |
| 3990 { | 3990 { |
| 3991 if (UNLIKELY(info.Length() < 1)) { | 3991 if (UNLIKELY(info.Length() < 1)) { |
| 3992 throwTypeError(ExceptionMessages::failedToExecute("voidMethodDocumentArg
", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length())),
info.GetIsolate()); | 3992 throwTypeError(ExceptionMessages::failedToExecute("voidMethodDocumentArg
", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length())),
info.GetIsolate()); |
| 3993 return; | 3993 return; |
| 3994 } | 3994 } |
| 3995 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 3995 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 3996 V8TRYCATCH_VOID(Document*, documentArg, V8Document::hasInstance(info[0], inf
o.GetIsolate(), worldType(info.GetIsolate())) ? V8Document::toNative(v8::Handle<
v8::Object>::Cast(info[0])) : 0); | 3996 V8TRYCATCH_VOID(Document*, documentArg, V8Document::hasInstance(info[0], inf
o.GetIsolate(), worldType(info.GetIsolate())) ? V8Document::toNative(v8::Handle<
v8::Object>::Cast(info[0])) : 0); |
| 3997 imp->voidMethodDocumentArg(documentArg); | 3997 imp->voidMethodDocumentArg(documentArg); |
| 3998 } | 3998 } |
| 3999 | 3999 |
| 4000 static void voidMethodDocumentArgMethodCallback(const v8::FunctionCallbackInfo<v
8::Value>& info) | 4000 static void voidMethodDocumentArgMethodCallback(const v8::FunctionCallbackInfo<v
8::Value>& info) |
| 4001 { | 4001 { |
| 4002 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4002 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4003 TestObjectPythonV8Internal::voidMethodDocumentArgMethod(info); | 4003 TestObjectPythonV8Internal::voidMethodDocumentArgMethod(info); |
| 4004 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4004 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4005 } | 4005 } |
| 4006 | 4006 |
| 4007 static void voidMethodDocumentTypeArgMethod(const v8::FunctionCallbackInfo<v8::V
alue>& info) | 4007 static void voidMethodDocumentTypeArgMethod(const v8::FunctionCallbackInfo<v8::V
alue>& info) |
| 4008 { | 4008 { |
| 4009 if (UNLIKELY(info.Length() < 1)) { | 4009 if (UNLIKELY(info.Length() < 1)) { |
| 4010 throwTypeError(ExceptionMessages::failedToExecute("voidMethodDocumentTyp
eArg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length(
))), info.GetIsolate()); | 4010 throwTypeError(ExceptionMessages::failedToExecute("voidMethodDocumentTyp
eArg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length(
))), info.GetIsolate()); |
| 4011 return; | 4011 return; |
| 4012 } | 4012 } |
| 4013 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4013 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4014 V8TRYCATCH_VOID(DocumentType*, documentTypeArg, V8DocumentType::hasInstance(
info[0], info.GetIsolate(), worldType(info.GetIsolate())) ? V8DocumentType::toNa
tive(v8::Handle<v8::Object>::Cast(info[0])) : 0); | 4014 V8TRYCATCH_VOID(DocumentType*, documentTypeArg, V8DocumentType::hasInstance(
info[0], info.GetIsolate(), worldType(info.GetIsolate())) ? V8DocumentType::toNa
tive(v8::Handle<v8::Object>::Cast(info[0])) : 0); |
| 4015 imp->voidMethodDocumentTypeArg(documentTypeArg); | 4015 imp->voidMethodDocumentTypeArg(documentTypeArg); |
| 4016 } | 4016 } |
| 4017 | 4017 |
| 4018 static void voidMethodDocumentTypeArgMethodCallback(const v8::FunctionCallbackIn
fo<v8::Value>& info) | 4018 static void voidMethodDocumentTypeArgMethodCallback(const v8::FunctionCallbackIn
fo<v8::Value>& info) |
| 4019 { | 4019 { |
| 4020 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4020 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4021 TestObjectPythonV8Internal::voidMethodDocumentTypeArgMethod(info); | 4021 TestObjectPythonV8Internal::voidMethodDocumentTypeArgMethod(info); |
| 4022 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4022 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4023 } | 4023 } |
| 4024 | 4024 |
| 4025 static void voidMethodElementArgMethod(const v8::FunctionCallbackInfo<v8::Value>
& info) | 4025 static void voidMethodElementArgMethod(const v8::FunctionCallbackInfo<v8::Value>
& info) |
| 4026 { | 4026 { |
| 4027 if (UNLIKELY(info.Length() < 1)) { | 4027 if (UNLIKELY(info.Length() < 1)) { |
| 4028 throwTypeError(ExceptionMessages::failedToExecute("voidMethodElementArg"
, "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length())),
info.GetIsolate()); | 4028 throwTypeError(ExceptionMessages::failedToExecute("voidMethodElementArg"
, "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length())),
info.GetIsolate()); |
| 4029 return; | 4029 return; |
| 4030 } | 4030 } |
| 4031 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4031 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4032 V8TRYCATCH_VOID(Element*, elementArg, V8Element::hasInstance(info[0], info.G
etIsolate(), worldType(info.GetIsolate())) ? V8Element::toNative(v8::Handle<v8::
Object>::Cast(info[0])) : 0); | 4032 V8TRYCATCH_VOID(Element*, elementArg, V8Element::hasInstance(info[0], info.G
etIsolate(), worldType(info.GetIsolate())) ? V8Element::toNative(v8::Handle<v8::
Object>::Cast(info[0])) : 0); |
| 4033 imp->voidMethodElementArg(elementArg); | 4033 imp->voidMethodElementArg(elementArg); |
| 4034 } | 4034 } |
| 4035 | 4035 |
| 4036 static void voidMethodElementArgMethodCallback(const v8::FunctionCallbackInfo<v8
::Value>& info) | 4036 static void voidMethodElementArgMethodCallback(const v8::FunctionCallbackInfo<v8
::Value>& info) |
| 4037 { | 4037 { |
| 4038 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4038 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4039 TestObjectPythonV8Internal::voidMethodElementArgMethod(info); | 4039 TestObjectPythonV8Internal::voidMethodElementArgMethod(info); |
| 4040 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4040 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4041 } | 4041 } |
| 4042 | 4042 |
| 4043 static void voidMethodNodeArgMethod(const v8::FunctionCallbackInfo<v8::Value>& i
nfo) | 4043 static void voidMethodNodeArgMethod(const v8::FunctionCallbackInfo<v8::Value>& i
nfo) |
| 4044 { | 4044 { |
| 4045 if (UNLIKELY(info.Length() < 1)) { | 4045 if (UNLIKELY(info.Length() < 1)) { |
| 4046 throwTypeError(ExceptionMessages::failedToExecute("voidMethodNodeArg", "
TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length())), inf
o.GetIsolate()); | 4046 throwTypeError(ExceptionMessages::failedToExecute("voidMethodNodeArg", "
TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length())), inf
o.GetIsolate()); |
| 4047 return; | 4047 return; |
| 4048 } | 4048 } |
| 4049 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4049 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4050 V8TRYCATCH_VOID(Node*, nodeArg, V8Node::hasInstance(info[0], info.GetIsolate
(), worldType(info.GetIsolate())) ? V8Node::toNative(v8::Handle<v8::Object>::Cas
t(info[0])) : 0); | 4050 V8TRYCATCH_VOID(Node*, nodeArg, V8Node::hasInstance(info[0], info.GetIsolate
(), worldType(info.GetIsolate())) ? V8Node::toNative(v8::Handle<v8::Object>::Cas
t(info[0])) : 0); |
| 4051 imp->voidMethodNodeArg(nodeArg); | 4051 imp->voidMethodNodeArg(nodeArg); |
| 4052 } | 4052 } |
| 4053 | 4053 |
| 4054 static void voidMethodNodeArgMethodCallback(const v8::FunctionCallbackInfo<v8::V
alue>& info) | 4054 static void voidMethodNodeArgMethodCallback(const v8::FunctionCallbackInfo<v8::V
alue>& info) |
| 4055 { | 4055 { |
| 4056 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4056 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4057 TestObjectPythonV8Internal::voidMethodNodeArgMethod(info); | 4057 TestObjectPythonV8Internal::voidMethodNodeArgMethod(info); |
| 4058 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4058 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4059 } | 4059 } |
| 4060 | 4060 |
| 4061 static void arrayBufferMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& i
nfo) | 4061 static void arrayBufferMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& i
nfo) |
| 4062 { | 4062 { |
| 4063 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4063 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4064 v8SetReturnValue(info, imp->arrayBufferMethod()); | 4064 v8SetReturnValue(info, imp->arrayBufferMethod()); |
| 4065 } | 4065 } |
| 4066 | 4066 |
| 4067 static void arrayBufferMethodMethodCallback(const v8::FunctionCallbackInfo<v8::V
alue>& info) | 4067 static void arrayBufferMethodMethodCallback(const v8::FunctionCallbackInfo<v8::V
alue>& info) |
| 4068 { | 4068 { |
| 4069 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4069 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4070 TestObjectPythonV8Internal::arrayBufferMethodMethod(info); | 4070 TestObjectPythonV8Internal::arrayBufferMethodMethod(info); |
| 4071 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4071 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4072 } | 4072 } |
| 4073 | 4073 |
| 4074 static void arrayBufferViewMethodMethod(const v8::FunctionCallbackInfo<v8::Value
>& info) | 4074 static void arrayBufferViewMethodMethod(const v8::FunctionCallbackInfo<v8::Value
>& info) |
| 4075 { | 4075 { |
| 4076 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4076 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4077 v8SetReturnValue(info, imp->arrayBufferViewMethod()); | 4077 v8SetReturnValue(info, imp->arrayBufferViewMethod()); |
| 4078 } | 4078 } |
| 4079 | 4079 |
| 4080 static void arrayBufferViewMethodMethodCallback(const v8::FunctionCallbackInfo<v
8::Value>& info) | 4080 static void arrayBufferViewMethodMethodCallback(const v8::FunctionCallbackInfo<v
8::Value>& info) |
| 4081 { | 4081 { |
| 4082 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4082 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4083 TestObjectPythonV8Internal::arrayBufferViewMethodMethod(info); | 4083 TestObjectPythonV8Internal::arrayBufferViewMethodMethod(info); |
| 4084 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4084 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4085 } | 4085 } |
| 4086 | 4086 |
| 4087 static void float32ArrayMethodMethod(const v8::FunctionCallbackInfo<v8::Value>&
info) | 4087 static void float32ArrayMethodMethod(const v8::FunctionCallbackInfo<v8::Value>&
info) |
| 4088 { | 4088 { |
| 4089 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4089 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4090 v8SetReturnValue(info, imp->float32ArrayMethod()); | 4090 v8SetReturnValue(info, imp->float32ArrayMethod()); |
| 4091 } | 4091 } |
| 4092 | 4092 |
| 4093 static void float32ArrayMethodMethodCallback(const v8::FunctionCallbackInfo<v8::
Value>& info) | 4093 static void float32ArrayMethodMethodCallback(const v8::FunctionCallbackInfo<v8::
Value>& info) |
| 4094 { | 4094 { |
| 4095 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4095 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4096 TestObjectPythonV8Internal::float32ArrayMethodMethod(info); | 4096 TestObjectPythonV8Internal::float32ArrayMethodMethod(info); |
| 4097 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4097 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4098 } | 4098 } |
| 4099 | 4099 |
| 4100 static void int32ArrayMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& in
fo) | 4100 static void int32ArrayMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& in
fo) |
| 4101 { | 4101 { |
| 4102 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4102 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4103 v8SetReturnValue(info, imp->int32ArrayMethod()); | 4103 v8SetReturnValue(info, imp->int32ArrayMethod()); |
| 4104 } | 4104 } |
| 4105 | 4105 |
| 4106 static void int32ArrayMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Va
lue>& info) | 4106 static void int32ArrayMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Va
lue>& info) |
| 4107 { | 4107 { |
| 4108 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4108 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4109 TestObjectPythonV8Internal::int32ArrayMethodMethod(info); | 4109 TestObjectPythonV8Internal::int32ArrayMethodMethod(info); |
| 4110 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4110 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4111 } | 4111 } |
| 4112 | 4112 |
| 4113 static void uint8ArrayMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& in
fo) | 4113 static void uint8ArrayMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& in
fo) |
| 4114 { | 4114 { |
| 4115 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4115 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4116 v8SetReturnValue(info, imp->uint8ArrayMethod()); | 4116 v8SetReturnValue(info, imp->uint8ArrayMethod()); |
| 4117 } | 4117 } |
| 4118 | 4118 |
| 4119 static void uint8ArrayMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Va
lue>& info) | 4119 static void uint8ArrayMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Va
lue>& info) |
| 4120 { | 4120 { |
| 4121 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4121 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4122 TestObjectPythonV8Internal::uint8ArrayMethodMethod(info); | 4122 TestObjectPythonV8Internal::uint8ArrayMethodMethod(info); |
| 4123 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4123 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4124 } | 4124 } |
| 4125 | 4125 |
| 4126 static void voidMethodArrayBufferArgMethod(const v8::FunctionCallbackInfo<v8::Va
lue>& info) | 4126 static void voidMethodArrayBufferArgMethod(const v8::FunctionCallbackInfo<v8::Va
lue>& info) |
| 4127 { | 4127 { |
| 4128 if (UNLIKELY(info.Length() < 1)) { | 4128 if (UNLIKELY(info.Length() < 1)) { |
| 4129 throwTypeError(ExceptionMessages::failedToExecute("voidMethodArrayBuffer
Arg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length()
)), info.GetIsolate()); | 4129 throwTypeError(ExceptionMessages::failedToExecute("voidMethodArrayBuffer
Arg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length()
)), info.GetIsolate()); |
| 4130 return; | 4130 return; |
| 4131 } | 4131 } |
| 4132 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4132 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4133 V8TRYCATCH_VOID(ArrayBuffer*, arrayBufferArg, info[0]->IsArrayBuffer() ? V8A
rrayBuffer::toNative(v8::Handle<v8::ArrayBuffer>::Cast(info[0])) : 0); | 4133 V8TRYCATCH_VOID(ArrayBuffer*, arrayBufferArg, info[0]->IsArrayBuffer() ? V8A
rrayBuffer::toNative(v8::Handle<v8::ArrayBuffer>::Cast(info[0])) : 0); |
| 4134 imp->voidMethodArrayBufferArg(arrayBufferArg); | 4134 imp->voidMethodArrayBufferArg(arrayBufferArg); |
| 4135 } | 4135 } |
| 4136 | 4136 |
| 4137 static void voidMethodArrayBufferArgMethodCallback(const v8::FunctionCallbackInf
o<v8::Value>& info) | 4137 static void voidMethodArrayBufferArgMethodCallback(const v8::FunctionCallbackInf
o<v8::Value>& info) |
| 4138 { | 4138 { |
| 4139 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4139 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4140 TestObjectPythonV8Internal::voidMethodArrayBufferArgMethod(info); | 4140 TestObjectPythonV8Internal::voidMethodArrayBufferArgMethod(info); |
| 4141 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4141 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4142 } | 4142 } |
| 4143 | 4143 |
| 4144 static void voidMethodArrayBufferViewArgMethod(const v8::FunctionCallbackInfo<v8
::Value>& info) | 4144 static void voidMethodArrayBufferViewArgMethod(const v8::FunctionCallbackInfo<v8
::Value>& info) |
| 4145 { | 4145 { |
| 4146 if (UNLIKELY(info.Length() < 1)) { | 4146 if (UNLIKELY(info.Length() < 1)) { |
| 4147 throwTypeError(ExceptionMessages::failedToExecute("voidMethodArrayBuffer
ViewArg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Leng
th())), info.GetIsolate()); | 4147 throwTypeError(ExceptionMessages::failedToExecute("voidMethodArrayBuffer
ViewArg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Leng
th())), info.GetIsolate()); |
| 4148 return; | 4148 return; |
| 4149 } | 4149 } |
| 4150 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4150 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4151 V8TRYCATCH_VOID(ArrayBufferView*, arrayBufferViewArg, info[0]->IsArrayBuffer
View() ? V8ArrayBufferView::toNative(v8::Handle<v8::ArrayBufferView>::Cast(info[
0])) : 0); | 4151 V8TRYCATCH_VOID(ArrayBufferView*, arrayBufferViewArg, info[0]->IsArrayBuffer
View() ? V8ArrayBufferView::toNative(v8::Handle<v8::ArrayBufferView>::Cast(info[
0])) : 0); |
| 4152 imp->voidMethodArrayBufferViewArg(arrayBufferViewArg); | 4152 imp->voidMethodArrayBufferViewArg(arrayBufferViewArg); |
| 4153 } | 4153 } |
| 4154 | 4154 |
| 4155 static void voidMethodArrayBufferViewArgMethodCallback(const v8::FunctionCallbac
kInfo<v8::Value>& info) | 4155 static void voidMethodArrayBufferViewArgMethodCallback(const v8::FunctionCallbac
kInfo<v8::Value>& info) |
| 4156 { | 4156 { |
| 4157 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4157 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4158 TestObjectPythonV8Internal::voidMethodArrayBufferViewArgMethod(info); | 4158 TestObjectPythonV8Internal::voidMethodArrayBufferViewArgMethod(info); |
| 4159 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4159 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4160 } | 4160 } |
| 4161 | 4161 |
| 4162 static void voidMethodFloat32ArrayArgMethod(const v8::FunctionCallbackInfo<v8::V
alue>& info) | 4162 static void voidMethodFloat32ArrayArgMethod(const v8::FunctionCallbackInfo<v8::V
alue>& info) |
| 4163 { | 4163 { |
| 4164 if (UNLIKELY(info.Length() < 1)) { | 4164 if (UNLIKELY(info.Length() < 1)) { |
| 4165 throwTypeError(ExceptionMessages::failedToExecute("voidMethodFloat32Arra
yArg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length(
))), info.GetIsolate()); | 4165 throwTypeError(ExceptionMessages::failedToExecute("voidMethodFloat32Arra
yArg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length(
))), info.GetIsolate()); |
| 4166 return; | 4166 return; |
| 4167 } | 4167 } |
| 4168 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4168 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4169 V8TRYCATCH_VOID(Float32Array*, float32ArrayArg, info[0]->IsFloat32Array() ?
V8Float32Array::toNative(v8::Handle<v8::Float32Array>::Cast(info[0])) : 0); | 4169 V8TRYCATCH_VOID(Float32Array*, float32ArrayArg, info[0]->IsFloat32Array() ?
V8Float32Array::toNative(v8::Handle<v8::Float32Array>::Cast(info[0])) : 0); |
| 4170 imp->voidMethodFloat32ArrayArg(float32ArrayArg); | 4170 imp->voidMethodFloat32ArrayArg(float32ArrayArg); |
| 4171 } | 4171 } |
| 4172 | 4172 |
| 4173 static void voidMethodFloat32ArrayArgMethodCallback(const v8::FunctionCallbackIn
fo<v8::Value>& info) | 4173 static void voidMethodFloat32ArrayArgMethodCallback(const v8::FunctionCallbackIn
fo<v8::Value>& info) |
| 4174 { | 4174 { |
| 4175 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4175 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4176 TestObjectPythonV8Internal::voidMethodFloat32ArrayArgMethod(info); | 4176 TestObjectPythonV8Internal::voidMethodFloat32ArrayArgMethod(info); |
| 4177 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4177 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4178 } | 4178 } |
| 4179 | 4179 |
| 4180 static void voidMethodInt32ArrayArgMethod(const v8::FunctionCallbackInfo<v8::Val
ue>& info) | 4180 static void voidMethodInt32ArrayArgMethod(const v8::FunctionCallbackInfo<v8::Val
ue>& info) |
| 4181 { | 4181 { |
| 4182 if (UNLIKELY(info.Length() < 1)) { | 4182 if (UNLIKELY(info.Length() < 1)) { |
| 4183 throwTypeError(ExceptionMessages::failedToExecute("voidMethodInt32ArrayA
rg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length())
), info.GetIsolate()); | 4183 throwTypeError(ExceptionMessages::failedToExecute("voidMethodInt32ArrayA
rg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length())
), info.GetIsolate()); |
| 4184 return; | 4184 return; |
| 4185 } | 4185 } |
| 4186 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4186 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4187 V8TRYCATCH_VOID(Int32Array*, int32ArrayArg, info[0]->IsInt32Array() ? V8Int3
2Array::toNative(v8::Handle<v8::Int32Array>::Cast(info[0])) : 0); | 4187 V8TRYCATCH_VOID(Int32Array*, int32ArrayArg, info[0]->IsInt32Array() ? V8Int3
2Array::toNative(v8::Handle<v8::Int32Array>::Cast(info[0])) : 0); |
| 4188 imp->voidMethodInt32ArrayArg(int32ArrayArg); | 4188 imp->voidMethodInt32ArrayArg(int32ArrayArg); |
| 4189 } | 4189 } |
| 4190 | 4190 |
| 4191 static void voidMethodInt32ArrayArgMethodCallback(const v8::FunctionCallbackInfo
<v8::Value>& info) | 4191 static void voidMethodInt32ArrayArgMethodCallback(const v8::FunctionCallbackInfo
<v8::Value>& info) |
| 4192 { | 4192 { |
| 4193 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4193 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4194 TestObjectPythonV8Internal::voidMethodInt32ArrayArgMethod(info); | 4194 TestObjectPythonV8Internal::voidMethodInt32ArrayArgMethod(info); |
| 4195 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4195 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4196 } | 4196 } |
| 4197 | 4197 |
| 4198 static void voidMethodUint8ArrayArgMethod(const v8::FunctionCallbackInfo<v8::Val
ue>& info) | 4198 static void voidMethodUint8ArrayArgMethod(const v8::FunctionCallbackInfo<v8::Val
ue>& info) |
| 4199 { | 4199 { |
| 4200 if (UNLIKELY(info.Length() < 1)) { | 4200 if (UNLIKELY(info.Length() < 1)) { |
| 4201 throwTypeError(ExceptionMessages::failedToExecute("voidMethodUint8ArrayA
rg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length())
), info.GetIsolate()); | 4201 throwTypeError(ExceptionMessages::failedToExecute("voidMethodUint8ArrayA
rg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length())
), info.GetIsolate()); |
| 4202 return; | 4202 return; |
| 4203 } | 4203 } |
| 4204 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4204 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4205 V8TRYCATCH_VOID(Uint8Array*, uint8ArrayArg, info[0]->IsUint8Array() ? V8Uint
8Array::toNative(v8::Handle<v8::Uint8Array>::Cast(info[0])) : 0); | 4205 V8TRYCATCH_VOID(Uint8Array*, uint8ArrayArg, info[0]->IsUint8Array() ? V8Uint
8Array::toNative(v8::Handle<v8::Uint8Array>::Cast(info[0])) : 0); |
| 4206 imp->voidMethodUint8ArrayArg(uint8ArrayArg); | 4206 imp->voidMethodUint8ArrayArg(uint8ArrayArg); |
| 4207 } | 4207 } |
| 4208 | 4208 |
| 4209 static void voidMethodUint8ArrayArgMethodCallback(const v8::FunctionCallbackInfo
<v8::Value>& info) | 4209 static void voidMethodUint8ArrayArgMethodCallback(const v8::FunctionCallbackInfo
<v8::Value>& info) |
| 4210 { | 4210 { |
| 4211 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4211 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4212 TestObjectPythonV8Internal::voidMethodUint8ArrayArgMethod(info); | 4212 TestObjectPythonV8Internal::voidMethodUint8ArrayArgMethod(info); |
| 4213 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4213 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4214 } | 4214 } |
| 4215 | 4215 |
| 4216 static void longArrayMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& inf
o) | 4216 static void longArrayMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& inf
o) |
| 4217 { | 4217 { |
| 4218 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4218 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4219 v8SetReturnValue(info, v8Array(imp->longArrayMethod(), info.GetIsolate())); | 4219 v8SetReturnValue(info, v8Array(imp->longArrayMethod(), info.GetIsolate())); |
| 4220 } | 4220 } |
| 4221 | 4221 |
| 4222 static void longArrayMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Val
ue>& info) | 4222 static void longArrayMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Val
ue>& info) |
| 4223 { | 4223 { |
| 4224 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4224 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4225 TestObjectPythonV8Internal::longArrayMethodMethod(info); | 4225 TestObjectPythonV8Internal::longArrayMethodMethod(info); |
| 4226 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4226 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4227 } | 4227 } |
| 4228 | 4228 |
| 4229 static void stringArrayMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& i
nfo) | 4229 static void stringArrayMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& i
nfo) |
| 4230 { | 4230 { |
| 4231 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4231 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4232 v8SetReturnValue(info, v8Array(imp->stringArrayMethod(), info.GetIsolate()))
; | 4232 v8SetReturnValue(info, v8Array(imp->stringArrayMethod(), info.GetIsolate()))
; |
| 4233 } | 4233 } |
| 4234 | 4234 |
| 4235 static void stringArrayMethodMethodCallback(const v8::FunctionCallbackInfo<v8::V
alue>& info) | 4235 static void stringArrayMethodMethodCallback(const v8::FunctionCallbackInfo<v8::V
alue>& info) |
| 4236 { | 4236 { |
| 4237 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4237 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4238 TestObjectPythonV8Internal::stringArrayMethodMethod(info); | 4238 TestObjectPythonV8Internal::stringArrayMethodMethod(info); |
| 4239 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4239 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4240 } | 4240 } |
| 4241 | 4241 |
| 4242 static void testInterfaceEmptyArrayMethodMethod(const v8::FunctionCallbackInfo<v
8::Value>& info) | 4242 static void testInterfaceEmptyArrayMethodMethod(const v8::FunctionCallbackInfo<v
8::Value>& info) |
| 4243 { | 4243 { |
| 4244 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4244 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4245 v8SetReturnValue(info, v8Array(imp->testInterfaceEmptyArrayMethod(), info.Ge
tIsolate())); | 4245 v8SetReturnValue(info, v8Array(imp->testInterfaceEmptyArrayMethod(), info.Ge
tIsolate())); |
| 4246 } | 4246 } |
| 4247 | 4247 |
| 4248 static void testInterfaceEmptyArrayMethodMethodCallback(const v8::FunctionCallba
ckInfo<v8::Value>& info) | 4248 static void testInterfaceEmptyArrayMethodMethodCallback(const v8::FunctionCallba
ckInfo<v8::Value>& info) |
| 4249 { | 4249 { |
| 4250 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4250 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4251 TestObjectPythonV8Internal::testInterfaceEmptyArrayMethodMethod(info); | 4251 TestObjectPythonV8Internal::testInterfaceEmptyArrayMethodMethod(info); |
| 4252 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4252 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4253 } | 4253 } |
| 4254 | 4254 |
| 4255 static void voidMethodArrayLongArgMethod(const v8::FunctionCallbackInfo<v8::Valu
e>& info) | 4255 static void voidMethodArrayLongArgMethod(const v8::FunctionCallbackInfo<v8::Valu
e>& info) |
| 4256 { | 4256 { |
| 4257 if (UNLIKELY(info.Length() < 1)) { | 4257 if (UNLIKELY(info.Length() < 1)) { |
| 4258 throwTypeError(ExceptionMessages::failedToExecute("voidMethodArrayLongAr
g", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length()))
, info.GetIsolate()); | 4258 throwTypeError(ExceptionMessages::failedToExecute("voidMethodArrayLongAr
g", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length()))
, info.GetIsolate()); |
| 4259 return; | 4259 return; |
| 4260 } | 4260 } |
| 4261 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4261 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4262 V8TRYCATCH_VOID(Vector<int>, arrayLongArg, toNativeArray<int>(info[0], 1, in
fo.GetIsolate())); | 4262 V8TRYCATCH_VOID(Vector<int>, arrayLongArg, toNativeArray<int>(info[0], 1, in
fo.GetIsolate())); |
| 4263 imp->voidMethodArrayLongArg(arrayLongArg); | 4263 imp->voidMethodArrayLongArg(arrayLongArg); |
| 4264 } | 4264 } |
| 4265 | 4265 |
| 4266 static void voidMethodArrayLongArgMethodCallback(const v8::FunctionCallbackInfo<
v8::Value>& info) | 4266 static void voidMethodArrayLongArgMethodCallback(const v8::FunctionCallbackInfo<
v8::Value>& info) |
| 4267 { | 4267 { |
| 4268 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4268 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4269 TestObjectPythonV8Internal::voidMethodArrayLongArgMethod(info); | 4269 TestObjectPythonV8Internal::voidMethodArrayLongArgMethod(info); |
| 4270 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4270 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4271 } | 4271 } |
| 4272 | 4272 |
| 4273 static void voidMethodArrayStringArgMethod(const v8::FunctionCallbackInfo<v8::Va
lue>& info) | 4273 static void voidMethodArrayStringArgMethod(const v8::FunctionCallbackInfo<v8::Va
lue>& info) |
| 4274 { | 4274 { |
| 4275 if (UNLIKELY(info.Length() < 1)) { | 4275 if (UNLIKELY(info.Length() < 1)) { |
| 4276 throwTypeError(ExceptionMessages::failedToExecute("voidMethodArrayString
Arg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length()
)), info.GetIsolate()); | 4276 throwTypeError(ExceptionMessages::failedToExecute("voidMethodArrayString
Arg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length()
)), info.GetIsolate()); |
| 4277 return; | 4277 return; |
| 4278 } | 4278 } |
| 4279 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4279 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4280 V8TRYCATCH_VOID(Vector<String>, arrayStringArg, toNativeArray<String>(info[0
], 1, info.GetIsolate())); | 4280 V8TRYCATCH_VOID(Vector<String>, arrayStringArg, toNativeArray<String>(info[0
], 1, info.GetIsolate())); |
| 4281 imp->voidMethodArrayStringArg(arrayStringArg); | 4281 imp->voidMethodArrayStringArg(arrayStringArg); |
| 4282 } | 4282 } |
| 4283 | 4283 |
| 4284 static void voidMethodArrayStringArgMethodCallback(const v8::FunctionCallbackInf
o<v8::Value>& info) | 4284 static void voidMethodArrayStringArgMethodCallback(const v8::FunctionCallbackInf
o<v8::Value>& info) |
| 4285 { | 4285 { |
| 4286 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4286 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4287 TestObjectPythonV8Internal::voidMethodArrayStringArgMethod(info); | 4287 TestObjectPythonV8Internal::voidMethodArrayStringArgMethod(info); |
| 4288 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4288 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4289 } | 4289 } |
| 4290 | 4290 |
| 4291 static void voidMethodArrayTestInterfaceEmptyArgMethod(const v8::FunctionCallbac
kInfo<v8::Value>& info) | 4291 static void voidMethodArrayTestInterfaceEmptyArgMethod(const v8::FunctionCallbac
kInfo<v8::Value>& info) |
| 4292 { | 4292 { |
| 4293 if (UNLIKELY(info.Length() < 1)) { | 4293 if (UNLIKELY(info.Length() < 1)) { |
| 4294 throwTypeError(ExceptionMessages::failedToExecute("voidMethodArrayTestIn
terfaceEmptyArg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, i
nfo.Length())), info.GetIsolate()); | 4294 throwTypeError(ExceptionMessages::failedToExecute("voidMethodArrayTestIn
terfaceEmptyArg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, i
nfo.Length())), info.GetIsolate()); |
| 4295 return; | 4295 return; |
| 4296 } | 4296 } |
| 4297 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4297 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4298 V8TRYCATCH_VOID(Vector<RefPtr<TestInterfaceEmpty> >, arrayTestInterfaceEmpty
Arg, (toRefPtrNativeArray<TestInterfaceEmpty, V8TestInterfaceEmpty>(info[0], 1,
info.GetIsolate()))); | 4298 V8TRYCATCH_VOID(Vector<RefPtr<TestInterfaceEmpty> >, arrayTestInterfaceEmpty
Arg, (toRefPtrNativeArray<TestInterfaceEmpty, V8TestInterfaceEmpty>(info[0], 1,
info.GetIsolate()))); |
| 4299 imp->voidMethodArrayTestInterfaceEmptyArg(arrayTestInterfaceEmptyArg); | 4299 imp->voidMethodArrayTestInterfaceEmptyArg(arrayTestInterfaceEmptyArg); |
| 4300 } | 4300 } |
| 4301 | 4301 |
| 4302 static void voidMethodArrayTestInterfaceEmptyArgMethodCallback(const v8::Functio
nCallbackInfo<v8::Value>& info) | 4302 static void voidMethodArrayTestInterfaceEmptyArgMethodCallback(const v8::Functio
nCallbackInfo<v8::Value>& info) |
| 4303 { | 4303 { |
| 4304 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4304 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4305 TestObjectPythonV8Internal::voidMethodArrayTestInterfaceEmptyArgMethod(info)
; | 4305 TestObjectPythonV8Internal::voidMethodArrayTestInterfaceEmptyArgMethod(info)
; |
| 4306 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4306 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4307 } | 4307 } |
| 4308 | 4308 |
| 4309 static void sequenceLongMethodMethod(const v8::FunctionCallbackInfo<v8::Value>&
info) | 4309 static void sequenceLongMethodMethod(const v8::FunctionCallbackInfo<v8::Value>&
info) |
| 4310 { | 4310 { |
| 4311 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4311 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4312 v8SetReturnValue(info, v8Array(imp->sequenceLongMethod(), info.GetIsolate())
); | 4312 v8SetReturnValue(info, v8Array(imp->sequenceLongMethod(), info.GetIsolate())
); |
| 4313 } | 4313 } |
| 4314 | 4314 |
| 4315 static void sequenceLongMethodMethodCallback(const v8::FunctionCallbackInfo<v8::
Value>& info) | 4315 static void sequenceLongMethodMethodCallback(const v8::FunctionCallbackInfo<v8::
Value>& info) |
| 4316 { | 4316 { |
| 4317 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4317 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4318 TestObjectPythonV8Internal::sequenceLongMethodMethod(info); | 4318 TestObjectPythonV8Internal::sequenceLongMethodMethod(info); |
| 4319 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4319 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4320 } | 4320 } |
| 4321 | 4321 |
| 4322 static void sequenceStringMethodMethod(const v8::FunctionCallbackInfo<v8::Value>
& info) | 4322 static void sequenceStringMethodMethod(const v8::FunctionCallbackInfo<v8::Value>
& info) |
| 4323 { | 4323 { |
| 4324 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4324 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4325 v8SetReturnValue(info, v8Array(imp->sequenceStringMethod(), info.GetIsolate(
))); | 4325 v8SetReturnValue(info, v8Array(imp->sequenceStringMethod(), info.GetIsolate(
))); |
| 4326 } | 4326 } |
| 4327 | 4327 |
| 4328 static void sequenceStringMethodMethodCallback(const v8::FunctionCallbackInfo<v8
::Value>& info) | 4328 static void sequenceStringMethodMethodCallback(const v8::FunctionCallbackInfo<v8
::Value>& info) |
| 4329 { | 4329 { |
| 4330 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4330 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4331 TestObjectPythonV8Internal::sequenceStringMethodMethod(info); | 4331 TestObjectPythonV8Internal::sequenceStringMethodMethod(info); |
| 4332 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4332 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4333 } | 4333 } |
| 4334 | 4334 |
| 4335 static void sequenceTestInterfaceEmptyMethodMethod(const v8::FunctionCallbackInf
o<v8::Value>& info) | 4335 static void sequenceTestInterfaceEmptyMethodMethod(const v8::FunctionCallbackInf
o<v8::Value>& info) |
| 4336 { | 4336 { |
| 4337 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4337 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4338 v8SetReturnValue(info, v8Array(imp->sequenceTestInterfaceEmptyMethod(), info
.GetIsolate())); | 4338 v8SetReturnValue(info, v8Array(imp->sequenceTestInterfaceEmptyMethod(), info
.GetIsolate())); |
| 4339 } | 4339 } |
| 4340 | 4340 |
| 4341 static void sequenceTestInterfaceEmptyMethodMethodCallback(const v8::FunctionCal
lbackInfo<v8::Value>& info) | 4341 static void sequenceTestInterfaceEmptyMethodMethodCallback(const v8::FunctionCal
lbackInfo<v8::Value>& info) |
| 4342 { | 4342 { |
| 4343 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4343 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4344 TestObjectPythonV8Internal::sequenceTestInterfaceEmptyMethodMethod(info); | 4344 TestObjectPythonV8Internal::sequenceTestInterfaceEmptyMethodMethod(info); |
| 4345 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4345 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4346 } | 4346 } |
| 4347 | 4347 |
| 4348 static void voidMethodSequenceLongArgMethod(const v8::FunctionCallbackInfo<v8::V
alue>& info) | 4348 static void voidMethodSequenceLongArgMethod(const v8::FunctionCallbackInfo<v8::V
alue>& info) |
| 4349 { | 4349 { |
| 4350 if (UNLIKELY(info.Length() < 1)) { | 4350 if (UNLIKELY(info.Length() < 1)) { |
| 4351 throwTypeError(ExceptionMessages::failedToExecute("voidMethodSequenceLon
gArg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length(
))), info.GetIsolate()); | 4351 throwTypeError(ExceptionMessages::failedToExecute("voidMethodSequenceLon
gArg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length(
))), info.GetIsolate()); |
| 4352 return; | 4352 return; |
| 4353 } | 4353 } |
| 4354 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4354 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4355 V8TRYCATCH_VOID(Vector<int>, sequenceLongArg, toNativeArray<int>(info[0], 1,
info.GetIsolate())); | 4355 V8TRYCATCH_VOID(Vector<int>, sequenceLongArg, toNativeArray<int>(info[0], 1,
info.GetIsolate())); |
| 4356 imp->voidMethodSequenceLongArg(sequenceLongArg); | 4356 imp->voidMethodSequenceLongArg(sequenceLongArg); |
| 4357 } | 4357 } |
| 4358 | 4358 |
| 4359 static void voidMethodSequenceLongArgMethodCallback(const v8::FunctionCallbackIn
fo<v8::Value>& info) | 4359 static void voidMethodSequenceLongArgMethodCallback(const v8::FunctionCallbackIn
fo<v8::Value>& info) |
| 4360 { | 4360 { |
| 4361 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4361 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4362 TestObjectPythonV8Internal::voidMethodSequenceLongArgMethod(info); | 4362 TestObjectPythonV8Internal::voidMethodSequenceLongArgMethod(info); |
| 4363 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4363 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4364 } | 4364 } |
| 4365 | 4365 |
| 4366 static void voidMethodSequenceStringArgMethod(const v8::FunctionCallbackInfo<v8:
:Value>& info) | 4366 static void voidMethodSequenceStringArgMethod(const v8::FunctionCallbackInfo<v8:
:Value>& info) |
| 4367 { | 4367 { |
| 4368 if (UNLIKELY(info.Length() < 1)) { | 4368 if (UNLIKELY(info.Length() < 1)) { |
| 4369 throwTypeError(ExceptionMessages::failedToExecute("voidMethodSequenceStr
ingArg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Lengt
h())), info.GetIsolate()); | 4369 throwTypeError(ExceptionMessages::failedToExecute("voidMethodSequenceStr
ingArg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Lengt
h())), info.GetIsolate()); |
| 4370 return; | 4370 return; |
| 4371 } | 4371 } |
| 4372 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4372 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4373 V8TRYCATCH_VOID(Vector<String>, sequenceStringArg, toNativeArray<String>(inf
o[0], 1, info.GetIsolate())); | 4373 V8TRYCATCH_VOID(Vector<String>, sequenceStringArg, toNativeArray<String>(inf
o[0], 1, info.GetIsolate())); |
| 4374 imp->voidMethodSequenceStringArg(sequenceStringArg); | 4374 imp->voidMethodSequenceStringArg(sequenceStringArg); |
| 4375 } | 4375 } |
| 4376 | 4376 |
| 4377 static void voidMethodSequenceStringArgMethodCallback(const v8::FunctionCallback
Info<v8::Value>& info) | 4377 static void voidMethodSequenceStringArgMethodCallback(const v8::FunctionCallback
Info<v8::Value>& info) |
| 4378 { | 4378 { |
| 4379 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4379 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4380 TestObjectPythonV8Internal::voidMethodSequenceStringArgMethod(info); | 4380 TestObjectPythonV8Internal::voidMethodSequenceStringArgMethod(info); |
| 4381 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4381 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4382 } | 4382 } |
| 4383 | 4383 |
| 4384 static void voidMethodSequenceTestInterfaceEmptyArgMethod(const v8::FunctionCall
backInfo<v8::Value>& info) | 4384 static void voidMethodSequenceTestInterfaceEmptyArgMethod(const v8::FunctionCall
backInfo<v8::Value>& info) |
| 4385 { | 4385 { |
| 4386 if (UNLIKELY(info.Length() < 1)) { | 4386 if (UNLIKELY(info.Length() < 1)) { |
| 4387 throwTypeError(ExceptionMessages::failedToExecute("voidMethodSequenceTes
tInterfaceEmptyArg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1
, info.Length())), info.GetIsolate()); | 4387 throwTypeError(ExceptionMessages::failedToExecute("voidMethodSequenceTes
tInterfaceEmptyArg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1
, info.Length())), info.GetIsolate()); |
| 4388 return; | 4388 return; |
| 4389 } | 4389 } |
| 4390 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4390 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4391 V8TRYCATCH_VOID(Vector<RefPtr<TestInterfaceEmpty> >, sequenceTestInterfaceEm
ptyArg, (toRefPtrNativeArray<TestInterfaceEmpty, V8TestInterfaceEmpty>(info[0],
1, info.GetIsolate()))); | 4391 V8TRYCATCH_VOID(Vector<RefPtr<TestInterfaceEmpty> >, sequenceTestInterfaceEm
ptyArg, (toRefPtrNativeArray<TestInterfaceEmpty, V8TestInterfaceEmpty>(info[0],
1, info.GetIsolate()))); |
| 4392 imp->voidMethodSequenceTestInterfaceEmptyArg(sequenceTestInterfaceEmptyArg); | 4392 imp->voidMethodSequenceTestInterfaceEmptyArg(sequenceTestInterfaceEmptyArg); |
| 4393 } | 4393 } |
| 4394 | 4394 |
| 4395 static void voidMethodSequenceTestInterfaceEmptyArgMethodCallback(const v8::Func
tionCallbackInfo<v8::Value>& info) | 4395 static void voidMethodSequenceTestInterfaceEmptyArgMethodCallback(const v8::Func
tionCallbackInfo<v8::Value>& info) |
| 4396 { | 4396 { |
| 4397 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4397 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4398 TestObjectPythonV8Internal::voidMethodSequenceTestInterfaceEmptyArgMethod(in
fo); | 4398 TestObjectPythonV8Internal::voidMethodSequenceTestInterfaceEmptyArgMethod(in
fo); |
| 4399 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4399 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4400 } | 4400 } |
| 4401 | 4401 |
| 4402 static void voidMethodNullableStringArgMethod(const v8::FunctionCallbackInfo<v8:
:Value>& info) | 4402 static void voidMethodNullableStringArgMethod(const v8::FunctionCallbackInfo<v8:
:Value>& info) |
| 4403 { | 4403 { |
| 4404 if (UNLIKELY(info.Length() < 1)) { | 4404 if (UNLIKELY(info.Length() < 1)) { |
| 4405 throwTypeError(ExceptionMessages::failedToExecute("voidMethodNullableStr
ingArg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Lengt
h())), info.GetIsolate()); | 4405 throwTypeError(ExceptionMessages::failedToExecute("voidMethodNullableStr
ingArg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Lengt
h())), info.GetIsolate()); |
| 4406 return; | 4406 return; |
| 4407 } | 4407 } |
| 4408 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4408 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4409 V8TRYCATCH_VOID(TestInterfaceEmpty*, nullableTestInterfaceEmptyArg, V8TestIn
terfaceEmpty::hasInstance(info[0], info.GetIsolate(), worldType(info.GetIsolate(
))) ? V8TestInterfaceEmpty::toNative(v8::Handle<v8::Object>::Cast(info[0])) : 0)
; | 4409 V8TRYCATCH_VOID(TestInterfaceEmpty*, nullableTestInterfaceEmptyArg, V8TestIn
terfaceEmpty::hasInstance(info[0], info.GetIsolate(), worldType(info.GetIsolate(
))) ? V8TestInterfaceEmpty::toNative(v8::Handle<v8::Object>::Cast(info[0])) : 0)
; |
| 4410 imp->voidMethodNullableStringArg(nullableTestInterfaceEmptyArg); | 4410 imp->voidMethodNullableStringArg(nullableTestInterfaceEmptyArg); |
| 4411 } | 4411 } |
| 4412 | 4412 |
| 4413 static void voidMethodNullableStringArgMethodCallback(const v8::FunctionCallback
Info<v8::Value>& info) | 4413 static void voidMethodNullableStringArgMethodCallback(const v8::FunctionCallback
Info<v8::Value>& info) |
| 4414 { | 4414 { |
| 4415 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4415 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4416 TestObjectPythonV8Internal::voidMethodNullableStringArgMethod(info); | 4416 TestObjectPythonV8Internal::voidMethodNullableStringArgMethod(info); |
| 4417 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4417 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4418 } | 4418 } |
| 4419 | 4419 |
| 4420 static void voidMethodTestCallbackInterfaceArgMethod(const v8::FunctionCallbackI
nfo<v8::Value>& info) | 4420 static void voidMethodTestCallbackInterfaceArgMethod(const v8::FunctionCallbackI
nfo<v8::Value>& info) |
| 4421 { | 4421 { |
| 4422 if (UNLIKELY(info.Length() < 1)) { | 4422 if (UNLIKELY(info.Length() < 1)) { |
| 4423 throwTypeError(ExceptionMessages::failedToExecute("voidMethodTestCallbac
kInterfaceArg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, inf
o.Length())), info.GetIsolate()); | 4423 throwTypeError(ExceptionMessages::failedToExecute("voidMethodTestCallbac
kInterfaceArg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, inf
o.Length())), info.GetIsolate()); |
| 4424 return; | 4424 return; |
| 4425 } | 4425 } |
| 4426 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4426 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4427 if (info.Length() <= 0 || !info[0]->IsFunction()) { | 4427 if (info.Length() <= 0 || !info[0]->IsFunction()) { |
| 4428 throwTypeError(ExceptionMessages::failedToExecute("voidMethodTestCallbac
kInterfaceArg", "TestObjectPython", "The callback provided as parameter 1 is not
a function."), info.GetIsolate()); | 4428 throwTypeError(ExceptionMessages::failedToExecute("voidMethodTestCallbac
kInterfaceArg", "TestObjectPython", "The callback provided as parameter 1 is not
a function."), info.GetIsolate()); |
| 4429 return; | 4429 return; |
| 4430 } | 4430 } |
| 4431 OwnPtr<TestCallbackInterface> testCallbackInterfaceArg = V8TestCallbackInter
face::create(v8::Handle<v8::Function>::Cast(info[0]), getExecutionContext()); | 4431 OwnPtr<TestCallbackInterface> testCallbackInterfaceArg = V8TestCallbackInter
face::create(v8::Handle<v8::Function>::Cast(info[0]), getExecutionContext()); |
| 4432 imp->voidMethodTestCallbackInterfaceArg(testCallbackInterfaceArg.release()); | 4432 imp->voidMethodTestCallbackInterfaceArg(testCallbackInterfaceArg.release()); |
| 4433 } | 4433 } |
| 4434 | 4434 |
| 4435 static void voidMethodTestCallbackInterfaceArgMethodCallback(const v8::FunctionC
allbackInfo<v8::Value>& info) | 4435 static void voidMethodTestCallbackInterfaceArgMethodCallback(const v8::FunctionC
allbackInfo<v8::Value>& info) |
| 4436 { | 4436 { |
| 4437 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4437 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4438 TestObjectPythonV8Internal::voidMethodTestCallbackInterfaceArgMethod(info); | 4438 TestObjectPythonV8Internal::voidMethodTestCallbackInterfaceArgMethod(info); |
| 4439 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4439 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4440 } | 4440 } |
| 4441 | 4441 |
| 4442 static void voidMethodOptionalTestCallbackInterfaceArgMethod(const v8::FunctionC
allbackInfo<v8::Value>& info) | 4442 static void voidMethodOptionalTestCallbackInterfaceArgMethod(const v8::FunctionC
allbackInfo<v8::Value>& info) |
| 4443 { | 4443 { |
| 4444 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4444 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4445 OwnPtr<TestCallbackInterface> optionalTestCallbackInterfaceArg; | 4445 OwnPtr<TestCallbackInterface> optionalTestCallbackInterfaceArg; |
| 4446 if (info.Length() > 0 && !isUndefinedOrNull(info[0])) { | 4446 if (info.Length() > 0 && !isUndefinedOrNull(info[0])) { |
| 4447 if (!info[0]->IsFunction()) { | 4447 if (!info[0]->IsFunction()) { |
| 4448 throwTypeError(ExceptionMessages::failedToExecute("voidMethodOptiona
lTestCallbackInterfaceArg", "TestObjectPython", "The callback provided as parame
ter 1 is not a function."), info.GetIsolate()); | 4448 throwTypeError(ExceptionMessages::failedToExecute("voidMethodOptiona
lTestCallbackInterfaceArg", "TestObjectPython", "The callback provided as parame
ter 1 is not a function."), info.GetIsolate()); |
| 4449 return; | 4449 return; |
| 4450 } | 4450 } |
| 4451 optionalTestCallbackInterfaceArg = V8TestCallbackInterface::create(v8::H
andle<v8::Function>::Cast(info[0]), getExecutionContext()); | 4451 optionalTestCallbackInterfaceArg = V8TestCallbackInterface::create(v8::H
andle<v8::Function>::Cast(info[0]), getExecutionContext()); |
| 4452 } | 4452 } |
| 4453 imp->voidMethodOptionalTestCallbackInterfaceArg(optionalTestCallbackInterfac
eArg.release()); | 4453 imp->voidMethodOptionalTestCallbackInterfaceArg(optionalTestCallbackInterfac
eArg.release()); |
| 4454 } | 4454 } |
| 4455 | 4455 |
| 4456 static void voidMethodOptionalTestCallbackInterfaceArgMethodCallback(const v8::F
unctionCallbackInfo<v8::Value>& info) | 4456 static void voidMethodOptionalTestCallbackInterfaceArgMethodCallback(const v8::F
unctionCallbackInfo<v8::Value>& info) |
| 4457 { | 4457 { |
| 4458 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4458 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4459 TestObjectPythonV8Internal::voidMethodOptionalTestCallbackInterfaceArgMethod
(info); | 4459 TestObjectPythonV8Internal::voidMethodOptionalTestCallbackInterfaceArgMethod
(info); |
| 4460 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4460 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4461 } | 4461 } |
| 4462 | 4462 |
| 4463 static void voidMethodNullableTestCallbackInterfaceArgMethod(const v8::FunctionC
allbackInfo<v8::Value>& info) | 4463 static void voidMethodNullableTestCallbackInterfaceArgMethod(const v8::FunctionC
allbackInfo<v8::Value>& info) |
| 4464 { | 4464 { |
| 4465 if (UNLIKELY(info.Length() < 1)) { | 4465 if (UNLIKELY(info.Length() < 1)) { |
| 4466 throwTypeError(ExceptionMessages::failedToExecute("voidMethodNullableTes
tCallbackInterfaceArg", "TestObjectPython", ExceptionMessages::notEnoughArgument
s(1, info.Length())), info.GetIsolate()); | 4466 throwTypeError(ExceptionMessages::failedToExecute("voidMethodNullableTes
tCallbackInterfaceArg", "TestObjectPython", ExceptionMessages::notEnoughArgument
s(1, info.Length())), info.GetIsolate()); |
| 4467 return; | 4467 return; |
| 4468 } | 4468 } |
| 4469 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4469 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4470 if (info.Length() <= 0 || !(info[0]->IsFunction() || info[0]->IsNull())) { | 4470 if (info.Length() <= 0 || !(info[0]->IsFunction() || info[0]->IsNull())) { |
| 4471 throwTypeError(ExceptionMessages::failedToExecute("voidMethodNullableTes
tCallbackInterfaceArg", "TestObjectPython", "The callback provided as parameter
1 is not a function."), info.GetIsolate()); | 4471 throwTypeError(ExceptionMessages::failedToExecute("voidMethodNullableTes
tCallbackInterfaceArg", "TestObjectPython", "The callback provided as parameter
1 is not a function."), info.GetIsolate()); |
| 4472 return; | 4472 return; |
| 4473 } | 4473 } |
| 4474 OwnPtr<TestCallbackInterface> testCallbackInterfaceArg = info[0]->IsNull() ?
nullptr : V8TestCallbackInterface::create(v8::Handle<v8::Function>::Cast(info[0
]), getExecutionContext()); | 4474 OwnPtr<TestCallbackInterface> testCallbackInterfaceArg = info[0]->IsNull() ?
nullptr : V8TestCallbackInterface::create(v8::Handle<v8::Function>::Cast(info[0
]), getExecutionContext()); |
| 4475 imp->voidMethodNullableTestCallbackInterfaceArg(testCallbackInterfaceArg.rel
ease()); | 4475 imp->voidMethodNullableTestCallbackInterfaceArg(testCallbackInterfaceArg.rel
ease()); |
| 4476 } | 4476 } |
| 4477 | 4477 |
| 4478 static void voidMethodNullableTestCallbackInterfaceArgMethodCallback(const v8::F
unctionCallbackInfo<v8::Value>& info) | 4478 static void voidMethodNullableTestCallbackInterfaceArgMethodCallback(const v8::F
unctionCallbackInfo<v8::Value>& info) |
| 4479 { | 4479 { |
| 4480 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4480 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4481 TestObjectPythonV8Internal::voidMethodNullableTestCallbackInterfaceArgMethod
(info); | 4481 TestObjectPythonV8Internal::voidMethodNullableTestCallbackInterfaceArgMethod
(info); |
| 4482 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4482 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4483 } | 4483 } |
| 4484 | 4484 |
| 4485 static void testEnumMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info
) | 4485 static void testEnumMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info
) |
| 4486 { | 4486 { |
| 4487 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4487 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4488 v8SetReturnValueString(info, imp->testEnumMethod(), info.GetIsolate()); | 4488 v8SetReturnValueString(info, imp->testEnumMethod(), info.GetIsolate()); |
| 4489 } | 4489 } |
| 4490 | 4490 |
| 4491 static void testEnumMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Valu
e>& info) | 4491 static void testEnumMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Valu
e>& info) |
| 4492 { | 4492 { |
| 4493 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4493 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4494 TestObjectPythonV8Internal::testEnumMethodMethod(info); | 4494 TestObjectPythonV8Internal::testEnumMethodMethod(info); |
| 4495 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4495 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4496 } | 4496 } |
| 4497 | 4497 |
| 4498 static void voidMethodTestEnumArgMethod(const v8::FunctionCallbackInfo<v8::Value
>& info) | 4498 static void voidMethodTestEnumArgMethod(const v8::FunctionCallbackInfo<v8::Value
>& info) |
| 4499 { | 4499 { |
| 4500 if (UNLIKELY(info.Length() < 1)) { | 4500 if (UNLIKELY(info.Length() < 1)) { |
| 4501 throwTypeError(ExceptionMessages::failedToExecute("voidMethodTestEnumArg
", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length())),
info.GetIsolate()); | 4501 throwTypeError(ExceptionMessages::failedToExecute("voidMethodTestEnumArg
", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length())),
info.GetIsolate()); |
| 4502 return; | 4502 return; |
| 4503 } | 4503 } |
| 4504 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4504 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4505 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, testEnumTypeArg, in
fo[0]); | 4505 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, testEnumTypeArg, in
fo[0]); |
| 4506 String string = testEnumTypeArg; | 4506 String string = testEnumTypeArg; |
| 4507 if (!(string == "" || string == "EnumValue1" || string == "EnumValue2" || st
ring == "EnumValue3")) { | 4507 if (!(string == "" || string == "EnumValue1" || string == "EnumValue2" || st
ring == "EnumValue3")) { |
| 4508 throwTypeError(ExceptionMessages::failedToExecute("voidMethodTestEnumArg
", "TestObjectPython", "parameter 1 ('" + string + "') is not a valid enum value
."), info.GetIsolate()); | 4508 throwTypeError(ExceptionMessages::failedToExecute("voidMethodTestEnumArg
", "TestObjectPython", "parameter 1 ('" + string + "') is not a valid enum value
."), info.GetIsolate()); |
| 4509 return; | 4509 return; |
| 4510 } | 4510 } |
| 4511 imp->voidMethodTestEnumArg(testEnumTypeArg); | 4511 imp->voidMethodTestEnumArg(testEnumTypeArg); |
| 4512 } | 4512 } |
| 4513 | 4513 |
| 4514 static void voidMethodTestEnumArgMethodCallback(const v8::FunctionCallbackInfo<v
8::Value>& info) | 4514 static void voidMethodTestEnumArgMethodCallback(const v8::FunctionCallbackInfo<v
8::Value>& info) |
| 4515 { | 4515 { |
| 4516 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4516 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4517 TestObjectPythonV8Internal::voidMethodTestEnumArgMethod(info); | 4517 TestObjectPythonV8Internal::voidMethodTestEnumArgMethod(info); |
| 4518 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4518 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4519 } | 4519 } |
| 4520 | 4520 |
| 4521 static void dictionaryMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& in
fo) | 4521 static void dictionaryMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& in
fo) |
| 4522 { | 4522 { |
| 4523 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4523 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4524 v8SetReturnValue(info, imp->dictionaryMethod()); | 4524 v8SetReturnValue(info, imp->dictionaryMethod()); |
| 4525 } | 4525 } |
| 4526 | 4526 |
| 4527 static void dictionaryMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Va
lue>& info) | 4527 static void dictionaryMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Va
lue>& info) |
| 4528 { | 4528 { |
| 4529 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4529 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4530 TestObjectPythonV8Internal::dictionaryMethodMethod(info); | 4530 TestObjectPythonV8Internal::dictionaryMethodMethod(info); |
| 4531 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4531 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4532 } | 4532 } |
| 4533 | 4533 |
| 4534 static void nodeFilterMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& in
fo) | 4534 static void nodeFilterMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& in
fo) |
| 4535 { | 4535 { |
| 4536 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4536 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4537 v8SetReturnValue(info, imp->nodeFilterMethod()); | 4537 v8SetReturnValue(info, imp->nodeFilterMethod()); |
| 4538 } | 4538 } |
| 4539 | 4539 |
| 4540 static void nodeFilterMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Va
lue>& info) | 4540 static void nodeFilterMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Va
lue>& info) |
| 4541 { | 4541 { |
| 4542 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4542 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4543 TestObjectPythonV8Internal::nodeFilterMethodMethod(info); | 4543 TestObjectPythonV8Internal::nodeFilterMethodMethod(info); |
| 4544 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4544 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4545 } | 4545 } |
| 4546 | 4546 |
| 4547 static void promiseMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) | 4547 static void promiseMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| 4548 { | 4548 { |
| 4549 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4549 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4550 v8SetReturnValue(info, imp->promiseMethod().v8Value()); | 4550 v8SetReturnValue(info, imp->promiseMethod().v8Value()); |
| 4551 } | 4551 } |
| 4552 | 4552 |
| 4553 static void promiseMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value
>& info) | 4553 static void promiseMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value
>& info) |
| 4554 { | 4554 { |
| 4555 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4555 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4556 TestObjectPythonV8Internal::promiseMethodMethod(info); | 4556 TestObjectPythonV8Internal::promiseMethodMethod(info); |
| 4557 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4557 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4558 } | 4558 } |
| 4559 | 4559 |
| 4560 static void serializedScriptValueMethodMethod(const v8::FunctionCallbackInfo<v8:
:Value>& info) | 4560 static void serializedScriptValueMethodMethod(const v8::FunctionCallbackInfo<v8:
:Value>& info) |
| 4561 { | 4561 { |
| 4562 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4562 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4563 v8SetReturnValue(info, imp->serializedScriptValueMethod() ? imp->serializedS
criptValueMethod()->deserialize() : v8::Handle<v8::Value>(v8::Null(info.GetIsola
te()))); | 4563 v8SetReturnValue(info, imp->serializedScriptValueMethod() ? imp->serializedS
criptValueMethod()->deserialize() : v8::Handle<v8::Value>(v8::Null(info.GetIsola
te()))); |
| 4564 } | 4564 } |
| 4565 | 4565 |
| 4566 static void serializedScriptValueMethodMethodCallback(const v8::FunctionCallback
Info<v8::Value>& info) | 4566 static void serializedScriptValueMethodMethodCallback(const v8::FunctionCallback
Info<v8::Value>& info) |
| 4567 { | 4567 { |
| 4568 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4568 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4569 TestObjectPythonV8Internal::serializedScriptValueMethodMethod(info); | 4569 TestObjectPythonV8Internal::serializedScriptValueMethodMethod(info); |
| 4570 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4570 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4571 } | 4571 } |
| 4572 | 4572 |
| 4573 static void xPathNSResolverMethodMethod(const v8::FunctionCallbackInfo<v8::Value
>& info) | 4573 static void xPathNSResolverMethodMethod(const v8::FunctionCallbackInfo<v8::Value
>& info) |
| 4574 { | 4574 { |
| 4575 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4575 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4576 v8SetReturnValue(info, imp->xPathNSResolverMethod()); | 4576 v8SetReturnValue(info, imp->xPathNSResolverMethod()); |
| 4577 } | 4577 } |
| 4578 | 4578 |
| 4579 static void xPathNSResolverMethodMethodCallback(const v8::FunctionCallbackInfo<v
8::Value>& info) | 4579 static void xPathNSResolverMethodMethodCallback(const v8::FunctionCallbackInfo<v
8::Value>& info) |
| 4580 { | 4580 { |
| 4581 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4581 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4582 TestObjectPythonV8Internal::xPathNSResolverMethodMethod(info); | 4582 TestObjectPythonV8Internal::xPathNSResolverMethodMethod(info); |
| 4583 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4583 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4584 } | 4584 } |
| 4585 | 4585 |
| 4586 static void voidMethodDictionaryArgMethod(const v8::FunctionCallbackInfo<v8::Val
ue>& info) | 4586 static void voidMethodDictionaryArgMethod(const v8::FunctionCallbackInfo<v8::Val
ue>& info) |
| 4587 { | 4587 { |
| 4588 if (UNLIKELY(info.Length() < 1)) { | 4588 if (UNLIKELY(info.Length() < 1)) { |
| 4589 throwTypeError(ExceptionMessages::failedToExecute("voidMethodDictionaryA
rg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length())
), info.GetIsolate()); | 4589 throwTypeError(ExceptionMessages::failedToExecute("voidMethodDictionaryA
rg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length())
), info.GetIsolate()); |
| 4590 return; | 4590 return; |
| 4591 } | 4591 } |
| 4592 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4592 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4593 V8TRYCATCH_VOID(Dictionary, dictionaryArg, Dictionary(info[0], info.GetIsola
te())); | 4593 V8TRYCATCH_VOID(Dictionary, dictionaryArg, Dictionary(info[0], info.GetIsola
te())); |
| 4594 if (!dictionaryArg.isUndefinedOrNull() && !dictionaryArg.isObject()) { | 4594 if (!dictionaryArg.isUndefinedOrNull() && !dictionaryArg.isObject()) { |
| 4595 throwTypeError(ExceptionMessages::failedToExecute("voidMethodDictionaryA
rg", "TestObjectPython", "parameter 1 ('dictionaryArg') is not an object."), inf
o.GetIsolate()); | 4595 throwTypeError(ExceptionMessages::failedToExecute("voidMethodDictionaryA
rg", "TestObjectPython", "parameter 1 ('dictionaryArg') is not an object."), inf
o.GetIsolate()); |
| 4596 return; | 4596 return; |
| 4597 } | 4597 } |
| 4598 imp->voidMethodDictionaryArg(dictionaryArg); | 4598 imp->voidMethodDictionaryArg(dictionaryArg); |
| 4599 } | 4599 } |
| 4600 | 4600 |
| 4601 static void voidMethodDictionaryArgMethodCallback(const v8::FunctionCallbackInfo
<v8::Value>& info) | 4601 static void voidMethodDictionaryArgMethodCallback(const v8::FunctionCallbackInfo
<v8::Value>& info) |
| 4602 { | 4602 { |
| 4603 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4603 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4604 TestObjectPythonV8Internal::voidMethodDictionaryArgMethod(info); | 4604 TestObjectPythonV8Internal::voidMethodDictionaryArgMethod(info); |
| 4605 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4605 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4606 } | 4606 } |
| 4607 | 4607 |
| 4608 static void voidMethodNodeFilterArgMethod(const v8::FunctionCallbackInfo<v8::Val
ue>& info) | 4608 static void voidMethodNodeFilterArgMethod(const v8::FunctionCallbackInfo<v8::Val
ue>& info) |
| 4609 { | 4609 { |
| 4610 if (UNLIKELY(info.Length() < 1)) { | 4610 if (UNLIKELY(info.Length() < 1)) { |
| 4611 throwTypeError(ExceptionMessages::failedToExecute("voidMethodNodeFilterA
rg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length())
), info.GetIsolate()); | 4611 throwTypeError(ExceptionMessages::failedToExecute("voidMethodNodeFilterA
rg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length())
), info.GetIsolate()); |
| 4612 return; | 4612 return; |
| 4613 } | 4613 } |
| 4614 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4614 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4615 V8TRYCATCH_VOID(RefPtr<NodeFilter>, nodeFilterArg, toNodeFilter(info[0], inf
o.GetIsolate())); | 4615 V8TRYCATCH_VOID(RefPtr<NodeFilter>, nodeFilterArg, toNodeFilter(info[0], inf
o.GetIsolate())); |
| 4616 imp->voidMethodNodeFilterArg(nodeFilterArg.release()); | 4616 imp->voidMethodNodeFilterArg(nodeFilterArg.release()); |
| 4617 } | 4617 } |
| 4618 | 4618 |
| 4619 static void voidMethodNodeFilterArgMethodCallback(const v8::FunctionCallbackInfo
<v8::Value>& info) | 4619 static void voidMethodNodeFilterArgMethodCallback(const v8::FunctionCallbackInfo
<v8::Value>& info) |
| 4620 { | 4620 { |
| 4621 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4621 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4622 TestObjectPythonV8Internal::voidMethodNodeFilterArgMethod(info); | 4622 TestObjectPythonV8Internal::voidMethodNodeFilterArgMethod(info); |
| 4623 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4623 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4624 } | 4624 } |
| 4625 | 4625 |
| 4626 static void voidMethodPromiseArgMethod(const v8::FunctionCallbackInfo<v8::Value>
& info) | 4626 static void voidMethodPromiseArgMethod(const v8::FunctionCallbackInfo<v8::Value>
& info) |
| 4627 { | 4627 { |
| 4628 if (UNLIKELY(info.Length() < 1)) { | 4628 if (UNLIKELY(info.Length() < 1)) { |
| 4629 throwTypeError(ExceptionMessages::failedToExecute("voidMethodPromiseArg"
, "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length())),
info.GetIsolate()); | 4629 throwTypeError(ExceptionMessages::failedToExecute("voidMethodPromiseArg"
, "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Length())),
info.GetIsolate()); |
| 4630 return; | 4630 return; |
| 4631 } | 4631 } |
| 4632 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4632 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4633 V8TRYCATCH_VOID(ScriptPromise, promiseArg, ScriptPromise(info[0])); | 4633 V8TRYCATCH_VOID(ScriptPromise, promiseArg, ScriptPromise(info[0])); |
| 4634 if (!promiseArg.isUndefinedOrNull() && !promiseArg.isObject()) { | 4634 if (!promiseArg.isUndefinedOrNull() && !promiseArg.isObject()) { |
| 4635 throwTypeError(ExceptionMessages::failedToExecute("voidMethodPromiseArg"
, "TestObjectPython", "parameter 1 ('promiseArg') is not an object."), info.GetI
solate()); | 4635 throwTypeError(ExceptionMessages::failedToExecute("voidMethodPromiseArg"
, "TestObjectPython", "parameter 1 ('promiseArg') is not an object."), info.GetI
solate()); |
| 4636 return; | 4636 return; |
| 4637 } | 4637 } |
| 4638 imp->voidMethodPromiseArg(promiseArg); | 4638 imp->voidMethodPromiseArg(promiseArg); |
| 4639 } | 4639 } |
| 4640 | 4640 |
| 4641 static void voidMethodPromiseArgMethodCallback(const v8::FunctionCallbackInfo<v8
::Value>& info) | 4641 static void voidMethodPromiseArgMethodCallback(const v8::FunctionCallbackInfo<v8
::Value>& info) |
| 4642 { | 4642 { |
| 4643 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4643 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4644 TestObjectPythonV8Internal::voidMethodPromiseArgMethod(info); | 4644 TestObjectPythonV8Internal::voidMethodPromiseArgMethod(info); |
| 4645 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4645 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4646 } | 4646 } |
| 4647 | 4647 |
| 4648 static void voidMethodSerializedScriptValueArgMethod(const v8::FunctionCallbackI
nfo<v8::Value>& info) | 4648 static void voidMethodSerializedScriptValueArgMethod(const v8::FunctionCallbackI
nfo<v8::Value>& info) |
| 4649 { | 4649 { |
| 4650 ExceptionState exceptionState(ExceptionState::ExecutionContext, "voidMethodS
erializedScriptValueArg", "TestObjectPython", info.Holder(), info.GetIsolate()); | 4650 ExceptionState exceptionState(ExceptionState::ExecutionContext, "voidMethodS
erializedScriptValueArg", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 4651 if (UNLIKELY(info.Length() < 1)) { | 4651 if (UNLIKELY(info.Length() < 1)) { |
| 4652 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); | 4652 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); |
| 4653 exceptionState.throwIfNeeded(); | 4653 exceptionState.throwIfNeeded(); |
| 4654 return; | 4654 return; |
| 4655 } | 4655 } |
| 4656 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4656 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4657 RefPtr<SerializedScriptValue> serializedScriptValueArg = SerializedScriptVal
ue::create(info[0], 0, 0, exceptionState, info.GetIsolate()); | 4657 RefPtr<SerializedScriptValue> serializedScriptValueArg = SerializedScriptVal
ue::create(info[0], 0, 0, exceptionState, info.GetIsolate()); |
| 4658 if (exceptionState.throwIfNeeded()) | 4658 if (exceptionState.throwIfNeeded()) |
| 4659 return; | 4659 return; |
| 4660 imp->voidMethodSerializedScriptValueArg(serializedScriptValueArg); | 4660 imp->voidMethodSerializedScriptValueArg(serializedScriptValueArg); |
| 4661 } | 4661 } |
| 4662 | 4662 |
| 4663 static void voidMethodSerializedScriptValueArgMethodCallback(const v8::FunctionC
allbackInfo<v8::Value>& info) | 4663 static void voidMethodSerializedScriptValueArgMethodCallback(const v8::FunctionC
allbackInfo<v8::Value>& info) |
| 4664 { | 4664 { |
| 4665 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4665 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4666 TestObjectPythonV8Internal::voidMethodSerializedScriptValueArgMethod(info); | 4666 TestObjectPythonV8Internal::voidMethodSerializedScriptValueArgMethod(info); |
| 4667 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4667 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4668 } | 4668 } |
| 4669 | 4669 |
| 4670 static void voidMethodXPathNSResolverArgMethod(const v8::FunctionCallbackInfo<v8
::Value>& info) | 4670 static void voidMethodXPathNSResolverArgMethod(const v8::FunctionCallbackInfo<v8
::Value>& info) |
| 4671 { | 4671 { |
| 4672 if (UNLIKELY(info.Length() < 1)) { | 4672 if (UNLIKELY(info.Length() < 1)) { |
| 4673 throwTypeError(ExceptionMessages::failedToExecute("voidMethodXPathNSReso
lverArg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Leng
th())), info.GetIsolate()); | 4673 throwTypeError(ExceptionMessages::failedToExecute("voidMethodXPathNSReso
lverArg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.Leng
th())), info.GetIsolate()); |
| 4674 return; | 4674 return; |
| 4675 } | 4675 } |
| 4676 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4676 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4677 V8TRYCATCH_VOID(RefPtr<XPathNSResolver>, xPathNSResolverArg, toXPathNSResolv
er(info[0], info.GetIsolate())); | 4677 V8TRYCATCH_VOID(RefPtr<XPathNSResolver>, xPathNSResolverArg, toXPathNSResolv
er(info[0], info.GetIsolate())); |
| 4678 imp->voidMethodXPathNSResolverArg(xPathNSResolverArg.release()); | 4678 imp->voidMethodXPathNSResolverArg(xPathNSResolverArg.release()); |
| 4679 } | 4679 } |
| 4680 | 4680 |
| 4681 static void voidMethodXPathNSResolverArgMethodCallback(const v8::FunctionCallbac
kInfo<v8::Value>& info) | 4681 static void voidMethodXPathNSResolverArgMethodCallback(const v8::FunctionCallbac
kInfo<v8::Value>& info) |
| 4682 { | 4682 { |
| 4683 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4683 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4684 TestObjectPythonV8Internal::voidMethodXPathNSResolverArgMethod(info); | 4684 TestObjectPythonV8Internal::voidMethodXPathNSResolverArgMethod(info); |
| 4685 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4685 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4686 } | 4686 } |
| 4687 | 4687 |
| 4688 static void voidMethodSequenceDictionaryArgMethod(const v8::FunctionCallbackInfo
<v8::Value>& info) | 4688 static void voidMethodSequenceDictionaryArgMethod(const v8::FunctionCallbackInfo
<v8::Value>& info) |
| 4689 { | 4689 { |
| 4690 if (UNLIKELY(info.Length() < 1)) { | 4690 if (UNLIKELY(info.Length() < 1)) { |
| 4691 throwTypeError(ExceptionMessages::failedToExecute("voidMethodSequenceDic
tionaryArg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.L
ength())), info.GetIsolate()); | 4691 throwTypeError(ExceptionMessages::failedToExecute("voidMethodSequenceDic
tionaryArg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, info.L
ength())), info.GetIsolate()); |
| 4692 return; | 4692 return; |
| 4693 } | 4693 } |
| 4694 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4694 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4695 V8TRYCATCH_VOID(Vector<Dictionary>, sequenceDictionaryArg, toNativeArray<Dic
tionary>(info[0], 1, info.GetIsolate())); | 4695 V8TRYCATCH_VOID(Vector<Dictionary>, sequenceDictionaryArg, toNativeArray<Dic
tionary>(info[0], 1, info.GetIsolate())); |
| 4696 imp->voidMethodSequenceDictionaryArg(sequenceDictionaryArg); | 4696 imp->voidMethodSequenceDictionaryArg(sequenceDictionaryArg); |
| 4697 } | 4697 } |
| 4698 | 4698 |
| 4699 static void voidMethodSequenceDictionaryArgMethodCallback(const v8::FunctionCall
backInfo<v8::Value>& info) | 4699 static void voidMethodSequenceDictionaryArgMethodCallback(const v8::FunctionCall
backInfo<v8::Value>& info) |
| 4700 { | 4700 { |
| 4701 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4701 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4702 TestObjectPythonV8Internal::voidMethodSequenceDictionaryArgMethod(info); | 4702 TestObjectPythonV8Internal::voidMethodSequenceDictionaryArgMethod(info); |
| 4703 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4703 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4704 } | 4704 } |
| 4705 | 4705 |
| 4706 static void voidMethodStringArgLongArgMethod(const v8::FunctionCallbackInfo<v8::
Value>& info) | 4706 static void voidMethodStringArgLongArgMethod(const v8::FunctionCallbackInfo<v8::
Value>& info) |
| 4707 { | 4707 { |
| 4708 ExceptionState exceptionState(ExceptionState::ExecutionContext, "voidMethodS
tringArgLongArg", "TestObjectPython", info.Holder(), info.GetIsolate()); | 4708 ExceptionState exceptionState(ExceptionState::ExecutionContext, "voidMethodS
tringArgLongArg", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 4709 if (UNLIKELY(info.Length() < 2)) { | 4709 if (UNLIKELY(info.Length() < 2)) { |
| 4710 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(2, i
nfo.Length())); | 4710 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(2, i
nfo.Length())); |
| 4711 exceptionState.throwIfNeeded(); | 4711 exceptionState.throwIfNeeded(); |
| 4712 return; | 4712 return; |
| 4713 } | 4713 } |
| 4714 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4714 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4715 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, stringArg, info[0])
; | 4715 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, stringArg, info[0])
; |
| 4716 V8TRYCATCH_EXCEPTION_VOID(int, longArg, toInt32(info[1], exceptionState), ex
ceptionState); | 4716 V8TRYCATCH_EXCEPTION_VOID(int, longArg, toInt32(info[1], exceptionState), ex
ceptionState); |
| 4717 imp->voidMethodStringArgLongArg(stringArg, longArg); | 4717 imp->voidMethodStringArgLongArg(stringArg, longArg); |
| 4718 } | 4718 } |
| 4719 | 4719 |
| 4720 static void voidMethodStringArgLongArgMethodCallback(const v8::FunctionCallbackI
nfo<v8::Value>& info) | 4720 static void voidMethodStringArgLongArgMethodCallback(const v8::FunctionCallbackI
nfo<v8::Value>& info) |
| 4721 { | 4721 { |
| 4722 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4722 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4723 TestObjectPythonV8Internal::voidMethodStringArgLongArgMethod(info); | 4723 TestObjectPythonV8Internal::voidMethodStringArgLongArgMethod(info); |
| 4724 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4724 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4725 } | 4725 } |
| 4726 | 4726 |
| 4727 static void voidMethodOptionalStringArgMethod(const v8::FunctionCallbackInfo<v8:
:Value>& info) | 4727 static void voidMethodOptionalStringArgMethod(const v8::FunctionCallbackInfo<v8:
:Value>& info) |
| 4728 { | 4728 { |
| 4729 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4729 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4730 if (UNLIKELY(info.Length() <= 0)) { | 4730 if (UNLIKELY(info.Length() <= 0)) { |
| 4731 imp->voidMethodOptionalStringArg(); | 4731 imp->voidMethodOptionalStringArg(); |
| 4732 return; | 4732 return; |
| 4733 } | 4733 } |
| 4734 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, optionalStringArg,
info[0]); | 4734 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, optionalStringArg,
info[0]); |
| 4735 imp->voidMethodOptionalStringArg(optionalStringArg); | 4735 imp->voidMethodOptionalStringArg(optionalStringArg); |
| 4736 } | 4736 } |
| 4737 | 4737 |
| 4738 static void voidMethodOptionalStringArgMethodCallback(const v8::FunctionCallback
Info<v8::Value>& info) | 4738 static void voidMethodOptionalStringArgMethodCallback(const v8::FunctionCallback
Info<v8::Value>& info) |
| 4739 { | 4739 { |
| 4740 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4740 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4741 TestObjectPythonV8Internal::voidMethodOptionalStringArgMethod(info); | 4741 TestObjectPythonV8Internal::voidMethodOptionalStringArgMethod(info); |
| 4742 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4742 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4743 } | 4743 } |
| 4744 | 4744 |
| 4745 static void voidMethodOptionalTestInterfaceEmptyArgMethod(const v8::FunctionCall
backInfo<v8::Value>& info) | 4745 static void voidMethodOptionalTestInterfaceEmptyArgMethod(const v8::FunctionCall
backInfo<v8::Value>& info) |
| 4746 { | 4746 { |
| 4747 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4747 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4748 if (UNLIKELY(info.Length() <= 0)) { | 4748 if (UNLIKELY(info.Length() <= 0)) { |
| 4749 imp->voidMethodOptionalTestInterfaceEmptyArg(); | 4749 imp->voidMethodOptionalTestInterfaceEmptyArg(); |
| 4750 return; | 4750 return; |
| 4751 } | 4751 } |
| 4752 V8TRYCATCH_VOID(TestInterfaceEmpty*, optionalTestInterfaceEmptyArg, V8TestIn
terfaceEmpty::hasInstance(info[0], info.GetIsolate(), worldType(info.GetIsolate(
))) ? V8TestInterfaceEmpty::toNative(v8::Handle<v8::Object>::Cast(info[0])) : 0)
; | 4752 V8TRYCATCH_VOID(TestInterfaceEmpty*, optionalTestInterfaceEmptyArg, V8TestIn
terfaceEmpty::hasInstance(info[0], info.GetIsolate(), worldType(info.GetIsolate(
))) ? V8TestInterfaceEmpty::toNative(v8::Handle<v8::Object>::Cast(info[0])) : 0)
; |
| 4753 imp->voidMethodOptionalTestInterfaceEmptyArg(optionalTestInterfaceEmptyArg); | 4753 imp->voidMethodOptionalTestInterfaceEmptyArg(optionalTestInterfaceEmptyArg); |
| 4754 } | 4754 } |
| 4755 | 4755 |
| 4756 static void voidMethodOptionalTestInterfaceEmptyArgMethodCallback(const v8::Func
tionCallbackInfo<v8::Value>& info) | 4756 static void voidMethodOptionalTestInterfaceEmptyArgMethodCallback(const v8::Func
tionCallbackInfo<v8::Value>& info) |
| 4757 { | 4757 { |
| 4758 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4758 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4759 TestObjectPythonV8Internal::voidMethodOptionalTestInterfaceEmptyArgMethod(in
fo); | 4759 TestObjectPythonV8Internal::voidMethodOptionalTestInterfaceEmptyArgMethod(in
fo); |
| 4760 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4760 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4761 } | 4761 } |
| 4762 | 4762 |
| 4763 static void voidMethodOptionalLongArgMethod(const v8::FunctionCallbackInfo<v8::V
alue>& info) | 4763 static void voidMethodOptionalLongArgMethod(const v8::FunctionCallbackInfo<v8::V
alue>& info) |
| 4764 { | 4764 { |
| 4765 ExceptionState exceptionState(ExceptionState::ExecutionContext, "voidMethodO
ptionalLongArg", "TestObjectPython", info.Holder(), info.GetIsolate()); | 4765 ExceptionState exceptionState(ExceptionState::ExecutionContext, "voidMethodO
ptionalLongArg", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 4766 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4766 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4767 if (UNLIKELY(info.Length() <= 0)) { | 4767 if (UNLIKELY(info.Length() <= 0)) { |
| 4768 imp->voidMethodOptionalLongArg(); | 4768 imp->voidMethodOptionalLongArg(); |
| 4769 return; | 4769 return; |
| 4770 } | 4770 } |
| 4771 V8TRYCATCH_EXCEPTION_VOID(int, optionalLongArg, toInt32(info[0], exceptionSt
ate), exceptionState); | 4771 V8TRYCATCH_EXCEPTION_VOID(int, optionalLongArg, toInt32(info[0], exceptionSt
ate), exceptionState); |
| 4772 imp->voidMethodOptionalLongArg(optionalLongArg); | 4772 imp->voidMethodOptionalLongArg(optionalLongArg); |
| 4773 } | 4773 } |
| 4774 | 4774 |
| 4775 static void voidMethodOptionalLongArgMethodCallback(const v8::FunctionCallbackIn
fo<v8::Value>& info) | 4775 static void voidMethodOptionalLongArgMethodCallback(const v8::FunctionCallbackIn
fo<v8::Value>& info) |
| 4776 { | 4776 { |
| 4777 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4777 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4778 TestObjectPythonV8Internal::voidMethodOptionalLongArgMethod(info); | 4778 TestObjectPythonV8Internal::voidMethodOptionalLongArgMethod(info); |
| 4779 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4779 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4780 } | 4780 } |
| 4781 | 4781 |
| 4782 static void stringMethodOptionalLongArgMethod(const v8::FunctionCallbackInfo<v8:
:Value>& info) | 4782 static void stringMethodOptionalLongArgMethod(const v8::FunctionCallbackInfo<v8:
:Value>& info) |
| 4783 { | 4783 { |
| 4784 ExceptionState exceptionState(ExceptionState::ExecutionContext, "stringMetho
dOptionalLongArg", "TestObjectPython", info.Holder(), info.GetIsolate()); | 4784 ExceptionState exceptionState(ExceptionState::ExecutionContext, "stringMetho
dOptionalLongArg", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 4785 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4785 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4786 if (UNLIKELY(info.Length() <= 0)) { | 4786 if (UNLIKELY(info.Length() <= 0)) { |
| 4787 v8SetReturnValueString(info, imp->stringMethodOptionalLongArg(), info.Ge
tIsolate()); | 4787 v8SetReturnValueString(info, imp->stringMethodOptionalLongArg(), info.Ge
tIsolate()); |
| 4788 return; | 4788 return; |
| 4789 } | 4789 } |
| 4790 V8TRYCATCH_EXCEPTION_VOID(int, optionalLongArg, toInt32(info[0], exceptionSt
ate), exceptionState); | 4790 V8TRYCATCH_EXCEPTION_VOID(int, optionalLongArg, toInt32(info[0], exceptionSt
ate), exceptionState); |
| 4791 v8SetReturnValueString(info, imp->stringMethodOptionalLongArg(optionalLongAr
g), info.GetIsolate()); | 4791 v8SetReturnValueString(info, imp->stringMethodOptionalLongArg(optionalLongAr
g), info.GetIsolate()); |
| 4792 } | 4792 } |
| 4793 | 4793 |
| 4794 static void stringMethodOptionalLongArgMethodCallback(const v8::FunctionCallback
Info<v8::Value>& info) | 4794 static void stringMethodOptionalLongArgMethodCallback(const v8::FunctionCallback
Info<v8::Value>& info) |
| 4795 { | 4795 { |
| 4796 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4796 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4797 TestObjectPythonV8Internal::stringMethodOptionalLongArgMethod(info); | 4797 TestObjectPythonV8Internal::stringMethodOptionalLongArgMethod(info); |
| 4798 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4798 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4799 } | 4799 } |
| 4800 | 4800 |
| 4801 static void testInterfaceEmptyMethodOptionalLongArgMethod(const v8::FunctionCall
backInfo<v8::Value>& info) | 4801 static void testInterfaceEmptyMethodOptionalLongArgMethod(const v8::FunctionCall
backInfo<v8::Value>& info) |
| 4802 { | 4802 { |
| 4803 ExceptionState exceptionState(ExceptionState::ExecutionContext, "testInterfa
ceEmptyMethodOptionalLongArg", "TestObjectPython", info.Holder(), info.GetIsolat
e()); | 4803 ExceptionState exceptionState(ExceptionState::ExecutionContext, "testInterfa
ceEmptyMethodOptionalLongArg", "TestObjectPython", info.Holder(), info.GetIsolat
e()); |
| 4804 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4804 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4805 if (UNLIKELY(info.Length() <= 0)) { | 4805 if (UNLIKELY(info.Length() <= 0)) { |
| 4806 v8SetReturnValue(info, imp->testInterfaceEmptyMethodOptionalLongArg()); | 4806 v8SetReturnValue(info, imp->testInterfaceEmptyMethodOptionalLongArg()); |
| 4807 return; | 4807 return; |
| 4808 } | 4808 } |
| 4809 V8TRYCATCH_EXCEPTION_VOID(int, optionalLongArg, toInt32(info[0], exceptionSt
ate), exceptionState); | 4809 V8TRYCATCH_EXCEPTION_VOID(int, optionalLongArg, toInt32(info[0], exceptionSt
ate), exceptionState); |
| 4810 v8SetReturnValue(info, imp->testInterfaceEmptyMethodOptionalLongArg(optional
LongArg)); | 4810 v8SetReturnValue(info, imp->testInterfaceEmptyMethodOptionalLongArg(optional
LongArg)); |
| 4811 } | 4811 } |
| 4812 | 4812 |
| 4813 static void testInterfaceEmptyMethodOptionalLongArgMethodCallback(const v8::Func
tionCallbackInfo<v8::Value>& info) | 4813 static void testInterfaceEmptyMethodOptionalLongArgMethodCallback(const v8::Func
tionCallbackInfo<v8::Value>& info) |
| 4814 { | 4814 { |
| 4815 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4815 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4816 TestObjectPythonV8Internal::testInterfaceEmptyMethodOptionalLongArgMethod(in
fo); | 4816 TestObjectPythonV8Internal::testInterfaceEmptyMethodOptionalLongArgMethod(in
fo); |
| 4817 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4817 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4818 } | 4818 } |
| 4819 | 4819 |
| 4820 static void longMethodOptionalLongArgMethod(const v8::FunctionCallbackInfo<v8::V
alue>& info) | 4820 static void longMethodOptionalLongArgMethod(const v8::FunctionCallbackInfo<v8::V
alue>& info) |
| 4821 { | 4821 { |
| 4822 ExceptionState exceptionState(ExceptionState::ExecutionContext, "longMethodO
ptionalLongArg", "TestObjectPython", info.Holder(), info.GetIsolate()); | 4822 ExceptionState exceptionState(ExceptionState::ExecutionContext, "longMethodO
ptionalLongArg", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 4823 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4823 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4824 if (UNLIKELY(info.Length() <= 0)) { | 4824 if (UNLIKELY(info.Length() <= 0)) { |
| 4825 v8SetReturnValueInt(info, imp->longMethodOptionalLongArg()); | 4825 v8SetReturnValueInt(info, imp->longMethodOptionalLongArg()); |
| 4826 return; | 4826 return; |
| 4827 } | 4827 } |
| 4828 V8TRYCATCH_EXCEPTION_VOID(int, optionalLongArg, toInt32(info[0], exceptionSt
ate), exceptionState); | 4828 V8TRYCATCH_EXCEPTION_VOID(int, optionalLongArg, toInt32(info[0], exceptionSt
ate), exceptionState); |
| 4829 v8SetReturnValueInt(info, imp->longMethodOptionalLongArg(optionalLongArg)); | 4829 v8SetReturnValueInt(info, imp->longMethodOptionalLongArg(optionalLongArg)); |
| 4830 } | 4830 } |
| 4831 | 4831 |
| 4832 static void longMethodOptionalLongArgMethodCallback(const v8::FunctionCallbackIn
fo<v8::Value>& info) | 4832 static void longMethodOptionalLongArgMethodCallback(const v8::FunctionCallbackIn
fo<v8::Value>& info) |
| 4833 { | 4833 { |
| 4834 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4834 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4835 TestObjectPythonV8Internal::longMethodOptionalLongArgMethod(info); | 4835 TestObjectPythonV8Internal::longMethodOptionalLongArgMethod(info); |
| 4836 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4836 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4837 } | 4837 } |
| 4838 | 4838 |
| 4839 static void voidMethodLongArgOptionalLongArgMethod(const v8::FunctionCallbackInf
o<v8::Value>& info) | 4839 static void voidMethodLongArgOptionalLongArgMethod(const v8::FunctionCallbackInf
o<v8::Value>& info) |
| 4840 { | 4840 { |
| 4841 ExceptionState exceptionState(ExceptionState::ExecutionContext, "voidMethodL
ongArgOptionalLongArg", "TestObjectPython", info.Holder(), info.GetIsolate()); | 4841 ExceptionState exceptionState(ExceptionState::ExecutionContext, "voidMethodL
ongArgOptionalLongArg", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 4842 if (UNLIKELY(info.Length() < 1)) { | 4842 if (UNLIKELY(info.Length() < 1)) { |
| 4843 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); | 4843 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); |
| 4844 exceptionState.throwIfNeeded(); | 4844 exceptionState.throwIfNeeded(); |
| 4845 return; | 4845 return; |
| 4846 } | 4846 } |
| 4847 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4847 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4848 V8TRYCATCH_EXCEPTION_VOID(int, longArg, toInt32(info[0], exceptionState), ex
ceptionState); | 4848 V8TRYCATCH_EXCEPTION_VOID(int, longArg, toInt32(info[0], exceptionState), ex
ceptionState); |
| 4849 if (UNLIKELY(info.Length() <= 1)) { | 4849 if (UNLIKELY(info.Length() <= 1)) { |
| 4850 imp->voidMethodLongArgOptionalLongArg(longArg); | 4850 imp->voidMethodLongArgOptionalLongArg(longArg); |
| 4851 return; | 4851 return; |
| 4852 } | 4852 } |
| 4853 V8TRYCATCH_EXCEPTION_VOID(int, optionalLongArg, toInt32(info[1], exceptionSt
ate), exceptionState); | 4853 V8TRYCATCH_EXCEPTION_VOID(int, optionalLongArg, toInt32(info[1], exceptionSt
ate), exceptionState); |
| 4854 imp->voidMethodLongArgOptionalLongArg(longArg, optionalLongArg); | 4854 imp->voidMethodLongArgOptionalLongArg(longArg, optionalLongArg); |
| 4855 } | 4855 } |
| 4856 | 4856 |
| 4857 static void voidMethodLongArgOptionalLongArgMethodCallback(const v8::FunctionCal
lbackInfo<v8::Value>& info) | 4857 static void voidMethodLongArgOptionalLongArgMethodCallback(const v8::FunctionCal
lbackInfo<v8::Value>& info) |
| 4858 { | 4858 { |
| 4859 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4859 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4860 TestObjectPythonV8Internal::voidMethodLongArgOptionalLongArgMethod(info); | 4860 TestObjectPythonV8Internal::voidMethodLongArgOptionalLongArgMethod(info); |
| 4861 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4861 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4862 } | 4862 } |
| 4863 | 4863 |
| 4864 static void voidMethodLongArgOptionalLongArgOptionalLongArgMethod(const v8::Func
tionCallbackInfo<v8::Value>& info) | 4864 static void voidMethodLongArgOptionalLongArgOptionalLongArgMethod(const v8::Func
tionCallbackInfo<v8::Value>& info) |
| 4865 { | 4865 { |
| 4866 ExceptionState exceptionState(ExceptionState::ExecutionContext, "voidMethodL
ongArgOptionalLongArgOptionalLongArg", "TestObjectPython", info.Holder(), info.G
etIsolate()); | 4866 ExceptionState exceptionState(ExceptionState::ExecutionContext, "voidMethodL
ongArgOptionalLongArgOptionalLongArg", "TestObjectPython", info.Holder(), info.G
etIsolate()); |
| 4867 if (UNLIKELY(info.Length() < 1)) { | 4867 if (UNLIKELY(info.Length() < 1)) { |
| 4868 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); | 4868 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); |
| 4869 exceptionState.throwIfNeeded(); | 4869 exceptionState.throwIfNeeded(); |
| 4870 return; | 4870 return; |
| 4871 } | 4871 } |
| 4872 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4872 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4873 V8TRYCATCH_EXCEPTION_VOID(int, longArg, toInt32(info[0], exceptionState), ex
ceptionState); | 4873 V8TRYCATCH_EXCEPTION_VOID(int, longArg, toInt32(info[0], exceptionState), ex
ceptionState); |
| 4874 if (UNLIKELY(info.Length() <= 1)) { | 4874 if (UNLIKELY(info.Length() <= 1)) { |
| 4875 imp->voidMethodLongArgOptionalLongArgOptionalLongArg(longArg); | 4875 imp->voidMethodLongArgOptionalLongArgOptionalLongArg(longArg); |
| 4876 return; | 4876 return; |
| 4877 } | 4877 } |
| 4878 V8TRYCATCH_EXCEPTION_VOID(int, optionalLongArg1, toInt32(info[1], exceptionS
tate), exceptionState); | 4878 V8TRYCATCH_EXCEPTION_VOID(int, optionalLongArg1, toInt32(info[1], exceptionS
tate), exceptionState); |
| 4879 if (UNLIKELY(info.Length() <= 2)) { | 4879 if (UNLIKELY(info.Length() <= 2)) { |
| 4880 imp->voidMethodLongArgOptionalLongArgOptionalLongArg(longArg, optionalLo
ngArg1); | 4880 imp->voidMethodLongArgOptionalLongArgOptionalLongArg(longArg, optionalLo
ngArg1); |
| 4881 return; | 4881 return; |
| 4882 } | 4882 } |
| 4883 V8TRYCATCH_EXCEPTION_VOID(int, optionalLongArg2, toInt32(info[2], exceptionS
tate), exceptionState); | 4883 V8TRYCATCH_EXCEPTION_VOID(int, optionalLongArg2, toInt32(info[2], exceptionS
tate), exceptionState); |
| 4884 imp->voidMethodLongArgOptionalLongArgOptionalLongArg(longArg, optionalLongAr
g1, optionalLongArg2); | 4884 imp->voidMethodLongArgOptionalLongArgOptionalLongArg(longArg, optionalLongAr
g1, optionalLongArg2); |
| 4885 } | 4885 } |
| 4886 | 4886 |
| 4887 static void voidMethodLongArgOptionalLongArgOptionalLongArgMethodCallback(const
v8::FunctionCallbackInfo<v8::Value>& info) | 4887 static void voidMethodLongArgOptionalLongArgOptionalLongArgMethodCallback(const
v8::FunctionCallbackInfo<v8::Value>& info) |
| 4888 { | 4888 { |
| 4889 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4889 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4890 TestObjectPythonV8Internal::voidMethodLongArgOptionalLongArgOptionalLongArgM
ethod(info); | 4890 TestObjectPythonV8Internal::voidMethodLongArgOptionalLongArgOptionalLongArgM
ethod(info); |
| 4891 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4891 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4892 } | 4892 } |
| 4893 | 4893 |
| 4894 static void voidMethodLongArgOptionalTestInterfaceEmptyArgMethod(const v8::Funct
ionCallbackInfo<v8::Value>& info) | 4894 static void voidMethodLongArgOptionalTestInterfaceEmptyArgMethod(const v8::Funct
ionCallbackInfo<v8::Value>& info) |
| 4895 { | 4895 { |
| 4896 ExceptionState exceptionState(ExceptionState::ExecutionContext, "voidMethodL
ongArgOptionalTestInterfaceEmptyArg", "TestObjectPython", info.Holder(), info.Ge
tIsolate()); | 4896 ExceptionState exceptionState(ExceptionState::ExecutionContext, "voidMethodL
ongArgOptionalTestInterfaceEmptyArg", "TestObjectPython", info.Holder(), info.Ge
tIsolate()); |
| 4897 if (UNLIKELY(info.Length() < 1)) { | 4897 if (UNLIKELY(info.Length() < 1)) { |
| 4898 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); | 4898 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); |
| 4899 exceptionState.throwIfNeeded(); | 4899 exceptionState.throwIfNeeded(); |
| 4900 return; | 4900 return; |
| 4901 } | 4901 } |
| 4902 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4902 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4903 V8TRYCATCH_EXCEPTION_VOID(int, longArg, toInt32(info[0], exceptionState), ex
ceptionState); | 4903 V8TRYCATCH_EXCEPTION_VOID(int, longArg, toInt32(info[0], exceptionState), ex
ceptionState); |
| 4904 if (UNLIKELY(info.Length() <= 1)) { | 4904 if (UNLIKELY(info.Length() <= 1)) { |
| 4905 imp->voidMethodLongArgOptionalTestInterfaceEmptyArg(longArg); | 4905 imp->voidMethodLongArgOptionalTestInterfaceEmptyArg(longArg); |
| 4906 return; | 4906 return; |
| 4907 } | 4907 } |
| 4908 V8TRYCATCH_VOID(TestInterfaceEmpty*, optionalTestInterfaceEmpty, V8TestInter
faceEmpty::hasInstance(info[1], info.GetIsolate(), worldType(info.GetIsolate()))
? V8TestInterfaceEmpty::toNative(v8::Handle<v8::Object>::Cast(info[1])) : 0); | 4908 V8TRYCATCH_VOID(TestInterfaceEmpty*, optionalTestInterfaceEmpty, V8TestInter
faceEmpty::hasInstance(info[1], info.GetIsolate(), worldType(info.GetIsolate()))
? V8TestInterfaceEmpty::toNative(v8::Handle<v8::Object>::Cast(info[1])) : 0); |
| 4909 imp->voidMethodLongArgOptionalTestInterfaceEmptyArg(longArg, optionalTestInt
erfaceEmpty); | 4909 imp->voidMethodLongArgOptionalTestInterfaceEmptyArg(longArg, optionalTestInt
erfaceEmpty); |
| 4910 } | 4910 } |
| 4911 | 4911 |
| 4912 static void voidMethodLongArgOptionalTestInterfaceEmptyArgMethodCallback(const v
8::FunctionCallbackInfo<v8::Value>& info) | 4912 static void voidMethodLongArgOptionalTestInterfaceEmptyArgMethodCallback(const v
8::FunctionCallbackInfo<v8::Value>& info) |
| 4913 { | 4913 { |
| 4914 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4914 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4915 TestObjectPythonV8Internal::voidMethodLongArgOptionalTestInterfaceEmptyArgMe
thod(info); | 4915 TestObjectPythonV8Internal::voidMethodLongArgOptionalTestInterfaceEmptyArgMe
thod(info); |
| 4916 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4916 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4917 } | 4917 } |
| 4918 | 4918 |
| 4919 static void voidMethodTestInterfaceEmptyArgOptionalLongArgMethod(const v8::Funct
ionCallbackInfo<v8::Value>& info) | 4919 static void voidMethodTestInterfaceEmptyArgOptionalLongArgMethod(const v8::Funct
ionCallbackInfo<v8::Value>& info) |
| 4920 { | 4920 { |
| 4921 ExceptionState exceptionState(ExceptionState::ExecutionContext, "voidMethodT
estInterfaceEmptyArgOptionalLongArg", "TestObjectPython", info.Holder(), info.Ge
tIsolate()); | 4921 ExceptionState exceptionState(ExceptionState::ExecutionContext, "voidMethodT
estInterfaceEmptyArgOptionalLongArg", "TestObjectPython", info.Holder(), info.Ge
tIsolate()); |
| 4922 if (UNLIKELY(info.Length() < 1)) { | 4922 if (UNLIKELY(info.Length() < 1)) { |
| 4923 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); | 4923 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); |
| 4924 exceptionState.throwIfNeeded(); | 4924 exceptionState.throwIfNeeded(); |
| 4925 return; | 4925 return; |
| 4926 } | 4926 } |
| 4927 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4927 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4928 V8TRYCATCH_VOID(TestInterfaceEmpty*, optionalTestInterfaceEmpty, V8TestInter
faceEmpty::hasInstance(info[0], info.GetIsolate(), worldType(info.GetIsolate()))
? V8TestInterfaceEmpty::toNative(v8::Handle<v8::Object>::Cast(info[0])) : 0); | 4928 V8TRYCATCH_VOID(TestInterfaceEmpty*, optionalTestInterfaceEmpty, V8TestInter
faceEmpty::hasInstance(info[0], info.GetIsolate(), worldType(info.GetIsolate()))
? V8TestInterfaceEmpty::toNative(v8::Handle<v8::Object>::Cast(info[0])) : 0); |
| 4929 if (UNLIKELY(info.Length() <= 1)) { | 4929 if (UNLIKELY(info.Length() <= 1)) { |
| 4930 imp->voidMethodTestInterfaceEmptyArgOptionalLongArg(optionalTestInterfac
eEmpty); | 4930 imp->voidMethodTestInterfaceEmptyArgOptionalLongArg(optionalTestInterfac
eEmpty); |
| 4931 return; | 4931 return; |
| 4932 } | 4932 } |
| 4933 V8TRYCATCH_EXCEPTION_VOID(int, longArg, toInt32(info[1], exceptionState), ex
ceptionState); | 4933 V8TRYCATCH_EXCEPTION_VOID(int, longArg, toInt32(info[1], exceptionState), ex
ceptionState); |
| 4934 imp->voidMethodTestInterfaceEmptyArgOptionalLongArg(optionalTestInterfaceEmp
ty, longArg); | 4934 imp->voidMethodTestInterfaceEmptyArgOptionalLongArg(optionalTestInterfaceEmp
ty, longArg); |
| 4935 } | 4935 } |
| 4936 | 4936 |
| 4937 static void voidMethodTestInterfaceEmptyArgOptionalLongArgMethodCallback(const v
8::FunctionCallbackInfo<v8::Value>& info) | 4937 static void voidMethodTestInterfaceEmptyArgOptionalLongArgMethodCallback(const v
8::FunctionCallbackInfo<v8::Value>& info) |
| 4938 { | 4938 { |
| 4939 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4939 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4940 TestObjectPythonV8Internal::voidMethodTestInterfaceEmptyArgOptionalLongArgMe
thod(info); | 4940 TestObjectPythonV8Internal::voidMethodTestInterfaceEmptyArgOptionalLongArgMe
thod(info); |
| 4941 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4941 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4942 } | 4942 } |
| 4943 | 4943 |
| 4944 static void voidMethodOptionalDictionaryArgMethod(const v8::FunctionCallbackInfo
<v8::Value>& info) | 4944 static void voidMethodOptionalDictionaryArgMethod(const v8::FunctionCallbackInfo
<v8::Value>& info) |
| 4945 { | 4945 { |
| 4946 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4946 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4947 V8TRYCATCH_VOID(Dictionary, optionalDictionaryArg, Dictionary(info[0], info.
GetIsolate())); | 4947 V8TRYCATCH_VOID(Dictionary, optionalDictionaryArg, Dictionary(info[0], info.
GetIsolate())); |
| 4948 if (!optionalDictionaryArg.isUndefinedOrNull() && !optionalDictionaryArg.isO
bject()) { | 4948 if (!optionalDictionaryArg.isUndefinedOrNull() && !optionalDictionaryArg.isO
bject()) { |
| 4949 throwTypeError(ExceptionMessages::failedToExecute("voidMethodOptionalDic
tionaryArg", "TestObjectPython", "parameter 1 ('optionalDictionaryArg') is not a
n object."), info.GetIsolate()); | 4949 throwTypeError(ExceptionMessages::failedToExecute("voidMethodOptionalDic
tionaryArg", "TestObjectPython", "parameter 1 ('optionalDictionaryArg') is not a
n object."), info.GetIsolate()); |
| 4950 return; | 4950 return; |
| 4951 } | 4951 } |
| 4952 imp->voidMethodOptionalDictionaryArg(optionalDictionaryArg); | 4952 imp->voidMethodOptionalDictionaryArg(optionalDictionaryArg); |
| 4953 } | 4953 } |
| 4954 | 4954 |
| 4955 static void voidMethodOptionalDictionaryArgMethodCallback(const v8::FunctionCall
backInfo<v8::Value>& info) | 4955 static void voidMethodOptionalDictionaryArgMethodCallback(const v8::FunctionCall
backInfo<v8::Value>& info) |
| 4956 { | 4956 { |
| 4957 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4957 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4958 TestObjectPythonV8Internal::voidMethodOptionalDictionaryArgMethod(info); | 4958 TestObjectPythonV8Internal::voidMethodOptionalDictionaryArgMethod(info); |
| 4959 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4959 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4960 } | 4960 } |
| 4961 | 4961 |
| 4962 static void voidMethodVariadicStringArgMethod(const v8::FunctionCallbackInfo<v8:
:Value>& info) | 4962 static void voidMethodVariadicStringArgMethod(const v8::FunctionCallbackInfo<v8:
:Value>& info) |
| 4963 { | 4963 { |
| 4964 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4964 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4965 V8TRYCATCH_VOID(Vector<String>, variadicStringArgs, toNativeArguments<String
>(info, 0)); | 4965 V8TRYCATCH_VOID(Vector<String>, variadicStringArgs, toNativeArguments<String
>(info, 0)); |
| 4966 imp->voidMethodVariadicStringArg(variadicStringArgs); | 4966 imp->voidMethodVariadicStringArg(variadicStringArgs); |
| 4967 } | 4967 } |
| 4968 | 4968 |
| 4969 static void voidMethodVariadicStringArgMethodCallback(const v8::FunctionCallback
Info<v8::Value>& info) | 4969 static void voidMethodVariadicStringArgMethodCallback(const v8::FunctionCallback
Info<v8::Value>& info) |
| 4970 { | 4970 { |
| 4971 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4971 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4972 TestObjectPythonV8Internal::voidMethodVariadicStringArgMethod(info); | 4972 TestObjectPythonV8Internal::voidMethodVariadicStringArgMethod(info); |
| 4973 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4973 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4974 } | 4974 } |
| 4975 | 4975 |
| 4976 static void voidMethodStringArgVariadicStringArgMethod(const v8::FunctionCallbac
kInfo<v8::Value>& info) | 4976 static void voidMethodStringArgVariadicStringArgMethod(const v8::FunctionCallbac
kInfo<v8::Value>& info) |
| 4977 { | 4977 { |
| 4978 if (UNLIKELY(info.Length() < 1)) { | 4978 if (UNLIKELY(info.Length() < 1)) { |
| 4979 throwTypeError(ExceptionMessages::failedToExecute("voidMethodStringArgVa
riadicStringArg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, i
nfo.Length())), info.GetIsolate()); | 4979 throwTypeError(ExceptionMessages::failedToExecute("voidMethodStringArgVa
riadicStringArg", "TestObjectPython", ExceptionMessages::notEnoughArguments(1, i
nfo.Length())), info.GetIsolate()); |
| 4980 return; | 4980 return; |
| 4981 } | 4981 } |
| 4982 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4982 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4983 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, stringArg, info[0])
; | 4983 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, stringArg, info[0])
; |
| 4984 V8TRYCATCH_VOID(Vector<String>, variadicStringArgs, toNativeArguments<String
>(info, 1)); | 4984 V8TRYCATCH_VOID(Vector<String>, variadicStringArgs, toNativeArguments<String
>(info, 1)); |
| 4985 imp->voidMethodStringArgVariadicStringArg(stringArg, variadicStringArgs); | 4985 imp->voidMethodStringArgVariadicStringArg(stringArg, variadicStringArgs); |
| 4986 } | 4986 } |
| 4987 | 4987 |
| 4988 static void voidMethodStringArgVariadicStringArgMethodCallback(const v8::Functio
nCallbackInfo<v8::Value>& info) | 4988 static void voidMethodStringArgVariadicStringArgMethodCallback(const v8::Functio
nCallbackInfo<v8::Value>& info) |
| 4989 { | 4989 { |
| 4990 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 4990 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 4991 TestObjectPythonV8Internal::voidMethodStringArgVariadicStringArgMethod(info)
; | 4991 TestObjectPythonV8Internal::voidMethodStringArgVariadicStringArgMethod(info)
; |
| 4992 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 4992 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4993 } | 4993 } |
| 4994 | 4994 |
| 4995 static void voidMethodVariadicTestInterfaceEmptyArgMethod(const v8::FunctionCall
backInfo<v8::Value>& info) | 4995 static void voidMethodVariadicTestInterfaceEmptyArgMethod(const v8::FunctionCall
backInfo<v8::Value>& info) |
| 4996 { | 4996 { |
| 4997 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 4997 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 4998 Vector<RefPtr<TestInterfaceEmpty> > variadicTestInterfaceEmptyArgs; | 4998 Vector<RefPtr<TestInterfaceEmpty> > variadicTestInterfaceEmptyArgs; |
| 4999 for (int i = 0; i < info.Length(); ++i) { | 4999 for (int i = 0; i < info.Length(); ++i) { |
| 5000 if (!V8TestInterfaceEmpty::hasInstance(info[i], info.GetIsolate(), world
Type(info.GetIsolate()))) { | 5000 if (!V8TestInterfaceEmpty::hasInstance(info[i], info.GetIsolate(), world
Type(info.GetIsolate()))) { |
| 5001 throwTypeError(ExceptionMessages::failedToExecute("voidMethodVariadi
cTestInterfaceEmptyArg", "TestObjectPython", "parameter 1 is not of type 'TestIn
terfaceEmpty'."), info.GetIsolate()); | 5001 throwTypeError(ExceptionMessages::failedToExecute("voidMethodVariadi
cTestInterfaceEmptyArg", "TestObjectPython", "parameter 1 is not of type 'TestIn
terfaceEmpty'."), info.GetIsolate()); |
| 5002 return; | 5002 return; |
| 5003 } | 5003 } |
| 5004 variadicTestInterfaceEmptyArgs.append(V8TestInterfaceEmpty::toNative(v8:
:Handle<v8::Object>::Cast(info[i]))); | 5004 variadicTestInterfaceEmptyArgs.append(V8TestInterfaceEmpty::toNative(v8:
:Handle<v8::Object>::Cast(info[i]))); |
| 5005 } | 5005 } |
| 5006 imp->voidMethodVariadicTestInterfaceEmptyArg(variadicTestInterfaceEmptyArgs)
; | 5006 imp->voidMethodVariadicTestInterfaceEmptyArg(variadicTestInterfaceEmptyArgs)
; |
| 5007 } | 5007 } |
| 5008 | 5008 |
| 5009 static void voidMethodVariadicTestInterfaceEmptyArgMethodCallback(const v8::Func
tionCallbackInfo<v8::Value>& info) | 5009 static void voidMethodVariadicTestInterfaceEmptyArgMethodCallback(const v8::Func
tionCallbackInfo<v8::Value>& info) |
| 5010 { | 5010 { |
| 5011 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 5011 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 5012 TestObjectPythonV8Internal::voidMethodVariadicTestInterfaceEmptyArgMethod(in
fo); | 5012 TestObjectPythonV8Internal::voidMethodVariadicTestInterfaceEmptyArgMethod(in
fo); |
| 5013 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 5013 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 5014 } | 5014 } |
| 5015 | 5015 |
| 5016 static void voidMethodTestInterfaceEmptyArgVariadicTestInterfaceEmptyArgMethod(c
onst v8::FunctionCallbackInfo<v8::Value>& info) | 5016 static void voidMethodTestInterfaceEmptyArgVariadicTestInterfaceEmptyArgMethod(c
onst v8::FunctionCallbackInfo<v8::Value>& info) |
| 5017 { | 5017 { |
| 5018 if (UNLIKELY(info.Length() < 1)) { | 5018 if (UNLIKELY(info.Length() < 1)) { |
| 5019 throwTypeError(ExceptionMessages::failedToExecute("voidMethodTestInterfa
ceEmptyArgVariadicTestInterfaceEmptyArg", "TestObjectPython", ExceptionMessages:
:notEnoughArguments(1, info.Length())), info.GetIsolate()); | 5019 throwTypeError(ExceptionMessages::failedToExecute("voidMethodTestInterfa
ceEmptyArgVariadicTestInterfaceEmptyArg", "TestObjectPython", ExceptionMessages:
:notEnoughArguments(1, info.Length())), info.GetIsolate()); |
| 5020 return; | 5020 return; |
| 5021 } | 5021 } |
| 5022 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 5022 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 5023 V8TRYCATCH_VOID(TestInterfaceEmpty*, testInterfaceEmptyArg, V8TestInterfaceE
mpty::hasInstance(info[0], info.GetIsolate(), worldType(info.GetIsolate())) ? V8
TestInterfaceEmpty::toNative(v8::Handle<v8::Object>::Cast(info[0])) : 0); | 5023 V8TRYCATCH_VOID(TestInterfaceEmpty*, testInterfaceEmptyArg, V8TestInterfaceE
mpty::hasInstance(info[0], info.GetIsolate(), worldType(info.GetIsolate())) ? V8
TestInterfaceEmpty::toNative(v8::Handle<v8::Object>::Cast(info[0])) : 0); |
| 5024 Vector<RefPtr<TestInterfaceEmpty> > variadicTestInterfaceEmptyArgs; | 5024 Vector<RefPtr<TestInterfaceEmpty> > variadicTestInterfaceEmptyArgs; |
| 5025 for (int i = 1; i < info.Length(); ++i) { | 5025 for (int i = 1; i < info.Length(); ++i) { |
| 5026 if (!V8TestInterfaceEmpty::hasInstance(info[i], info.GetIsolate(), world
Type(info.GetIsolate()))) { | 5026 if (!V8TestInterfaceEmpty::hasInstance(info[i], info.GetIsolate(), world
Type(info.GetIsolate()))) { |
| 5027 throwTypeError(ExceptionMessages::failedToExecute("voidMethodTestInt
erfaceEmptyArgVariadicTestInterfaceEmptyArg", "TestObjectPython", "parameter 2 i
s not of type 'TestInterfaceEmpty'."), info.GetIsolate()); | 5027 throwTypeError(ExceptionMessages::failedToExecute("voidMethodTestInt
erfaceEmptyArgVariadicTestInterfaceEmptyArg", "TestObjectPython", "parameter 2 i
s not of type 'TestInterfaceEmpty'."), info.GetIsolate()); |
| 5028 return; | 5028 return; |
| 5029 } | 5029 } |
| 5030 variadicTestInterfaceEmptyArgs.append(V8TestInterfaceEmpty::toNative(v8:
:Handle<v8::Object>::Cast(info[i]))); | 5030 variadicTestInterfaceEmptyArgs.append(V8TestInterfaceEmpty::toNative(v8:
:Handle<v8::Object>::Cast(info[i]))); |
| 5031 } | 5031 } |
| 5032 imp->voidMethodTestInterfaceEmptyArgVariadicTestInterfaceEmptyArg(testInterf
aceEmptyArg, variadicTestInterfaceEmptyArgs); | 5032 imp->voidMethodTestInterfaceEmptyArgVariadicTestInterfaceEmptyArg(testInterf
aceEmptyArg, variadicTestInterfaceEmptyArgs); |
| 5033 } | 5033 } |
| 5034 | 5034 |
| 5035 static void voidMethodTestInterfaceEmptyArgVariadicTestInterfaceEmptyArgMethodCa
llback(const v8::FunctionCallbackInfo<v8::Value>& info) | 5035 static void voidMethodTestInterfaceEmptyArgVariadicTestInterfaceEmptyArgMethodCa
llback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| 5036 { | 5036 { |
| 5037 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 5037 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 5038 TestObjectPythonV8Internal::voidMethodTestInterfaceEmptyArgVariadicTestInter
faceEmptyArgMethod(info); | 5038 TestObjectPythonV8Internal::voidMethodTestInterfaceEmptyArgVariadicTestInter
faceEmptyArgMethod(info); |
| 5039 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 5039 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 5040 } | 5040 } |
| 5041 | 5041 |
| 5042 static void overloadedMethodA1Method(const v8::FunctionCallbackInfo<v8::Value>&
info) | 5042 static void overloadedMethodA1Method(const v8::FunctionCallbackInfo<v8::Value>&
info) |
| 5043 { | 5043 { |
| 5044 ExceptionState exceptionState(ExceptionState::ExecutionContext, "overloadedM
ethodA", "TestObjectPython", info.Holder(), info.GetIsolate()); | 5044 ExceptionState exceptionState(ExceptionState::ExecutionContext, "overloadedM
ethodA", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 5045 if (UNLIKELY(info.Length() < 1)) { | 5045 if (UNLIKELY(info.Length() < 1)) { |
| 5046 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); | 5046 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); |
| 5047 exceptionState.throwIfNeeded(); | 5047 exceptionState.throwIfNeeded(); |
| 5048 return; | 5048 return; |
| 5049 } | 5049 } |
| (...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5083 return; | 5083 return; |
| 5084 } | 5084 } |
| 5085 exceptionState.throwTypeError("No function was found that matched the signat
ure provided."); | 5085 exceptionState.throwTypeError("No function was found that matched the signat
ure provided."); |
| 5086 exceptionState.throwIfNeeded(); | 5086 exceptionState.throwIfNeeded(); |
| 5087 } | 5087 } |
| 5088 | 5088 |
| 5089 static void overloadedMethodAMethodCallback(const v8::FunctionCallbackInfo<v8::V
alue>& info) | 5089 static void overloadedMethodAMethodCallback(const v8::FunctionCallbackInfo<v8::V
alue>& info) |
| 5090 { | 5090 { |
| 5091 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 5091 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 5092 TestObjectPythonV8Internal::overloadedMethodAMethod(info); | 5092 TestObjectPythonV8Internal::overloadedMethodAMethod(info); |
| 5093 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 5093 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 5094 } | 5094 } |
| 5095 | 5095 |
| 5096 static void overloadedMethodB1Method(const v8::FunctionCallbackInfo<v8::Value>&
info) | 5096 static void overloadedMethodB1Method(const v8::FunctionCallbackInfo<v8::Value>&
info) |
| 5097 { | 5097 { |
| 5098 ExceptionState exceptionState(ExceptionState::ExecutionContext, "overloadedM
ethodB", "TestObjectPython", info.Holder(), info.GetIsolate()); | 5098 ExceptionState exceptionState(ExceptionState::ExecutionContext, "overloadedM
ethodB", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 5099 if (UNLIKELY(info.Length() < 1)) { | 5099 if (UNLIKELY(info.Length() < 1)) { |
| 5100 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); | 5100 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); |
| 5101 exceptionState.throwIfNeeded(); | 5101 exceptionState.throwIfNeeded(); |
| 5102 return; | 5102 return; |
| 5103 } | 5103 } |
| (...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5141 return; | 5141 return; |
| 5142 } | 5142 } |
| 5143 exceptionState.throwTypeError("No function was found that matched the signat
ure provided."); | 5143 exceptionState.throwTypeError("No function was found that matched the signat
ure provided."); |
| 5144 exceptionState.throwIfNeeded(); | 5144 exceptionState.throwIfNeeded(); |
| 5145 } | 5145 } |
| 5146 | 5146 |
| 5147 static void overloadedMethodBMethodCallback(const v8::FunctionCallbackInfo<v8::V
alue>& info) | 5147 static void overloadedMethodBMethodCallback(const v8::FunctionCallbackInfo<v8::V
alue>& info) |
| 5148 { | 5148 { |
| 5149 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 5149 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 5150 TestObjectPythonV8Internal::overloadedMethodBMethod(info); | 5150 TestObjectPythonV8Internal::overloadedMethodBMethod(info); |
| 5151 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 5151 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 5152 } | 5152 } |
| 5153 | 5153 |
| 5154 static void overloadedMethodC1Method(const v8::FunctionCallbackInfo<v8::Value>&
info) | 5154 static void overloadedMethodC1Method(const v8::FunctionCallbackInfo<v8::Value>&
info) |
| 5155 { | 5155 { |
| 5156 ExceptionState exceptionState(ExceptionState::ExecutionContext, "overloadedM
ethodC", "TestObjectPython", info.Holder(), info.GetIsolate()); | 5156 ExceptionState exceptionState(ExceptionState::ExecutionContext, "overloadedM
ethodC", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 5157 if (UNLIKELY(info.Length() < 1)) { | 5157 if (UNLIKELY(info.Length() < 1)) { |
| 5158 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); | 5158 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); |
| 5159 exceptionState.throwIfNeeded(); | 5159 exceptionState.throwIfNeeded(); |
| 5160 return; | 5160 return; |
| 5161 } | 5161 } |
| (...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5195 return; | 5195 return; |
| 5196 } | 5196 } |
| 5197 exceptionState.throwTypeError("No function was found that matched the signat
ure provided."); | 5197 exceptionState.throwTypeError("No function was found that matched the signat
ure provided."); |
| 5198 exceptionState.throwIfNeeded(); | 5198 exceptionState.throwIfNeeded(); |
| 5199 } | 5199 } |
| 5200 | 5200 |
| 5201 static void overloadedMethodCMethodCallback(const v8::FunctionCallbackInfo<v8::V
alue>& info) | 5201 static void overloadedMethodCMethodCallback(const v8::FunctionCallbackInfo<v8::V
alue>& info) |
| 5202 { | 5202 { |
| 5203 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 5203 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 5204 TestObjectPythonV8Internal::overloadedMethodCMethod(info); | 5204 TestObjectPythonV8Internal::overloadedMethodCMethod(info); |
| 5205 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 5205 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 5206 } | 5206 } |
| 5207 | 5207 |
| 5208 static void overloadedMethodD1Method(const v8::FunctionCallbackInfo<v8::Value>&
info) | 5208 static void overloadedMethodD1Method(const v8::FunctionCallbackInfo<v8::Value>&
info) |
| 5209 { | 5209 { |
| 5210 ExceptionState exceptionState(ExceptionState::ExecutionContext, "overloadedM
ethodD", "TestObjectPython", info.Holder(), info.GetIsolate()); | 5210 ExceptionState exceptionState(ExceptionState::ExecutionContext, "overloadedM
ethodD", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 5211 if (UNLIKELY(info.Length() < 1)) { | 5211 if (UNLIKELY(info.Length() < 1)) { |
| 5212 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); | 5212 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); |
| 5213 exceptionState.throwIfNeeded(); | 5213 exceptionState.throwIfNeeded(); |
| 5214 return; | 5214 return; |
| 5215 } | 5215 } |
| (...skipping 30 matching lines...) Expand all Loading... |
| 5246 return; | 5246 return; |
| 5247 } | 5247 } |
| 5248 exceptionState.throwTypeError("No function was found that matched the signat
ure provided."); | 5248 exceptionState.throwTypeError("No function was found that matched the signat
ure provided."); |
| 5249 exceptionState.throwIfNeeded(); | 5249 exceptionState.throwIfNeeded(); |
| 5250 } | 5250 } |
| 5251 | 5251 |
| 5252 static void overloadedMethodDMethodCallback(const v8::FunctionCallbackInfo<v8::V
alue>& info) | 5252 static void overloadedMethodDMethodCallback(const v8::FunctionCallbackInfo<v8::V
alue>& info) |
| 5253 { | 5253 { |
| 5254 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 5254 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 5255 TestObjectPythonV8Internal::overloadedMethodDMethod(info); | 5255 TestObjectPythonV8Internal::overloadedMethodDMethod(info); |
| 5256 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 5256 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 5257 } | 5257 } |
| 5258 | 5258 |
| 5259 static void overloadedMethodE1Method(const v8::FunctionCallbackInfo<v8::Value>&
info) | 5259 static void overloadedMethodE1Method(const v8::FunctionCallbackInfo<v8::Value>&
info) |
| 5260 { | 5260 { |
| 5261 ExceptionState exceptionState(ExceptionState::ExecutionContext, "overloadedM
ethodE", "TestObjectPython", info.Holder(), info.GetIsolate()); | 5261 ExceptionState exceptionState(ExceptionState::ExecutionContext, "overloadedM
ethodE", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 5262 if (UNLIKELY(info.Length() < 1)) { | 5262 if (UNLIKELY(info.Length() < 1)) { |
| 5263 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); | 5263 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); |
| 5264 exceptionState.throwIfNeeded(); | 5264 exceptionState.throwIfNeeded(); |
| 5265 return; | 5265 return; |
| 5266 } | 5266 } |
| (...skipping 30 matching lines...) Expand all Loading... |
| 5297 return; | 5297 return; |
| 5298 } | 5298 } |
| 5299 exceptionState.throwTypeError("No function was found that matched the signat
ure provided."); | 5299 exceptionState.throwTypeError("No function was found that matched the signat
ure provided."); |
| 5300 exceptionState.throwIfNeeded(); | 5300 exceptionState.throwIfNeeded(); |
| 5301 } | 5301 } |
| 5302 | 5302 |
| 5303 static void overloadedMethodEMethodCallback(const v8::FunctionCallbackInfo<v8::V
alue>& info) | 5303 static void overloadedMethodEMethodCallback(const v8::FunctionCallbackInfo<v8::V
alue>& info) |
| 5304 { | 5304 { |
| 5305 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 5305 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 5306 TestObjectPythonV8Internal::overloadedMethodEMethod(info); | 5306 TestObjectPythonV8Internal::overloadedMethodEMethod(info); |
| 5307 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 5307 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 5308 } | 5308 } |
| 5309 | 5309 |
| 5310 static void overloadedMethodF1Method(const v8::FunctionCallbackInfo<v8::Value>&
info) | 5310 static void overloadedMethodF1Method(const v8::FunctionCallbackInfo<v8::Value>&
info) |
| 5311 { | 5311 { |
| 5312 ExceptionState exceptionState(ExceptionState::ExecutionContext, "overloadedM
ethodF", "TestObjectPython", info.Holder(), info.GetIsolate()); | 5312 ExceptionState exceptionState(ExceptionState::ExecutionContext, "overloadedM
ethodF", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 5313 if (UNLIKELY(info.Length() < 1)) { | 5313 if (UNLIKELY(info.Length() < 1)) { |
| 5314 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); | 5314 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); |
| 5315 exceptionState.throwIfNeeded(); | 5315 exceptionState.throwIfNeeded(); |
| 5316 return; | 5316 return; |
| 5317 } | 5317 } |
| (...skipping 30 matching lines...) Expand all Loading... |
| 5348 return; | 5348 return; |
| 5349 } | 5349 } |
| 5350 exceptionState.throwTypeError("No function was found that matched the signat
ure provided."); | 5350 exceptionState.throwTypeError("No function was found that matched the signat
ure provided."); |
| 5351 exceptionState.throwIfNeeded(); | 5351 exceptionState.throwIfNeeded(); |
| 5352 } | 5352 } |
| 5353 | 5353 |
| 5354 static void overloadedMethodFMethodCallback(const v8::FunctionCallbackInfo<v8::V
alue>& info) | 5354 static void overloadedMethodFMethodCallback(const v8::FunctionCallbackInfo<v8::V
alue>& info) |
| 5355 { | 5355 { |
| 5356 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 5356 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 5357 TestObjectPythonV8Internal::overloadedMethodFMethod(info); | 5357 TestObjectPythonV8Internal::overloadedMethodFMethod(info); |
| 5358 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 5358 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 5359 } | 5359 } |
| 5360 | 5360 |
| 5361 static void overloadedMethodG1Method(const v8::FunctionCallbackInfo<v8::Value>&
info) | 5361 static void overloadedMethodG1Method(const v8::FunctionCallbackInfo<v8::Value>&
info) |
| 5362 { | 5362 { |
| 5363 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 5363 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 5364 imp->overloadedMethodG(); | 5364 imp->overloadedMethodG(); |
| 5365 } | 5365 } |
| 5366 | 5366 |
| 5367 static void overloadedMethodG2Method(const v8::FunctionCallbackInfo<v8::Value>&
info) | 5367 static void overloadedMethodG2Method(const v8::FunctionCallbackInfo<v8::Value>&
info) |
| 5368 { | 5368 { |
| (...skipping 16 matching lines...) Expand all Loading... |
| 5385 overloadedMethodG2Method(info); | 5385 overloadedMethodG2Method(info); |
| 5386 return; | 5386 return; |
| 5387 } | 5387 } |
| 5388 throwTypeError(ExceptionMessages::failedToExecute("overloadedMethodG", "Test
ObjectPython", "No function was found that matched the signature provided."), in
fo.GetIsolate()); | 5388 throwTypeError(ExceptionMessages::failedToExecute("overloadedMethodG", "Test
ObjectPython", "No function was found that matched the signature provided."), in
fo.GetIsolate()); |
| 5389 } | 5389 } |
| 5390 | 5390 |
| 5391 static void overloadedMethodGMethodCallback(const v8::FunctionCallbackInfo<v8::V
alue>& info) | 5391 static void overloadedMethodGMethodCallback(const v8::FunctionCallbackInfo<v8::V
alue>& info) |
| 5392 { | 5392 { |
| 5393 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 5393 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 5394 TestObjectPythonV8Internal::overloadedMethodGMethod(info); | 5394 TestObjectPythonV8Internal::overloadedMethodGMethod(info); |
| 5395 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 5395 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 5396 } | 5396 } |
| 5397 | 5397 |
| 5398 static void overloadedMethodH1Method(const v8::FunctionCallbackInfo<v8::Value>&
info) | 5398 static void overloadedMethodH1Method(const v8::FunctionCallbackInfo<v8::Value>&
info) |
| 5399 { | 5399 { |
| 5400 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 5400 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 5401 imp->overloadedMethodH(); | 5401 imp->overloadedMethodH(); |
| 5402 } | 5402 } |
| 5403 | 5403 |
| 5404 static void overloadedMethodH2Method(const v8::FunctionCallbackInfo<v8::Value>&
info) | 5404 static void overloadedMethodH2Method(const v8::FunctionCallbackInfo<v8::Value>&
info) |
| 5405 { | 5405 { |
| (...skipping 20 matching lines...) Expand all Loading... |
| 5426 overloadedMethodH2Method(info); | 5426 overloadedMethodH2Method(info); |
| 5427 return; | 5427 return; |
| 5428 } | 5428 } |
| 5429 throwTypeError(ExceptionMessages::failedToExecute("overloadedMethodH", "Test
ObjectPython", "No function was found that matched the signature provided."), in
fo.GetIsolate()); | 5429 throwTypeError(ExceptionMessages::failedToExecute("overloadedMethodH", "Test
ObjectPython", "No function was found that matched the signature provided."), in
fo.GetIsolate()); |
| 5430 } | 5430 } |
| 5431 | 5431 |
| 5432 static void overloadedMethodHMethodCallback(const v8::FunctionCallbackInfo<v8::V
alue>& info) | 5432 static void overloadedMethodHMethodCallback(const v8::FunctionCallbackInfo<v8::V
alue>& info) |
| 5433 { | 5433 { |
| 5434 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 5434 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 5435 TestObjectPythonV8Internal::overloadedMethodHMethod(info); | 5435 TestObjectPythonV8Internal::overloadedMethodHMethod(info); |
| 5436 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 5436 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 5437 } | 5437 } |
| 5438 | 5438 |
| 5439 static void overloadedPerWorldBindingsMethod1Method(const v8::FunctionCallbackIn
fo<v8::Value>& info) | 5439 static void overloadedPerWorldBindingsMethod1Method(const v8::FunctionCallbackIn
fo<v8::Value>& info) |
| 5440 { | 5440 { |
| 5441 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 5441 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 5442 imp->overloadedPerWorldBindingsMethod(); | 5442 imp->overloadedPerWorldBindingsMethod(); |
| 5443 } | 5443 } |
| 5444 | 5444 |
| 5445 static void overloadedPerWorldBindingsMethod1MethodForMainWorld(const v8::Functi
onCallbackInfo<v8::Value>& info) | 5445 static void overloadedPerWorldBindingsMethod1MethodForMainWorld(const v8::Functi
onCallbackInfo<v8::Value>& info) |
| 5446 { | 5446 { |
| (...skipping 24 matching lines...) Expand all Loading... |
| 5471 overloadedPerWorldBindingsMethod2Method(info); | 5471 overloadedPerWorldBindingsMethod2Method(info); |
| 5472 return; | 5472 return; |
| 5473 } | 5473 } |
| 5474 throwTypeError(ExceptionMessages::failedToExecute("overloadedPerWorldBinding
sMethod", "TestObjectPython", "No function was found that matched the signature
provided."), info.GetIsolate()); | 5474 throwTypeError(ExceptionMessages::failedToExecute("overloadedPerWorldBinding
sMethod", "TestObjectPython", "No function was found that matched the signature
provided."), info.GetIsolate()); |
| 5475 } | 5475 } |
| 5476 | 5476 |
| 5477 static void overloadedPerWorldBindingsMethodMethodCallback(const v8::FunctionCal
lbackInfo<v8::Value>& info) | 5477 static void overloadedPerWorldBindingsMethodMethodCallback(const v8::FunctionCal
lbackInfo<v8::Value>& info) |
| 5478 { | 5478 { |
| 5479 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 5479 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 5480 TestObjectPythonV8Internal::overloadedPerWorldBindingsMethodMethod(info); | 5480 TestObjectPythonV8Internal::overloadedPerWorldBindingsMethodMethod(info); |
| 5481 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 5481 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 5482 } | 5482 } |
| 5483 | 5483 |
| 5484 static void overloadedPerWorldBindingsMethod2MethodForMainWorld(const v8::Functi
onCallbackInfo<v8::Value>& info) | 5484 static void overloadedPerWorldBindingsMethod2MethodForMainWorld(const v8::Functi
onCallbackInfo<v8::Value>& info) |
| 5485 { | 5485 { |
| 5486 ExceptionState exceptionState(ExceptionState::ExecutionContext, "overloadedP
erWorldBindingsMethod", "TestObjectPython", info.Holder(), info.GetIsolate()); | 5486 ExceptionState exceptionState(ExceptionState::ExecutionContext, "overloadedP
erWorldBindingsMethod", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 5487 if (UNLIKELY(info.Length() < 1)) { | 5487 if (UNLIKELY(info.Length() < 1)) { |
| 5488 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); | 5488 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); |
| 5489 exceptionState.throwIfNeeded(); | 5489 exceptionState.throwIfNeeded(); |
| 5490 return; | 5490 return; |
| 5491 } | 5491 } |
| (...skipping 12 matching lines...) Expand all Loading... |
| 5504 overloadedPerWorldBindingsMethod2MethodForMainWorld(info); | 5504 overloadedPerWorldBindingsMethod2MethodForMainWorld(info); |
| 5505 return; | 5505 return; |
| 5506 } | 5506 } |
| 5507 throwTypeError(ExceptionMessages::failedToExecute("overloadedPerWorldBinding
sMethod", "TestObjectPython", "No function was found that matched the signature
provided."), info.GetIsolate()); | 5507 throwTypeError(ExceptionMessages::failedToExecute("overloadedPerWorldBinding
sMethod", "TestObjectPython", "No function was found that matched the signature
provided."), info.GetIsolate()); |
| 5508 } | 5508 } |
| 5509 | 5509 |
| 5510 static void overloadedPerWorldBindingsMethodMethodCallbackForMainWorld(const v8:
:FunctionCallbackInfo<v8::Value>& info) | 5510 static void overloadedPerWorldBindingsMethodMethodCallbackForMainWorld(const v8:
:FunctionCallbackInfo<v8::Value>& info) |
| 5511 { | 5511 { |
| 5512 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 5512 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 5513 TestObjectPythonV8Internal::overloadedPerWorldBindingsMethodMethodForMainWor
ld(info); | 5513 TestObjectPythonV8Internal::overloadedPerWorldBindingsMethodMethodForMainWor
ld(info); |
| 5514 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 5514 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 5515 } | 5515 } |
| 5516 | 5516 |
| 5517 static void overloadedStaticMethod1Method(const v8::FunctionCallbackInfo<v8::Val
ue>& info) | 5517 static void overloadedStaticMethod1Method(const v8::FunctionCallbackInfo<v8::Val
ue>& info) |
| 5518 { | 5518 { |
| 5519 ExceptionState exceptionState(ExceptionState::ExecutionContext, "overloadedS
taticMethod", "TestObjectPython", info.Holder(), info.GetIsolate()); | 5519 ExceptionState exceptionState(ExceptionState::ExecutionContext, "overloadedS
taticMethod", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 5520 if (UNLIKELY(info.Length() < 1)) { | 5520 if (UNLIKELY(info.Length() < 1)) { |
| 5521 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); | 5521 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); |
| 5522 exceptionState.throwIfNeeded(); | 5522 exceptionState.throwIfNeeded(); |
| 5523 return; | 5523 return; |
| 5524 } | 5524 } |
| (...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5556 return; | 5556 return; |
| 5557 } | 5557 } |
| 5558 exceptionState.throwTypeError("No function was found that matched the signat
ure provided."); | 5558 exceptionState.throwTypeError("No function was found that matched the signat
ure provided."); |
| 5559 exceptionState.throwIfNeeded(); | 5559 exceptionState.throwIfNeeded(); |
| 5560 } | 5560 } |
| 5561 | 5561 |
| 5562 static void overloadedStaticMethodMethodCallback(const v8::FunctionCallbackInfo<
v8::Value>& info) | 5562 static void overloadedStaticMethodMethodCallback(const v8::FunctionCallbackInfo<
v8::Value>& info) |
| 5563 { | 5563 { |
| 5564 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 5564 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 5565 TestObjectPythonV8Internal::overloadedStaticMethodMethod(info); | 5565 TestObjectPythonV8Internal::overloadedStaticMethodMethod(info); |
| 5566 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 5566 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 5567 } | 5567 } |
| 5568 | 5568 |
| 5569 static void addEventListenerMethod(const v8::FunctionCallbackInfo<v8::Value>& in
fo) | 5569 static void addEventListenerMethod(const v8::FunctionCallbackInfo<v8::Value>& in
fo) |
| 5570 { | 5570 { |
| 5571 ExceptionState exceptionState(ExceptionState::ExecutionContext, "addEventLis
tener", "TestObjectPython", info.Holder(), info.GetIsolate()); | 5571 ExceptionState exceptionState(ExceptionState::ExecutionContext, "addEventLis
tener", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 5572 EventTarget* impl = V8TestObjectPython::toNative(info.Holder()); | 5572 EventTarget* impl = V8TestObjectPython::toNative(info.Holder()); |
| 5573 if (DOMWindow* window = impl->toDOMWindow()) { | 5573 if (DOMWindow* window = impl->toDOMWindow()) { |
| 5574 if (!BindingSecurity::shouldAllowAccessToFrame(window->frame(), exceptio
nState)) { | 5574 if (!BindingSecurity::shouldAllowAccessToFrame(window->frame(), exceptio
nState)) { |
| 5575 exceptionState.throwIfNeeded(); | 5575 exceptionState.throwIfNeeded(); |
| 5576 return; | 5576 return; |
| 5577 } | 5577 } |
| 5578 if (!window->document()) | 5578 if (!window->document()) |
| 5579 return; | 5579 return; |
| 5580 } | 5580 } |
| 5581 RefPtr<EventListener> listener = V8EventListenerList::getEventListener(info[
1], false, ListenerFindOrCreate); | 5581 RefPtr<EventListener> listener = V8EventListenerList::getEventListener(info[
1], false, ListenerFindOrCreate); |
| 5582 if (listener) { | 5582 if (listener) { |
| 5583 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<WithNullCheck>, ev
entName, info[0]); | 5583 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<WithNullCheck>, ev
entName, info[0]); |
| 5584 impl->addEventListener(eventName, listener, info[2]->BooleanValue()); | 5584 impl->addEventListener(eventName, listener, info[2]->BooleanValue()); |
| 5585 if (!impl->toNode()) | 5585 if (!impl->toNode()) |
| 5586 createHiddenDependency(info.Holder(), info[1], V8TestObjectPython::e
ventListenerCacheIndex, info.GetIsolate()); | 5586 createHiddenDependency(info.Holder(), info[1], V8TestObjectPython::e
ventListenerCacheIndex, info.GetIsolate()); |
| 5587 } | 5587 } |
| 5588 } | 5588 } |
| 5589 | 5589 |
| 5590 static void addEventListenerMethodCallback(const v8::FunctionCallbackInfo<v8::Va
lue>& info) | 5590 static void addEventListenerMethodCallback(const v8::FunctionCallbackInfo<v8::Va
lue>& info) |
| 5591 { | 5591 { |
| 5592 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 5592 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 5593 TestObjectPythonV8Internal::addEventListenerMethod(info); | 5593 TestObjectPythonV8Internal::addEventListenerMethod(info); |
| 5594 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 5594 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 5595 } | 5595 } |
| 5596 | 5596 |
| 5597 static void removeEventListenerMethod(const v8::FunctionCallbackInfo<v8::Value>&
info) | 5597 static void removeEventListenerMethod(const v8::FunctionCallbackInfo<v8::Value>&
info) |
| 5598 { | 5598 { |
| 5599 ExceptionState exceptionState(ExceptionState::ExecutionContext, "removeEvent
Listener", "TestObjectPython", info.Holder(), info.GetIsolate()); | 5599 ExceptionState exceptionState(ExceptionState::ExecutionContext, "removeEvent
Listener", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 5600 EventTarget* impl = V8TestObjectPython::toNative(info.Holder()); | 5600 EventTarget* impl = V8TestObjectPython::toNative(info.Holder()); |
| 5601 if (DOMWindow* window = impl->toDOMWindow()) { | 5601 if (DOMWindow* window = impl->toDOMWindow()) { |
| 5602 if (!BindingSecurity::shouldAllowAccessToFrame(window->frame(), exceptio
nState)) { | 5602 if (!BindingSecurity::shouldAllowAccessToFrame(window->frame(), exceptio
nState)) { |
| 5603 exceptionState.throwIfNeeded(); | 5603 exceptionState.throwIfNeeded(); |
| 5604 return; | 5604 return; |
| 5605 } | 5605 } |
| 5606 if (!window->document()) | 5606 if (!window->document()) |
| 5607 return; | 5607 return; |
| 5608 } | 5608 } |
| 5609 RefPtr<EventListener> listener = V8EventListenerList::getEventListener(info[
1], false, ListenerFindOnly); | 5609 RefPtr<EventListener> listener = V8EventListenerList::getEventListener(info[
1], false, ListenerFindOnly); |
| 5610 if (listener) { | 5610 if (listener) { |
| 5611 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<WithNullCheck>, ev
entName, info[0]); | 5611 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<WithNullCheck>, ev
entName, info[0]); |
| 5612 impl->removeEventListener(eventName, listener.get(), info[2]->BooleanVal
ue()); | 5612 impl->removeEventListener(eventName, listener.get(), info[2]->BooleanVal
ue()); |
| 5613 if (!impl->toNode()) | 5613 if (!impl->toNode()) |
| 5614 removeHiddenDependency(info.Holder(), info[1], V8TestObjectPython::e
ventListenerCacheIndex, info.GetIsolate()); | 5614 removeHiddenDependency(info.Holder(), info[1], V8TestObjectPython::e
ventListenerCacheIndex, info.GetIsolate()); |
| 5615 } | 5615 } |
| 5616 } | 5616 } |
| 5617 | 5617 |
| 5618 static void removeEventListenerMethodCallback(const v8::FunctionCallbackInfo<v8:
:Value>& info) | 5618 static void removeEventListenerMethodCallback(const v8::FunctionCallbackInfo<v8:
:Value>& info) |
| 5619 { | 5619 { |
| 5620 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 5620 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 5621 TestObjectPythonV8Internal::removeEventListenerMethod(info); | 5621 TestObjectPythonV8Internal::removeEventListenerMethod(info); |
| 5622 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 5622 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 5623 } | 5623 } |
| 5624 | 5624 |
| 5625 static void voidMethodClampUnsignedShortArgMethod(const v8::FunctionCallbackInfo
<v8::Value>& info) | 5625 static void voidMethodClampUnsignedShortArgMethod(const v8::FunctionCallbackInfo
<v8::Value>& info) |
| 5626 { | 5626 { |
| 5627 ExceptionState exceptionState(ExceptionState::ExecutionContext, "voidMethodC
lampUnsignedShortArg", "TestObjectPython", info.Holder(), info.GetIsolate()); | 5627 ExceptionState exceptionState(ExceptionState::ExecutionContext, "voidMethodC
lampUnsignedShortArg", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 5628 if (UNLIKELY(info.Length() < 1)) { | 5628 if (UNLIKELY(info.Length() < 1)) { |
| 5629 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); | 5629 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); |
| 5630 exceptionState.throwIfNeeded(); | 5630 exceptionState.throwIfNeeded(); |
| 5631 return; | 5631 return; |
| 5632 } | 5632 } |
| 5633 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 5633 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 5634 unsigned clampUnsignedShortArg = 0; | 5634 unsigned clampUnsignedShortArg = 0; |
| 5635 V8TRYCATCH_VOID(double, clampUnsignedShortArgNativeValue, info[0]->NumberVal
ue()); | 5635 V8TRYCATCH_VOID(double, clampUnsignedShortArgNativeValue, info[0]->NumberVal
ue()); |
| 5636 if (!std::isnan(clampUnsignedShortArgNativeValue)) | 5636 if (!std::isnan(clampUnsignedShortArgNativeValue)) |
| 5637 clampUnsignedShortArg = clampTo<unsigned short>(clampUnsignedShortArgNat
iveValue); | 5637 clampUnsignedShortArg = clampTo<unsigned short>(clampUnsignedShortArgNat
iveValue); |
| 5638 imp->voidMethodClampUnsignedShortArg(clampUnsignedShortArg); | 5638 imp->voidMethodClampUnsignedShortArg(clampUnsignedShortArg); |
| 5639 } | 5639 } |
| 5640 | 5640 |
| 5641 static void voidMethodClampUnsignedShortArgMethodCallback(const v8::FunctionCall
backInfo<v8::Value>& info) | 5641 static void voidMethodClampUnsignedShortArgMethodCallback(const v8::FunctionCall
backInfo<v8::Value>& info) |
| 5642 { | 5642 { |
| 5643 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 5643 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 5644 TestObjectPythonV8Internal::voidMethodClampUnsignedShortArgMethod(info); | 5644 TestObjectPythonV8Internal::voidMethodClampUnsignedShortArgMethod(info); |
| 5645 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 5645 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 5646 } | 5646 } |
| 5647 | 5647 |
| 5648 static void voidMethodClampUnsignedLongArgMethod(const v8::FunctionCallbackInfo<
v8::Value>& info) | 5648 static void voidMethodClampUnsignedLongArgMethod(const v8::FunctionCallbackInfo<
v8::Value>& info) |
| 5649 { | 5649 { |
| 5650 ExceptionState exceptionState(ExceptionState::ExecutionContext, "voidMethodC
lampUnsignedLongArg", "TestObjectPython", info.Holder(), info.GetIsolate()); | 5650 ExceptionState exceptionState(ExceptionState::ExecutionContext, "voidMethodC
lampUnsignedLongArg", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 5651 if (UNLIKELY(info.Length() < 1)) { | 5651 if (UNLIKELY(info.Length() < 1)) { |
| 5652 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); | 5652 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); |
| 5653 exceptionState.throwIfNeeded(); | 5653 exceptionState.throwIfNeeded(); |
| 5654 return; | 5654 return; |
| 5655 } | 5655 } |
| 5656 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 5656 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 5657 unsigned clampUnsignedLongArg = 0; | 5657 unsigned clampUnsignedLongArg = 0; |
| 5658 V8TRYCATCH_VOID(double, clampUnsignedLongArgNativeValue, info[0]->NumberValu
e()); | 5658 V8TRYCATCH_VOID(double, clampUnsignedLongArgNativeValue, info[0]->NumberValu
e()); |
| 5659 if (!std::isnan(clampUnsignedLongArgNativeValue)) | 5659 if (!std::isnan(clampUnsignedLongArgNativeValue)) |
| 5660 clampUnsignedLongArg = clampTo<unsigned long>(clampUnsignedLongArgNative
Value); | 5660 clampUnsignedLongArg = clampTo<unsigned long>(clampUnsignedLongArgNative
Value); |
| 5661 imp->voidMethodClampUnsignedLongArg(clampUnsignedLongArg); | 5661 imp->voidMethodClampUnsignedLongArg(clampUnsignedLongArg); |
| 5662 } | 5662 } |
| 5663 | 5663 |
| 5664 static void voidMethodClampUnsignedLongArgMethodCallback(const v8::FunctionCallb
ackInfo<v8::Value>& info) | 5664 static void voidMethodClampUnsignedLongArgMethodCallback(const v8::FunctionCallb
ackInfo<v8::Value>& info) |
| 5665 { | 5665 { |
| 5666 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 5666 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 5667 TestObjectPythonV8Internal::voidMethodClampUnsignedLongArgMethod(info); | 5667 TestObjectPythonV8Internal::voidMethodClampUnsignedLongArgMethod(info); |
| 5668 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 5668 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 5669 } | 5669 } |
| 5670 | 5670 |
| 5671 static void voidMethodDefaultUndefinedTestInterfaceEmptyArgMethod(const v8::Func
tionCallbackInfo<v8::Value>& info) | 5671 static void voidMethodDefaultUndefinedTestInterfaceEmptyArgMethod(const v8::Func
tionCallbackInfo<v8::Value>& info) |
| 5672 { | 5672 { |
| 5673 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 5673 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 5674 V8TRYCATCH_VOID(TestInterfaceEmpty*, defaultUndefinedTestInterfaceEmptyArg,
V8TestInterfaceEmpty::hasInstance(info[0], info.GetIsolate(), worldType(info.Get
Isolate())) ? V8TestInterfaceEmpty::toNative(v8::Handle<v8::Object>::Cast(info[0
])) : 0); | 5674 V8TRYCATCH_VOID(TestInterfaceEmpty*, defaultUndefinedTestInterfaceEmptyArg,
V8TestInterfaceEmpty::hasInstance(info[0], info.GetIsolate(), worldType(info.Get
Isolate())) ? V8TestInterfaceEmpty::toNative(v8::Handle<v8::Object>::Cast(info[0
])) : 0); |
| 5675 imp->voidMethodDefaultUndefinedTestInterfaceEmptyArg(defaultUndefinedTestInt
erfaceEmptyArg); | 5675 imp->voidMethodDefaultUndefinedTestInterfaceEmptyArg(defaultUndefinedTestInt
erfaceEmptyArg); |
| 5676 } | 5676 } |
| 5677 | 5677 |
| 5678 static void voidMethodDefaultUndefinedTestInterfaceEmptyArgMethodCallback(const
v8::FunctionCallbackInfo<v8::Value>& info) | 5678 static void voidMethodDefaultUndefinedTestInterfaceEmptyArgMethodCallback(const
v8::FunctionCallbackInfo<v8::Value>& info) |
| 5679 { | 5679 { |
| 5680 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 5680 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 5681 TestObjectPythonV8Internal::voidMethodDefaultUndefinedTestInterfaceEmptyArgM
ethod(info); | 5681 TestObjectPythonV8Internal::voidMethodDefaultUndefinedTestInterfaceEmptyArgM
ethod(info); |
| 5682 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 5682 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 5683 } | 5683 } |
| 5684 | 5684 |
| 5685 static void voidMethodDefaultUndefinedLongArgMethod(const v8::FunctionCallbackIn
fo<v8::Value>& info) | 5685 static void voidMethodDefaultUndefinedLongArgMethod(const v8::FunctionCallbackIn
fo<v8::Value>& info) |
| 5686 { | 5686 { |
| 5687 ExceptionState exceptionState(ExceptionState::ExecutionContext, "voidMethodD
efaultUndefinedLongArg", "TestObjectPython", info.Holder(), info.GetIsolate()); | 5687 ExceptionState exceptionState(ExceptionState::ExecutionContext, "voidMethodD
efaultUndefinedLongArg", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 5688 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 5688 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 5689 V8TRYCATCH_EXCEPTION_VOID(int, defaultUndefinedLongArg, toInt32(info[0], exc
eptionState), exceptionState); | 5689 V8TRYCATCH_EXCEPTION_VOID(int, defaultUndefinedLongArg, toInt32(info[0], exc
eptionState), exceptionState); |
| 5690 imp->voidMethodDefaultUndefinedLongArg(defaultUndefinedLongArg); | 5690 imp->voidMethodDefaultUndefinedLongArg(defaultUndefinedLongArg); |
| 5691 } | 5691 } |
| 5692 | 5692 |
| 5693 static void voidMethodDefaultUndefinedLongArgMethodCallback(const v8::FunctionCa
llbackInfo<v8::Value>& info) | 5693 static void voidMethodDefaultUndefinedLongArgMethodCallback(const v8::FunctionCa
llbackInfo<v8::Value>& info) |
| 5694 { | 5694 { |
| 5695 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 5695 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 5696 TestObjectPythonV8Internal::voidMethodDefaultUndefinedLongArgMethod(info); | 5696 TestObjectPythonV8Internal::voidMethodDefaultUndefinedLongArgMethod(info); |
| 5697 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 5697 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 5698 } | 5698 } |
| 5699 | 5699 |
| 5700 static void voidMethodDefaultUndefinedStringArgMethod(const v8::FunctionCallback
Info<v8::Value>& info) | 5700 static void voidMethodDefaultUndefinedStringArgMethod(const v8::FunctionCallback
Info<v8::Value>& info) |
| 5701 { | 5701 { |
| 5702 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 5702 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 5703 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, defaultUndefinedStr
ingArg, info[0]); | 5703 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, defaultUndefinedStr
ingArg, info[0]); |
| 5704 imp->voidMethodDefaultUndefinedStringArg(defaultUndefinedStringArg); | 5704 imp->voidMethodDefaultUndefinedStringArg(defaultUndefinedStringArg); |
| 5705 } | 5705 } |
| 5706 | 5706 |
| 5707 static void voidMethodDefaultUndefinedStringArgMethodCallback(const v8::Function
CallbackInfo<v8::Value>& info) | 5707 static void voidMethodDefaultUndefinedStringArgMethodCallback(const v8::Function
CallbackInfo<v8::Value>& info) |
| 5708 { | 5708 { |
| 5709 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 5709 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 5710 TestObjectPythonV8Internal::voidMethodDefaultUndefinedStringArgMethod(info); | 5710 TestObjectPythonV8Internal::voidMethodDefaultUndefinedStringArgMethod(info); |
| 5711 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 5711 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 5712 } | 5712 } |
| 5713 | 5713 |
| 5714 static void voidMethodDefaultNullStringStringArgMethod(const v8::FunctionCallbac
kInfo<v8::Value>& info) | 5714 static void voidMethodDefaultNullStringStringArgMethod(const v8::FunctionCallbac
kInfo<v8::Value>& info) |
| 5715 { | 5715 { |
| 5716 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 5716 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 5717 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, defaultNullStringSt
ringArg, argumentOrNull(info, 0)); | 5717 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<>, defaultNullStringSt
ringArg, argumentOrNull(info, 0)); |
| 5718 imp->voidMethodDefaultNullStringStringArg(defaultNullStringStringArg); | 5718 imp->voidMethodDefaultNullStringStringArg(defaultNullStringStringArg); |
| 5719 } | 5719 } |
| 5720 | 5720 |
| 5721 static void voidMethodDefaultNullStringStringArgMethodCallback(const v8::Functio
nCallbackInfo<v8::Value>& info) | 5721 static void voidMethodDefaultNullStringStringArgMethodCallback(const v8::Functio
nCallbackInfo<v8::Value>& info) |
| 5722 { | 5722 { |
| 5723 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 5723 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 5724 TestObjectPythonV8Internal::voidMethodDefaultNullStringStringArgMethod(info)
; | 5724 TestObjectPythonV8Internal::voidMethodDefaultNullStringStringArgMethod(info)
; |
| 5725 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 5725 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 5726 } | 5726 } |
| 5727 | 5727 |
| 5728 static void voidMethodEnforceRangeLongArgMethod(const v8::FunctionCallbackInfo<v
8::Value>& info) | 5728 static void voidMethodEnforceRangeLongArgMethod(const v8::FunctionCallbackInfo<v
8::Value>& info) |
| 5729 { | 5729 { |
| 5730 ExceptionState exceptionState(ExceptionState::ExecutionContext, "voidMethodE
nforceRangeLongArg", "TestObjectPython", info.Holder(), info.GetIsolate()); | 5730 ExceptionState exceptionState(ExceptionState::ExecutionContext, "voidMethodE
nforceRangeLongArg", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 5731 if (UNLIKELY(info.Length() < 1)) { | 5731 if (UNLIKELY(info.Length() < 1)) { |
| 5732 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); | 5732 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); |
| 5733 exceptionState.throwIfNeeded(); | 5733 exceptionState.throwIfNeeded(); |
| 5734 return; | 5734 return; |
| 5735 } | 5735 } |
| 5736 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 5736 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 5737 V8TRYCATCH_EXCEPTION_VOID(int, enforceRangeLongArg, toInt32(info[0], Enforce
Range, exceptionState), exceptionState); | 5737 V8TRYCATCH_EXCEPTION_VOID(int, enforceRangeLongArg, toInt32(info[0], Enforce
Range, exceptionState), exceptionState); |
| 5738 imp->voidMethodEnforceRangeLongArg(enforceRangeLongArg); | 5738 imp->voidMethodEnforceRangeLongArg(enforceRangeLongArg); |
| 5739 } | 5739 } |
| 5740 | 5740 |
| 5741 static void voidMethodEnforceRangeLongArgMethodCallback(const v8::FunctionCallba
ckInfo<v8::Value>& info) | 5741 static void voidMethodEnforceRangeLongArgMethodCallback(const v8::FunctionCallba
ckInfo<v8::Value>& info) |
| 5742 { | 5742 { |
| 5743 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 5743 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 5744 TestObjectPythonV8Internal::voidMethodEnforceRangeLongArgMethod(info); | 5744 TestObjectPythonV8Internal::voidMethodEnforceRangeLongArgMethod(info); |
| 5745 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 5745 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 5746 } | 5746 } |
| 5747 | 5747 |
| 5748 static void voidMethodTreatNullAsNullStringStringArgMethod(const v8::FunctionCal
lbackInfo<v8::Value>& info) | 5748 static void voidMethodTreatNullAsNullStringStringArgMethod(const v8::FunctionCal
lbackInfo<v8::Value>& info) |
| 5749 { | 5749 { |
| 5750 if (UNLIKELY(info.Length() < 1)) { | 5750 if (UNLIKELY(info.Length() < 1)) { |
| 5751 throwTypeError(ExceptionMessages::failedToExecute("voidMethodTreatNullAs
NullStringStringArg", "TestObjectPython", ExceptionMessages::notEnoughArguments(
1, info.Length())), info.GetIsolate()); | 5751 throwTypeError(ExceptionMessages::failedToExecute("voidMethodTreatNullAs
NullStringStringArg", "TestObjectPython", ExceptionMessages::notEnoughArguments(
1, info.Length())), info.GetIsolate()); |
| 5752 return; | 5752 return; |
| 5753 } | 5753 } |
| 5754 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 5754 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 5755 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<WithNullCheck>, treatN
ullAsNullStringStringArg, info[0]); | 5755 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<WithNullCheck>, treatN
ullAsNullStringStringArg, info[0]); |
| 5756 imp->voidMethodTreatNullAsNullStringStringArg(treatNullAsNullStringStringArg
); | 5756 imp->voidMethodTreatNullAsNullStringStringArg(treatNullAsNullStringStringArg
); |
| 5757 } | 5757 } |
| 5758 | 5758 |
| 5759 static void voidMethodTreatNullAsNullStringStringArgMethodCallback(const v8::Fun
ctionCallbackInfo<v8::Value>& info) | 5759 static void voidMethodTreatNullAsNullStringStringArgMethodCallback(const v8::Fun
ctionCallbackInfo<v8::Value>& info) |
| 5760 { | 5760 { |
| 5761 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 5761 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 5762 TestObjectPythonV8Internal::voidMethodTreatNullAsNullStringStringArgMethod(i
nfo); | 5762 TestObjectPythonV8Internal::voidMethodTreatNullAsNullStringStringArgMethod(i
nfo); |
| 5763 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 5763 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 5764 } | 5764 } |
| 5765 | 5765 |
| 5766 static void voidMethodTreatNullAsNullStringTreatUndefinedAsNullStringStringArgMe
thod(const v8::FunctionCallbackInfo<v8::Value>& info) | 5766 static void voidMethodTreatNullAsNullStringTreatUndefinedAsNullStringStringArgMe
thod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| 5767 { | 5767 { |
| 5768 if (UNLIKELY(info.Length() < 1)) { | 5768 if (UNLIKELY(info.Length() < 1)) { |
| 5769 throwTypeError(ExceptionMessages::failedToExecute("voidMethodTreatNullAs
NullStringTreatUndefinedAsNullStringStringArg", "TestObjectPython", ExceptionMes
sages::notEnoughArguments(1, info.Length())), info.GetIsolate()); | 5769 throwTypeError(ExceptionMessages::failedToExecute("voidMethodTreatNullAs
NullStringTreatUndefinedAsNullStringStringArg", "TestObjectPython", ExceptionMes
sages::notEnoughArguments(1, info.Length())), info.GetIsolate()); |
| 5770 return; | 5770 return; |
| 5771 } | 5771 } |
| 5772 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 5772 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 5773 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<WithUndefinedOrNullChe
ck>, treatNullAsNullStringStringArg, info[0]); | 5773 V8TRYCATCH_FOR_V8STRINGRESOURCE_VOID(V8StringResource<WithUndefinedOrNullChe
ck>, treatNullAsNullStringStringArg, info[0]); |
| 5774 imp->voidMethodTreatNullAsNullStringTreatUndefinedAsNullStringStringArg(trea
tNullAsNullStringStringArg); | 5774 imp->voidMethodTreatNullAsNullStringTreatUndefinedAsNullStringStringArg(trea
tNullAsNullStringStringArg); |
| 5775 } | 5775 } |
| 5776 | 5776 |
| 5777 static void voidMethodTreatNullAsNullStringTreatUndefinedAsNullStringStringArgMe
thodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) | 5777 static void voidMethodTreatNullAsNullStringTreatUndefinedAsNullStringStringArgMe
thodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| 5778 { | 5778 { |
| 5779 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 5779 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 5780 TestObjectPythonV8Internal::voidMethodTreatNullAsNullStringTreatUndefinedAsN
ullStringStringArgMethod(info); | 5780 TestObjectPythonV8Internal::voidMethodTreatNullAsNullStringTreatUndefinedAsN
ullStringStringArgMethod(info); |
| 5781 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 5781 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 5782 } | 5782 } |
| 5783 | 5783 |
| 5784 static void activityLoggingAccessForAllWorldsMethodMethod(const v8::FunctionCall
backInfo<v8::Value>& info) | 5784 static void activityLoggingAccessForAllWorldsMethodMethod(const v8::FunctionCall
backInfo<v8::Value>& info) |
| 5785 { | 5785 { |
| 5786 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 5786 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 5787 imp->activityLoggingAccessForAllWorldsMethod(); | 5787 imp->activityLoggingAccessForAllWorldsMethod(); |
| 5788 } | 5788 } |
| 5789 | 5789 |
| 5790 static void activityLoggingAccessForAllWorldsMethodMethodCallback(const v8::Func
tionCallbackInfo<v8::Value>& info) | 5790 static void activityLoggingAccessForAllWorldsMethodMethodCallback(const v8::Func
tionCallbackInfo<v8::Value>& info) |
| 5791 { | 5791 { |
| 5792 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 5792 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 5793 V8PerContextData* contextData = V8PerContextData::from(info.GetIsolate()->Ge
tCurrentContext()); | 5793 V8PerContextData* contextData = V8PerContextData::from(info.GetIsolate()->Ge
tCurrentContext()); |
| 5794 if (contextData && contextData->activityLogger()) { | 5794 if (contextData && contextData->activityLogger()) { |
| 5795 Vector<v8::Handle<v8::Value> > loggerArgs = toNativeArguments<v8::Handle
<v8::Value> >(info, 0); | 5795 Vector<v8::Handle<v8::Value> > loggerArgs = toNativeArguments<v8::Handle
<v8::Value> >(info, 0); |
| 5796 contextData->activityLogger()->log("TestObjectPython.activityLoggingAcce
ssForAllWorldsMethod", info.Length(), loggerArgs.data(), "Method"); | 5796 contextData->activityLogger()->log("TestObjectPython.activityLoggingAcce
ssForAllWorldsMethod", info.Length(), loggerArgs.data(), "Method"); |
| 5797 } | 5797 } |
| 5798 TestObjectPythonV8Internal::activityLoggingAccessForAllWorldsMethodMethod(in
fo); | 5798 TestObjectPythonV8Internal::activityLoggingAccessForAllWorldsMethodMethod(in
fo); |
| 5799 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 5799 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 5800 } | 5800 } |
| 5801 | 5801 |
| 5802 static void callWithScriptStateVoidMethodMethod(const v8::FunctionCallbackInfo<v
8::Value>& info) | 5802 static void callWithScriptStateVoidMethodMethod(const v8::FunctionCallbackInfo<v
8::Value>& info) |
| 5803 { | 5803 { |
| 5804 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 5804 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 5805 ScriptState* currentState = ScriptState::current(); | 5805 ScriptState* currentState = ScriptState::current(); |
| 5806 if (!currentState) | 5806 if (!currentState) |
| 5807 return; | 5807 return; |
| 5808 ScriptState& state = *currentState; | 5808 ScriptState& state = *currentState; |
| 5809 imp->callWithScriptStateVoidMethod(&state); | 5809 imp->callWithScriptStateVoidMethod(&state); |
| 5810 if (state.hadException()) { | 5810 if (state.hadException()) { |
| 5811 v8::Local<v8::Value> exception = state.exception(); | 5811 v8::Local<v8::Value> exception = state.exception(); |
| 5812 state.clearException(); | 5812 state.clearException(); |
| 5813 throwError(exception, info.GetIsolate()); | 5813 throwError(exception, info.GetIsolate()); |
| 5814 return; | 5814 return; |
| 5815 } | 5815 } |
| 5816 } | 5816 } |
| 5817 | 5817 |
| 5818 static void callWithScriptStateVoidMethodMethodCallback(const v8::FunctionCallba
ckInfo<v8::Value>& info) | 5818 static void callWithScriptStateVoidMethodMethodCallback(const v8::FunctionCallba
ckInfo<v8::Value>& info) |
| 5819 { | 5819 { |
| 5820 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 5820 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 5821 TestObjectPythonV8Internal::callWithScriptStateVoidMethodMethod(info); | 5821 TestObjectPythonV8Internal::callWithScriptStateVoidMethodMethod(info); |
| 5822 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 5822 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 5823 } | 5823 } |
| 5824 | 5824 |
| 5825 static void callWithScriptStateLongMethodMethod(const v8::FunctionCallbackInfo<v
8::Value>& info) | 5825 static void callWithScriptStateLongMethodMethod(const v8::FunctionCallbackInfo<v
8::Value>& info) |
| 5826 { | 5826 { |
| 5827 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 5827 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 5828 ScriptState* currentState = ScriptState::current(); | 5828 ScriptState* currentState = ScriptState::current(); |
| 5829 if (!currentState) | 5829 if (!currentState) |
| 5830 return; | 5830 return; |
| 5831 ScriptState& state = *currentState; | 5831 ScriptState& state = *currentState; |
| 5832 int result = imp->callWithScriptStateLongMethod(&state); | 5832 int result = imp->callWithScriptStateLongMethod(&state); |
| 5833 if (state.hadException()) { | 5833 if (state.hadException()) { |
| 5834 v8::Local<v8::Value> exception = state.exception(); | 5834 v8::Local<v8::Value> exception = state.exception(); |
| 5835 state.clearException(); | 5835 state.clearException(); |
| 5836 throwError(exception, info.GetIsolate()); | 5836 throwError(exception, info.GetIsolate()); |
| 5837 return; | 5837 return; |
| 5838 } | 5838 } |
| 5839 v8SetReturnValueInt(info, result); | 5839 v8SetReturnValueInt(info, result); |
| 5840 } | 5840 } |
| 5841 | 5841 |
| 5842 static void callWithScriptStateLongMethodMethodCallback(const v8::FunctionCallba
ckInfo<v8::Value>& info) | 5842 static void callWithScriptStateLongMethodMethodCallback(const v8::FunctionCallba
ckInfo<v8::Value>& info) |
| 5843 { | 5843 { |
| 5844 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 5844 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 5845 TestObjectPythonV8Internal::callWithScriptStateLongMethodMethod(info); | 5845 TestObjectPythonV8Internal::callWithScriptStateLongMethodMethod(info); |
| 5846 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 5846 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 5847 } | 5847 } |
| 5848 | 5848 |
| 5849 static void callWithExecutionContextVoidMethodMethod(const v8::FunctionCallbackI
nfo<v8::Value>& info) | 5849 static void callWithExecutionContextVoidMethodMethod(const v8::FunctionCallbackI
nfo<v8::Value>& info) |
| 5850 { | 5850 { |
| 5851 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 5851 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 5852 ExecutionContext* scriptContext = getExecutionContext(); | 5852 ExecutionContext* scriptContext = getExecutionContext(); |
| 5853 imp->callWithExecutionContextVoidMethod(scriptContext); | 5853 imp->callWithExecutionContextVoidMethod(scriptContext); |
| 5854 } | 5854 } |
| 5855 | 5855 |
| 5856 static void callWithExecutionContextVoidMethodMethodCallback(const v8::FunctionC
allbackInfo<v8::Value>& info) | 5856 static void callWithExecutionContextVoidMethodMethodCallback(const v8::FunctionC
allbackInfo<v8::Value>& info) |
| 5857 { | 5857 { |
| 5858 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 5858 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 5859 TestObjectPythonV8Internal::callWithExecutionContextVoidMethodMethod(info); | 5859 TestObjectPythonV8Internal::callWithExecutionContextVoidMethodMethod(info); |
| 5860 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 5860 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 5861 } | 5861 } |
| 5862 | 5862 |
| 5863 static void callWithScriptStateExecutionContextVoidMethodMethod(const v8::Functi
onCallbackInfo<v8::Value>& info) | 5863 static void callWithScriptStateExecutionContextVoidMethodMethod(const v8::Functi
onCallbackInfo<v8::Value>& info) |
| 5864 { | 5864 { |
| 5865 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 5865 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 5866 ScriptState* currentState = ScriptState::current(); | 5866 ScriptState* currentState = ScriptState::current(); |
| 5867 if (!currentState) | 5867 if (!currentState) |
| 5868 return; | 5868 return; |
| 5869 ScriptState& state = *currentState; | 5869 ScriptState& state = *currentState; |
| 5870 ExecutionContext* scriptContext = getExecutionContext(); | 5870 ExecutionContext* scriptContext = getExecutionContext(); |
| 5871 imp->callWithScriptStateExecutionContextVoidMethod(&state, scriptContext); | 5871 imp->callWithScriptStateExecutionContextVoidMethod(&state, scriptContext); |
| 5872 if (state.hadException()) { | 5872 if (state.hadException()) { |
| 5873 v8::Local<v8::Value> exception = state.exception(); | 5873 v8::Local<v8::Value> exception = state.exception(); |
| 5874 state.clearException(); | 5874 state.clearException(); |
| 5875 throwError(exception, info.GetIsolate()); | 5875 throwError(exception, info.GetIsolate()); |
| 5876 return; | 5876 return; |
| 5877 } | 5877 } |
| 5878 } | 5878 } |
| 5879 | 5879 |
| 5880 static void callWithScriptStateExecutionContextVoidMethodMethodCallback(const v8
::FunctionCallbackInfo<v8::Value>& info) | 5880 static void callWithScriptStateExecutionContextVoidMethodMethodCallback(const v8
::FunctionCallbackInfo<v8::Value>& info) |
| 5881 { | 5881 { |
| 5882 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 5882 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 5883 TestObjectPythonV8Internal::callWithScriptStateExecutionContextVoidMethodMet
hod(info); | 5883 TestObjectPythonV8Internal::callWithScriptStateExecutionContextVoidMethodMet
hod(info); |
| 5884 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 5884 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 5885 } | 5885 } |
| 5886 | 5886 |
| 5887 static void callWithScriptStateScriptArgumentsVoidMethodMethod(const v8::Functio
nCallbackInfo<v8::Value>& info) | 5887 static void callWithScriptStateScriptArgumentsVoidMethodMethod(const v8::Functio
nCallbackInfo<v8::Value>& info) |
| 5888 { | 5888 { |
| 5889 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 5889 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 5890 ScriptState* currentState = ScriptState::current(); | 5890 ScriptState* currentState = ScriptState::current(); |
| 5891 if (!currentState) | 5891 if (!currentState) |
| 5892 return; | 5892 return; |
| 5893 ScriptState& state = *currentState; | 5893 ScriptState& state = *currentState; |
| 5894 RefPtr<ScriptArguments> scriptArguments(createScriptArguments(info, 0)); | 5894 RefPtr<ScriptArguments> scriptArguments(createScriptArguments(info, 0)); |
| 5895 imp->callWithScriptStateScriptArgumentsVoidMethod(&state, scriptArguments.re
lease()); | 5895 imp->callWithScriptStateScriptArgumentsVoidMethod(&state, scriptArguments.re
lease()); |
| 5896 if (state.hadException()) { | 5896 if (state.hadException()) { |
| 5897 v8::Local<v8::Value> exception = state.exception(); | 5897 v8::Local<v8::Value> exception = state.exception(); |
| 5898 state.clearException(); | 5898 state.clearException(); |
| 5899 throwError(exception, info.GetIsolate()); | 5899 throwError(exception, info.GetIsolate()); |
| 5900 return; | 5900 return; |
| 5901 } | 5901 } |
| 5902 } | 5902 } |
| 5903 | 5903 |
| 5904 static void callWithScriptStateScriptArgumentsVoidMethodMethodCallback(const v8:
:FunctionCallbackInfo<v8::Value>& info) | 5904 static void callWithScriptStateScriptArgumentsVoidMethodMethodCallback(const v8:
:FunctionCallbackInfo<v8::Value>& info) |
| 5905 { | 5905 { |
| 5906 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 5906 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 5907 TestObjectPythonV8Internal::callWithScriptStateScriptArgumentsVoidMethodMeth
od(info); | 5907 TestObjectPythonV8Internal::callWithScriptStateScriptArgumentsVoidMethodMeth
od(info); |
| 5908 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 5908 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 5909 } | 5909 } |
| 5910 | 5910 |
| 5911 static void callWithScriptStateScriptArgumentsVoidMethodOptionalBooleanArgMethod
(const v8::FunctionCallbackInfo<v8::Value>& info) | 5911 static void callWithScriptStateScriptArgumentsVoidMethodOptionalBooleanArgMethod
(const v8::FunctionCallbackInfo<v8::Value>& info) |
| 5912 { | 5912 { |
| 5913 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 5913 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 5914 if (UNLIKELY(info.Length() <= 0)) { | 5914 if (UNLIKELY(info.Length() <= 0)) { |
| 5915 ScriptState* currentState = ScriptState::current(); | 5915 ScriptState* currentState = ScriptState::current(); |
| 5916 if (!currentState) | 5916 if (!currentState) |
| 5917 return; | 5917 return; |
| 5918 ScriptState& state = *currentState; | 5918 ScriptState& state = *currentState; |
| (...skipping 19 matching lines...) Expand all Loading... |
| 5938 state.clearException(); | 5938 state.clearException(); |
| 5939 throwError(exception, info.GetIsolate()); | 5939 throwError(exception, info.GetIsolate()); |
| 5940 return; | 5940 return; |
| 5941 } | 5941 } |
| 5942 } | 5942 } |
| 5943 | 5943 |
| 5944 static void callWithScriptStateScriptArgumentsVoidMethodOptionalBooleanArgMethod
Callback(const v8::FunctionCallbackInfo<v8::Value>& info) | 5944 static void callWithScriptStateScriptArgumentsVoidMethodOptionalBooleanArgMethod
Callback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| 5945 { | 5945 { |
| 5946 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 5946 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 5947 TestObjectPythonV8Internal::callWithScriptStateScriptArgumentsVoidMethodOpti
onalBooleanArgMethod(info); | 5947 TestObjectPythonV8Internal::callWithScriptStateScriptArgumentsVoidMethodOpti
onalBooleanArgMethod(info); |
| 5948 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 5948 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 5949 } | 5949 } |
| 5950 | 5950 |
| 5951 static void callWithActiveWindowMethod(const v8::FunctionCallbackInfo<v8::Value>
& info) | 5951 static void callWithActiveWindowMethod(const v8::FunctionCallbackInfo<v8::Value>
& info) |
| 5952 { | 5952 { |
| 5953 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 5953 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 5954 imp->callWithActiveWindow(activeDOMWindow()); | 5954 imp->callWithActiveWindow(activeDOMWindow()); |
| 5955 } | 5955 } |
| 5956 | 5956 |
| 5957 static void callWithActiveWindowMethodCallback(const v8::FunctionCallbackInfo<v8
::Value>& info) | 5957 static void callWithActiveWindowMethodCallback(const v8::FunctionCallbackInfo<v8
::Value>& info) |
| 5958 { | 5958 { |
| 5959 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 5959 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 5960 TestObjectPythonV8Internal::callWithActiveWindowMethod(info); | 5960 TestObjectPythonV8Internal::callWithActiveWindowMethod(info); |
| 5961 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 5961 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 5962 } | 5962 } |
| 5963 | 5963 |
| 5964 static void callWithActiveWindowScriptWindowMethod(const v8::FunctionCallbackInf
o<v8::Value>& info) | 5964 static void callWithActiveWindowScriptWindowMethod(const v8::FunctionCallbackInf
o<v8::Value>& info) |
| 5965 { | 5965 { |
| 5966 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 5966 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 5967 imp->callWithActiveWindowScriptWindow(activeDOMWindow(), firstDOMWindow()); | 5967 imp->callWithActiveWindowScriptWindow(activeDOMWindow(), firstDOMWindow()); |
| 5968 } | 5968 } |
| 5969 | 5969 |
| 5970 static void callWithActiveWindowScriptWindowMethodCallback(const v8::FunctionCal
lbackInfo<v8::Value>& info) | 5970 static void callWithActiveWindowScriptWindowMethodCallback(const v8::FunctionCal
lbackInfo<v8::Value>& info) |
| 5971 { | 5971 { |
| 5972 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 5972 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 5973 TestObjectPythonV8Internal::callWithActiveWindowScriptWindowMethod(info); | 5973 TestObjectPythonV8Internal::callWithActiveWindowScriptWindowMethod(info); |
| 5974 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 5974 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 5975 } | 5975 } |
| 5976 | 5976 |
| 5977 static void checkSecurityForNodeVoidMethodMethod(const v8::FunctionCallbackInfo<
v8::Value>& info) | 5977 static void checkSecurityForNodeVoidMethodMethod(const v8::FunctionCallbackInfo<
v8::Value>& info) |
| 5978 { | 5978 { |
| 5979 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 5979 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 5980 if (!BindingSecurity::shouldAllowAccessToNode(imp->checkSecurityForNodeVoidM
ethod(exceptionState), exceptionState)) { | 5980 if (!BindingSecurity::shouldAllowAccessToNode(imp->checkSecurityForNodeVoidM
ethod(exceptionState), exceptionState)) { |
| 5981 v8SetReturnValueNull(info); | 5981 v8SetReturnValueNull(info); |
| 5982 exceptionState.throwIfNeeded(); | 5982 exceptionState.throwIfNeeded(); |
| 5983 return; | 5983 return; |
| 5984 } | 5984 } |
| 5985 imp->checkSecurityForNodeVoidMethod(); | 5985 imp->checkSecurityForNodeVoidMethod(); |
| 5986 } | 5986 } |
| 5987 | 5987 |
| 5988 static void checkSecurityForNodeVoidMethodMethodCallback(const v8::FunctionCallb
ackInfo<v8::Value>& info) | 5988 static void checkSecurityForNodeVoidMethodMethodCallback(const v8::FunctionCallb
ackInfo<v8::Value>& info) |
| 5989 { | 5989 { |
| 5990 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 5990 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 5991 TestObjectPythonV8Internal::checkSecurityForNodeVoidMethodMethod(info); | 5991 TestObjectPythonV8Internal::checkSecurityForNodeVoidMethodMethod(info); |
| 5992 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 5992 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 5993 } | 5993 } |
| 5994 | 5994 |
| 5995 #if ENABLE(CONDITION) | 5995 #if ENABLE(CONDITION) |
| 5996 static void conditionalConditionVoidMethodMethod(const v8::FunctionCallbackInfo<
v8::Value>& info) | 5996 static void conditionalConditionVoidMethodMethod(const v8::FunctionCallbackInfo<
v8::Value>& info) |
| 5997 { | 5997 { |
| 5998 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 5998 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 5999 imp->conditionalConditionVoidMethod(); | 5999 imp->conditionalConditionVoidMethod(); |
| 6000 } | 6000 } |
| 6001 #endif // ENABLE(CONDITION) | 6001 #endif // ENABLE(CONDITION) |
| 6002 | 6002 |
| 6003 #if ENABLE(CONDITION) | 6003 #if ENABLE(CONDITION) |
| 6004 static void conditionalConditionVoidMethodMethodCallback(const v8::FunctionCallb
ackInfo<v8::Value>& info) | 6004 static void conditionalConditionVoidMethodMethodCallback(const v8::FunctionCallb
ackInfo<v8::Value>& info) |
| 6005 { | 6005 { |
| 6006 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 6006 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 6007 TestObjectPythonV8Internal::conditionalConditionVoidMethodMethod(info); | 6007 TestObjectPythonV8Internal::conditionalConditionVoidMethodMethod(info); |
| 6008 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 6008 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 6009 } | 6009 } |
| 6010 #endif // ENABLE(CONDITION) | 6010 #endif // ENABLE(CONDITION) |
| 6011 | 6011 |
| 6012 #if ENABLE(CONDITION_1) && ENABLE(CONDITION_2) | 6012 #if ENABLE(CONDITION_1) && ENABLE(CONDITION_2) |
| 6013 static void conditionalCondition1AndCondition2VoidMethodMethod(const v8::Functio
nCallbackInfo<v8::Value>& info) | 6013 static void conditionalCondition1AndCondition2VoidMethodMethod(const v8::Functio
nCallbackInfo<v8::Value>& info) |
| 6014 { | 6014 { |
| 6015 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 6015 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 6016 imp->conditionalCondition1AndCondition2VoidMethod(); | 6016 imp->conditionalCondition1AndCondition2VoidMethod(); |
| 6017 } | 6017 } |
| 6018 #endif // ENABLE(CONDITION_1) && ENABLE(CONDITION_2) | 6018 #endif // ENABLE(CONDITION_1) && ENABLE(CONDITION_2) |
| 6019 | 6019 |
| 6020 #if ENABLE(CONDITION_1) && ENABLE(CONDITION_2) | 6020 #if ENABLE(CONDITION_1) && ENABLE(CONDITION_2) |
| 6021 static void conditionalCondition1AndCondition2VoidMethodMethodCallback(const v8:
:FunctionCallbackInfo<v8::Value>& info) | 6021 static void conditionalCondition1AndCondition2VoidMethodMethodCallback(const v8:
:FunctionCallbackInfo<v8::Value>& info) |
| 6022 { | 6022 { |
| 6023 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 6023 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 6024 TestObjectPythonV8Internal::conditionalCondition1AndCondition2VoidMethodMeth
od(info); | 6024 TestObjectPythonV8Internal::conditionalCondition1AndCondition2VoidMethodMeth
od(info); |
| 6025 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 6025 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 6026 } | 6026 } |
| 6027 #endif // ENABLE(CONDITION_1) && ENABLE(CONDITION_2) | 6027 #endif // ENABLE(CONDITION_1) && ENABLE(CONDITION_2) |
| 6028 | 6028 |
| 6029 #if ENABLE(CONDITION) | 6029 #if ENABLE(CONDITION) |
| 6030 static void conditionalConditionStaticVoidMethodMethod(const v8::FunctionCallbac
kInfo<v8::Value>& info) | 6030 static void conditionalConditionStaticVoidMethodMethod(const v8::FunctionCallbac
kInfo<v8::Value>& info) |
| 6031 { | 6031 { |
| 6032 TestObjectPython::conditionalConditionStaticVoidMethod(); | 6032 TestObjectPython::conditionalConditionStaticVoidMethod(); |
| 6033 } | 6033 } |
| 6034 #endif // ENABLE(CONDITION) | 6034 #endif // ENABLE(CONDITION) |
| 6035 | 6035 |
| 6036 #if ENABLE(CONDITION) | 6036 #if ENABLE(CONDITION) |
| 6037 static void conditionalConditionStaticVoidMethodMethodCallback(const v8::Functio
nCallbackInfo<v8::Value>& info) | 6037 static void conditionalConditionStaticVoidMethodMethodCallback(const v8::Functio
nCallbackInfo<v8::Value>& info) |
| 6038 { | 6038 { |
| 6039 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 6039 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 6040 TestObjectPythonV8Internal::conditionalConditionStaticVoidMethodMethod(info)
; | 6040 TestObjectPythonV8Internal::conditionalConditionStaticVoidMethodMethod(info)
; |
| 6041 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 6041 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 6042 } | 6042 } |
| 6043 #endif // ENABLE(CONDITION) | 6043 #endif // ENABLE(CONDITION) |
| 6044 | 6044 |
| 6045 static void customVoidMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Va
lue>& info) | 6045 static void customVoidMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Va
lue>& info) |
| 6046 { | 6046 { |
| 6047 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 6047 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 6048 V8TestObjectPython::customVoidMethodMethodCustom(info); | 6048 V8TestObjectPython::customVoidMethodMethodCustom(info); |
| 6049 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 6049 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 6050 } | 6050 } |
| 6051 | 6051 |
| 6052 #if ENABLE(CONDITION) | 6052 #if ENABLE(CONDITION) |
| 6053 static void conditionalConditionCustomVoidMethodMethodCallback(const v8::Functio
nCallbackInfo<v8::Value>& info) | 6053 static void conditionalConditionCustomVoidMethodMethodCallback(const v8::Functio
nCallbackInfo<v8::Value>& info) |
| 6054 { | 6054 { |
| 6055 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 6055 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 6056 V8TestObjectPython::conditionalConditionCustomVoidMethodMethodCustom(info); | 6056 V8TestObjectPython::conditionalConditionCustomVoidMethodMethodCustom(info); |
| 6057 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 6057 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 6058 } | 6058 } |
| 6059 #endif // ENABLE(CONDITION) | 6059 #endif // ENABLE(CONDITION) |
| 6060 | 6060 |
| 6061 static void customElementCallbacksVoidMethodMethod(const v8::FunctionCallbackInf
o<v8::Value>& info) | 6061 static void customElementCallbacksVoidMethodMethod(const v8::FunctionCallbackInf
o<v8::Value>& info) |
| 6062 { | 6062 { |
| 6063 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 6063 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 6064 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; | 6064 CustomElementCallbackDispatcher::CallbackDeliveryScope deliveryScope; |
| 6065 imp->customElementCallbacksVoidMethod(); | 6065 imp->customElementCallbacksVoidMethod(); |
| 6066 } | 6066 } |
| 6067 | 6067 |
| 6068 static void customElementCallbacksVoidMethodMethodCallback(const v8::FunctionCal
lbackInfo<v8::Value>& info) | 6068 static void customElementCallbacksVoidMethodMethodCallback(const v8::FunctionCal
lbackInfo<v8::Value>& info) |
| 6069 { | 6069 { |
| 6070 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 6070 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 6071 TestObjectPythonV8Internal::customElementCallbacksVoidMethodMethod(info); | 6071 TestObjectPythonV8Internal::customElementCallbacksVoidMethodMethod(info); |
| 6072 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 6072 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 6073 } | 6073 } |
| 6074 | 6074 |
| 6075 static void deprecatedVoidMethodMethod(const v8::FunctionCallbackInfo<v8::Value>
& info) | 6075 static void deprecatedVoidMethodMethod(const v8::FunctionCallbackInfo<v8::Value>
& info) |
| 6076 { | 6076 { |
| 6077 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 6077 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 6078 imp->deprecatedVoidMethod(); | 6078 imp->deprecatedVoidMethod(); |
| 6079 } | 6079 } |
| 6080 | 6080 |
| 6081 static void deprecatedVoidMethodMethodCallback(const v8::FunctionCallbackInfo<v8
::Value>& info) | 6081 static void deprecatedVoidMethodMethodCallback(const v8::FunctionCallbackInfo<v8
::Value>& info) |
| 6082 { | 6082 { |
| 6083 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 6083 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 6084 UseCounter::countDeprecation(activeExecutionContext(), UseCounter::voidMetho
d); | 6084 UseCounter::countDeprecation(activeExecutionContext(), UseCounter::voidMetho
d); |
| 6085 TestObjectPythonV8Internal::deprecatedVoidMethodMethod(info); | 6085 TestObjectPythonV8Internal::deprecatedVoidMethodMethod(info); |
| 6086 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 6086 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 6087 } | 6087 } |
| 6088 | 6088 |
| 6089 static void doNotCheckSignatureVoidMethodMethod(const v8::FunctionCallbackInfo<v
8::Value>& info) | 6089 static void doNotCheckSignatureVoidMethodMethod(const v8::FunctionCallbackInfo<v
8::Value>& info) |
| 6090 { | 6090 { |
| 6091 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 6091 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 6092 imp->doNotCheckSignatureVoidMethod(); | 6092 imp->doNotCheckSignatureVoidMethod(); |
| 6093 } | 6093 } |
| 6094 | 6094 |
| 6095 static void doNotCheckSignatureVoidMethodMethodCallback(const v8::FunctionCallba
ckInfo<v8::Value>& info) | 6095 static void doNotCheckSignatureVoidMethodMethodCallback(const v8::FunctionCallba
ckInfo<v8::Value>& info) |
| 6096 { | 6096 { |
| 6097 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 6097 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 6098 TestObjectPythonV8Internal::doNotCheckSignatureVoidMethodMethod(info); | 6098 TestObjectPythonV8Internal::doNotCheckSignatureVoidMethodMethod(info); |
| 6099 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 6099 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 6100 } | 6100 } |
| 6101 | 6101 |
| 6102 static void implementedAsVoidMethodMethod(const v8::FunctionCallbackInfo<v8::Val
ue>& info) | 6102 static void implementedAsVoidMethodMethod(const v8::FunctionCallbackInfo<v8::Val
ue>& info) |
| 6103 { | 6103 { |
| 6104 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 6104 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 6105 imp->implementedAsMethodName(); | 6105 imp->implementedAsMethodName(); |
| 6106 } | 6106 } |
| 6107 | 6107 |
| 6108 static void implementedAsVoidMethodMethodCallback(const v8::FunctionCallbackInfo
<v8::Value>& info) | 6108 static void implementedAsVoidMethodMethodCallback(const v8::FunctionCallbackInfo
<v8::Value>& info) |
| 6109 { | 6109 { |
| 6110 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 6110 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 6111 TestObjectPythonV8Internal::implementedAsVoidMethodMethod(info); | 6111 TestObjectPythonV8Internal::implementedAsVoidMethodMethod(info); |
| 6112 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 6112 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 6113 } | 6113 } |
| 6114 | 6114 |
| 6115 static void measureAsVoidMethodMethod(const v8::FunctionCallbackInfo<v8::Value>&
info) | 6115 static void measureAsVoidMethodMethod(const v8::FunctionCallbackInfo<v8::Value>&
info) |
| 6116 { | 6116 { |
| 6117 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 6117 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 6118 imp->measureAsVoidMethod(); | 6118 imp->measureAsVoidMethod(); |
| 6119 } | 6119 } |
| 6120 | 6120 |
| 6121 static void measureAsVoidMethodMethodCallback(const v8::FunctionCallbackInfo<v8:
:Value>& info) | 6121 static void measureAsVoidMethodMethodCallback(const v8::FunctionCallbackInfo<v8:
:Value>& info) |
| 6122 { | 6122 { |
| 6123 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 6123 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 6124 UseCounter::count(activeExecutionContext(), UseCounter::TestFeature); | 6124 UseCounter::count(activeExecutionContext(), UseCounter::TestFeature); |
| 6125 TestObjectPythonV8Internal::measureAsVoidMethodMethod(info); | 6125 TestObjectPythonV8Internal::measureAsVoidMethodMethod(info); |
| 6126 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 6126 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 6127 } | 6127 } |
| 6128 | 6128 |
| 6129 static void notEnumerableVoidMethodMethod(const v8::FunctionCallbackInfo<v8::Val
ue>& info) | 6129 static void notEnumerableVoidMethodMethod(const v8::FunctionCallbackInfo<v8::Val
ue>& info) |
| 6130 { | 6130 { |
| 6131 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 6131 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 6132 imp->notEnumerableVoidMethod(); | 6132 imp->notEnumerableVoidMethod(); |
| 6133 } | 6133 } |
| 6134 | 6134 |
| 6135 static void notEnumerableVoidMethodMethodCallback(const v8::FunctionCallbackInfo
<v8::Value>& info) | 6135 static void notEnumerableVoidMethodMethodCallback(const v8::FunctionCallbackInfo
<v8::Value>& info) |
| 6136 { | 6136 { |
| 6137 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 6137 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 6138 TestObjectPythonV8Internal::notEnumerableVoidMethodMethod(info); | 6138 TestObjectPythonV8Internal::notEnumerableVoidMethodMethod(info); |
| 6139 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 6139 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 6140 } | 6140 } |
| 6141 | 6141 |
| 6142 static void perContextEnabledVoidMethodMethod(const v8::FunctionCallbackInfo<v8:
:Value>& info) | 6142 static void perContextEnabledVoidMethodMethod(const v8::FunctionCallbackInfo<v8:
:Value>& info) |
| 6143 { | 6143 { |
| 6144 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 6144 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 6145 imp->perContextEnabledVoidMethod(); | 6145 imp->perContextEnabledVoidMethod(); |
| 6146 } | 6146 } |
| 6147 | 6147 |
| 6148 static void perContextEnabledVoidMethodMethodCallback(const v8::FunctionCallback
Info<v8::Value>& info) | 6148 static void perContextEnabledVoidMethodMethodCallback(const v8::FunctionCallback
Info<v8::Value>& info) |
| 6149 { | 6149 { |
| 6150 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 6150 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 6151 TestObjectPythonV8Internal::perContextEnabledVoidMethodMethod(info); | 6151 TestObjectPythonV8Internal::perContextEnabledVoidMethodMethod(info); |
| 6152 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 6152 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 6153 } | 6153 } |
| 6154 | 6154 |
| 6155 static void perWorldBindingsVoidMethodMethod(const v8::FunctionCallbackInfo<v8::
Value>& info) | 6155 static void perWorldBindingsVoidMethodMethod(const v8::FunctionCallbackInfo<v8::
Value>& info) |
| 6156 { | 6156 { |
| 6157 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 6157 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 6158 imp->perWorldBindingsVoidMethod(); | 6158 imp->perWorldBindingsVoidMethod(); |
| 6159 } | 6159 } |
| 6160 | 6160 |
| 6161 static void perWorldBindingsVoidMethodMethodCallback(const v8::FunctionCallbackI
nfo<v8::Value>& info) | 6161 static void perWorldBindingsVoidMethodMethodCallback(const v8::FunctionCallbackI
nfo<v8::Value>& info) |
| 6162 { | 6162 { |
| 6163 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 6163 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 6164 TestObjectPythonV8Internal::perWorldBindingsVoidMethodMethod(info); | 6164 TestObjectPythonV8Internal::perWorldBindingsVoidMethodMethod(info); |
| 6165 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 6165 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 6166 } | 6166 } |
| 6167 | 6167 |
| 6168 static void perWorldBindingsVoidMethodMethodForMainWorld(const v8::FunctionCallb
ackInfo<v8::Value>& info) | 6168 static void perWorldBindingsVoidMethodMethodForMainWorld(const v8::FunctionCallb
ackInfo<v8::Value>& info) |
| 6169 { | 6169 { |
| 6170 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 6170 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 6171 imp->perWorldBindingsVoidMethod(); | 6171 imp->perWorldBindingsVoidMethod(); |
| 6172 } | 6172 } |
| 6173 | 6173 |
| 6174 static void perWorldBindingsVoidMethodMethodCallbackForMainWorld(const v8::Funct
ionCallbackInfo<v8::Value>& info) | 6174 static void perWorldBindingsVoidMethodMethodCallbackForMainWorld(const v8::Funct
ionCallbackInfo<v8::Value>& info) |
| 6175 { | 6175 { |
| 6176 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 6176 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 6177 TestObjectPythonV8Internal::perWorldBindingsVoidMethodMethodForMainWorld(inf
o); | 6177 TestObjectPythonV8Internal::perWorldBindingsVoidMethodMethodForMainWorld(inf
o); |
| 6178 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 6178 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 6179 } | 6179 } |
| 6180 | 6180 |
| 6181 static void activityLoggingForAllWorldsPerWorldBindingsVoidMethodMethod(const v8
::FunctionCallbackInfo<v8::Value>& info) | 6181 static void activityLoggingForAllWorldsPerWorldBindingsVoidMethodMethod(const v8
::FunctionCallbackInfo<v8::Value>& info) |
| 6182 { | 6182 { |
| 6183 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 6183 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 6184 imp->activityLoggingForAllWorldsPerWorldBindingsVoidMethod(); | 6184 imp->activityLoggingForAllWorldsPerWorldBindingsVoidMethod(); |
| 6185 } | 6185 } |
| 6186 | 6186 |
| 6187 static void activityLoggingForAllWorldsPerWorldBindingsVoidMethodMethodCallback(
const v8::FunctionCallbackInfo<v8::Value>& info) | 6187 static void activityLoggingForAllWorldsPerWorldBindingsVoidMethodMethodCallback(
const v8::FunctionCallbackInfo<v8::Value>& info) |
| 6188 { | 6188 { |
| 6189 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 6189 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 6190 V8PerContextData* contextData = V8PerContextData::from(info.GetIsolate()->Ge
tCurrentContext()); | 6190 V8PerContextData* contextData = V8PerContextData::from(info.GetIsolate()->Ge
tCurrentContext()); |
| 6191 if (contextData && contextData->activityLogger()) { | 6191 if (contextData && contextData->activityLogger()) { |
| 6192 Vector<v8::Handle<v8::Value> > loggerArgs = toNativeArguments<v8::Handle
<v8::Value> >(info, 0); | 6192 Vector<v8::Handle<v8::Value> > loggerArgs = toNativeArguments<v8::Handle
<v8::Value> >(info, 0); |
| 6193 contextData->activityLogger()->log("TestObjectPython.activityLoggingForA
llWorldsPerWorldBindingsVoidMethod", info.Length(), loggerArgs.data(), "Method")
; | 6193 contextData->activityLogger()->log("TestObjectPython.activityLoggingForA
llWorldsPerWorldBindingsVoidMethod", info.Length(), loggerArgs.data(), "Method")
; |
| 6194 } | 6194 } |
| 6195 TestObjectPythonV8Internal::activityLoggingForAllWorldsPerWorldBindingsVoidM
ethodMethod(info); | 6195 TestObjectPythonV8Internal::activityLoggingForAllWorldsPerWorldBindingsVoidM
ethodMethod(info); |
| 6196 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 6196 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 6197 } | 6197 } |
| 6198 | 6198 |
| 6199 static void activityLoggingForAllWorldsPerWorldBindingsVoidMethodMethodForMainWo
rld(const v8::FunctionCallbackInfo<v8::Value>& info) | 6199 static void activityLoggingForAllWorldsPerWorldBindingsVoidMethodMethodForMainWo
rld(const v8::FunctionCallbackInfo<v8::Value>& info) |
| 6200 { | 6200 { |
| 6201 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 6201 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 6202 imp->activityLoggingForAllWorldsPerWorldBindingsVoidMethod(); | 6202 imp->activityLoggingForAllWorldsPerWorldBindingsVoidMethod(); |
| 6203 } | 6203 } |
| 6204 | 6204 |
| 6205 static void activityLoggingForAllWorldsPerWorldBindingsVoidMethodMethodCallbackF
orMainWorld(const v8::FunctionCallbackInfo<v8::Value>& info) | 6205 static void activityLoggingForAllWorldsPerWorldBindingsVoidMethodMethodCallbackF
orMainWorld(const v8::FunctionCallbackInfo<v8::Value>& info) |
| 6206 { | 6206 { |
| 6207 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 6207 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 6208 V8PerContextData* contextData = V8PerContextData::from(info.GetIsolate()->Ge
tCurrentContext()); | 6208 V8PerContextData* contextData = V8PerContextData::from(info.GetIsolate()->Ge
tCurrentContext()); |
| 6209 if (contextData && contextData->activityLogger()) { | 6209 if (contextData && contextData->activityLogger()) { |
| 6210 Vector<v8::Handle<v8::Value> > loggerArgs = toNativeArguments<v8::Handle
<v8::Value> >(info, 0); | 6210 Vector<v8::Handle<v8::Value> > loggerArgs = toNativeArguments<v8::Handle
<v8::Value> >(info, 0); |
| 6211 contextData->activityLogger()->log("TestObjectPython.activityLoggingForA
llWorldsPerWorldBindingsVoidMethod", info.Length(), loggerArgs.data(), "Method")
; | 6211 contextData->activityLogger()->log("TestObjectPython.activityLoggingForA
llWorldsPerWorldBindingsVoidMethod", info.Length(), loggerArgs.data(), "Method")
; |
| 6212 } | 6212 } |
| 6213 TestObjectPythonV8Internal::activityLoggingForAllWorldsPerWorldBindingsVoidM
ethodMethodForMainWorld(info); | 6213 TestObjectPythonV8Internal::activityLoggingForAllWorldsPerWorldBindingsVoidM
ethodMethodForMainWorld(info); |
| 6214 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 6214 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 6215 } | 6215 } |
| 6216 | 6216 |
| 6217 static void activityLoggingForIsolatedWorldsPerWorldBindingsVoidMethodMethod(con
st v8::FunctionCallbackInfo<v8::Value>& info) | 6217 static void activityLoggingForIsolatedWorldsPerWorldBindingsVoidMethodMethod(con
st v8::FunctionCallbackInfo<v8::Value>& info) |
| 6218 { | 6218 { |
| 6219 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 6219 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 6220 imp->activityLoggingForIsolatedWorldsPerWorldBindingsVoidMethod(); | 6220 imp->activityLoggingForIsolatedWorldsPerWorldBindingsVoidMethod(); |
| 6221 } | 6221 } |
| 6222 | 6222 |
| 6223 static void activityLoggingForIsolatedWorldsPerWorldBindingsVoidMethodMethodCall
back(const v8::FunctionCallbackInfo<v8::Value>& info) | 6223 static void activityLoggingForIsolatedWorldsPerWorldBindingsVoidMethodMethodCall
back(const v8::FunctionCallbackInfo<v8::Value>& info) |
| 6224 { | 6224 { |
| 6225 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 6225 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 6226 V8PerContextData* contextData = V8PerContextData::from(info.GetIsolate()->Ge
tCurrentContext()); | 6226 V8PerContextData* contextData = V8PerContextData::from(info.GetIsolate()->Ge
tCurrentContext()); |
| 6227 if (contextData && contextData->activityLogger()) { | 6227 if (contextData && contextData->activityLogger()) { |
| 6228 Vector<v8::Handle<v8::Value> > loggerArgs = toNativeArguments<v8::Handle
<v8::Value> >(info, 0); | 6228 Vector<v8::Handle<v8::Value> > loggerArgs = toNativeArguments<v8::Handle
<v8::Value> >(info, 0); |
| 6229 contextData->activityLogger()->log("TestObjectPython.activityLoggingForI
solatedWorldsPerWorldBindingsVoidMethod", info.Length(), loggerArgs.data(), "Met
hod"); | 6229 contextData->activityLogger()->log("TestObjectPython.activityLoggingForI
solatedWorldsPerWorldBindingsVoidMethod", info.Length(), loggerArgs.data(), "Met
hod"); |
| 6230 } | 6230 } |
| 6231 TestObjectPythonV8Internal::activityLoggingForIsolatedWorldsPerWorldBindings
VoidMethodMethod(info); | 6231 TestObjectPythonV8Internal::activityLoggingForIsolatedWorldsPerWorldBindings
VoidMethodMethod(info); |
| 6232 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 6232 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 6233 } | 6233 } |
| 6234 | 6234 |
| 6235 static void activityLoggingForIsolatedWorldsPerWorldBindingsVoidMethodMethodForM
ainWorld(const v8::FunctionCallbackInfo<v8::Value>& info) | 6235 static void activityLoggingForIsolatedWorldsPerWorldBindingsVoidMethodMethodForM
ainWorld(const v8::FunctionCallbackInfo<v8::Value>& info) |
| 6236 { | 6236 { |
| 6237 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 6237 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 6238 imp->activityLoggingForIsolatedWorldsPerWorldBindingsVoidMethod(); | 6238 imp->activityLoggingForIsolatedWorldsPerWorldBindingsVoidMethod(); |
| 6239 } | 6239 } |
| 6240 | 6240 |
| 6241 static void activityLoggingForIsolatedWorldsPerWorldBindingsVoidMethodMethodCall
backForMainWorld(const v8::FunctionCallbackInfo<v8::Value>& info) | 6241 static void activityLoggingForIsolatedWorldsPerWorldBindingsVoidMethodMethodCall
backForMainWorld(const v8::FunctionCallbackInfo<v8::Value>& info) |
| 6242 { | 6242 { |
| 6243 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 6243 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 6244 TestObjectPythonV8Internal::activityLoggingForIsolatedWorldsPerWorldBindings
VoidMethodMethodForMainWorld(info); | 6244 TestObjectPythonV8Internal::activityLoggingForIsolatedWorldsPerWorldBindings
VoidMethodMethodForMainWorld(info); |
| 6245 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 6245 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 6246 } | 6246 } |
| 6247 | 6247 |
| 6248 static void perWorldBindingsVoidMethodTestInterfaceEmptyArgMethod(const v8::Func
tionCallbackInfo<v8::Value>& info) | 6248 static void perWorldBindingsVoidMethodTestInterfaceEmptyArgMethod(const v8::Func
tionCallbackInfo<v8::Value>& info) |
| 6249 { | 6249 { |
| 6250 if (UNLIKELY(info.Length() < 1)) { | 6250 if (UNLIKELY(info.Length() < 1)) { |
| 6251 throwTypeError(ExceptionMessages::failedToExecute("perWorldBindingsVoidM
ethodTestInterfaceEmptyArg", "TestObjectPython", ExceptionMessages::notEnoughArg
uments(1, info.Length())), info.GetIsolate()); | 6251 throwTypeError(ExceptionMessages::failedToExecute("perWorldBindingsVoidM
ethodTestInterfaceEmptyArg", "TestObjectPython", ExceptionMessages::notEnoughArg
uments(1, info.Length())), info.GetIsolate()); |
| 6252 return; | 6252 return; |
| 6253 } | 6253 } |
| 6254 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 6254 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 6255 V8TRYCATCH_VOID(TestInterfaceEmpty*, testInterfaceEmptyArg, V8TestInterfaceE
mpty::hasInstance(info[0], info.GetIsolate(), worldType(info.GetIsolate())) ? V8
TestInterfaceEmpty::toNative(v8::Handle<v8::Object>::Cast(info[0])) : 0); | 6255 V8TRYCATCH_VOID(TestInterfaceEmpty*, testInterfaceEmptyArg, V8TestInterfaceE
mpty::hasInstance(info[0], info.GetIsolate(), worldType(info.GetIsolate())) ? V8
TestInterfaceEmpty::toNative(v8::Handle<v8::Object>::Cast(info[0])) : 0); |
| 6256 imp->perWorldBindingsVoidMethodTestInterfaceEmptyArg(testInterfaceEmptyArg); | 6256 imp->perWorldBindingsVoidMethodTestInterfaceEmptyArg(testInterfaceEmptyArg); |
| 6257 } | 6257 } |
| 6258 | 6258 |
| 6259 static void perWorldBindingsVoidMethodTestInterfaceEmptyArgMethodCallback(const
v8::FunctionCallbackInfo<v8::Value>& info) | 6259 static void perWorldBindingsVoidMethodTestInterfaceEmptyArgMethodCallback(const
v8::FunctionCallbackInfo<v8::Value>& info) |
| 6260 { | 6260 { |
| 6261 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 6261 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 6262 TestObjectPythonV8Internal::perWorldBindingsVoidMethodTestInterfaceEmptyArgM
ethod(info); | 6262 TestObjectPythonV8Internal::perWorldBindingsVoidMethodTestInterfaceEmptyArgM
ethod(info); |
| 6263 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 6263 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 6264 } | 6264 } |
| 6265 | 6265 |
| 6266 static void perWorldBindingsVoidMethodTestInterfaceEmptyArgMethodForMainWorld(co
nst v8::FunctionCallbackInfo<v8::Value>& info) | 6266 static void perWorldBindingsVoidMethodTestInterfaceEmptyArgMethodForMainWorld(co
nst v8::FunctionCallbackInfo<v8::Value>& info) |
| 6267 { | 6267 { |
| 6268 if (UNLIKELY(info.Length() < 1)) { | 6268 if (UNLIKELY(info.Length() < 1)) { |
| 6269 throwTypeError(ExceptionMessages::failedToExecute("perWorldBindingsVoidM
ethodTestInterfaceEmptyArg", "TestObjectPython", ExceptionMessages::notEnoughArg
uments(1, info.Length())), info.GetIsolate()); | 6269 throwTypeError(ExceptionMessages::failedToExecute("perWorldBindingsVoidM
ethodTestInterfaceEmptyArg", "TestObjectPython", ExceptionMessages::notEnoughArg
uments(1, info.Length())), info.GetIsolate()); |
| 6270 return; | 6270 return; |
| 6271 } | 6271 } |
| 6272 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 6272 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 6273 V8TRYCATCH_VOID(TestInterfaceEmpty*, testInterfaceEmptyArg, V8TestInterfaceE
mpty::hasInstance(info[0], info.GetIsolate(), worldType(info.GetIsolate())) ? V8
TestInterfaceEmpty::toNative(v8::Handle<v8::Object>::Cast(info[0])) : 0); | 6273 V8TRYCATCH_VOID(TestInterfaceEmpty*, testInterfaceEmptyArg, V8TestInterfaceE
mpty::hasInstance(info[0], info.GetIsolate(), worldType(info.GetIsolate())) ? V8
TestInterfaceEmpty::toNative(v8::Handle<v8::Object>::Cast(info[0])) : 0); |
| 6274 imp->perWorldBindingsVoidMethodTestInterfaceEmptyArg(testInterfaceEmptyArg); | 6274 imp->perWorldBindingsVoidMethodTestInterfaceEmptyArg(testInterfaceEmptyArg); |
| 6275 } | 6275 } |
| 6276 | 6276 |
| 6277 static void perWorldBindingsVoidMethodTestInterfaceEmptyArgMethodCallbackForMain
World(const v8::FunctionCallbackInfo<v8::Value>& info) | 6277 static void perWorldBindingsVoidMethodTestInterfaceEmptyArgMethodCallbackForMain
World(const v8::FunctionCallbackInfo<v8::Value>& info) |
| 6278 { | 6278 { |
| 6279 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 6279 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 6280 TestObjectPythonV8Internal::perWorldBindingsVoidMethodTestInterfaceEmptyArgM
ethodForMainWorld(info); | 6280 TestObjectPythonV8Internal::perWorldBindingsVoidMethodTestInterfaceEmptyArgM
ethodForMainWorld(info); |
| 6281 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 6281 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 6282 } | 6282 } |
| 6283 | 6283 |
| 6284 static void raisesExceptionVoidMethodMethod(const v8::FunctionCallbackInfo<v8::V
alue>& info) | 6284 static void raisesExceptionVoidMethodMethod(const v8::FunctionCallbackInfo<v8::V
alue>& info) |
| 6285 { | 6285 { |
| 6286 ExceptionState exceptionState(ExceptionState::ExecutionContext, "raisesExcep
tionVoidMethod", "TestObjectPython", info.Holder(), info.GetIsolate()); | 6286 ExceptionState exceptionState(ExceptionState::ExecutionContext, "raisesExcep
tionVoidMethod", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 6287 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 6287 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 6288 imp->raisesExceptionVoidMethod(exceptionState); | 6288 imp->raisesExceptionVoidMethod(exceptionState); |
| 6289 if (exceptionState.throwIfNeeded()) | 6289 if (exceptionState.throwIfNeeded()) |
| 6290 return; | 6290 return; |
| 6291 } | 6291 } |
| 6292 | 6292 |
| 6293 static void raisesExceptionVoidMethodMethodCallback(const v8::FunctionCallbackIn
fo<v8::Value>& info) | 6293 static void raisesExceptionVoidMethodMethodCallback(const v8::FunctionCallbackIn
fo<v8::Value>& info) |
| 6294 { | 6294 { |
| 6295 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 6295 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 6296 TestObjectPythonV8Internal::raisesExceptionVoidMethodMethod(info); | 6296 TestObjectPythonV8Internal::raisesExceptionVoidMethodMethod(info); |
| 6297 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 6297 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 6298 } | 6298 } |
| 6299 | 6299 |
| 6300 static void raisesExceptionStringMethodMethod(const v8::FunctionCallbackInfo<v8:
:Value>& info) | 6300 static void raisesExceptionStringMethodMethod(const v8::FunctionCallbackInfo<v8:
:Value>& info) |
| 6301 { | 6301 { |
| 6302 ExceptionState exceptionState(ExceptionState::ExecutionContext, "raisesExcep
tionStringMethod", "TestObjectPython", info.Holder(), info.GetIsolate()); | 6302 ExceptionState exceptionState(ExceptionState::ExecutionContext, "raisesExcep
tionStringMethod", "TestObjectPython", info.Holder(), info.GetIsolate()); |
| 6303 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 6303 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 6304 String result = imp->raisesExceptionStringMethod(exceptionState); | 6304 String result = imp->raisesExceptionStringMethod(exceptionState); |
| 6305 if (exceptionState.throwIfNeeded()) | 6305 if (exceptionState.throwIfNeeded()) |
| 6306 return; | 6306 return; |
| 6307 v8SetReturnValueString(info, result, info.GetIsolate()); | 6307 v8SetReturnValueString(info, result, info.GetIsolate()); |
| 6308 } | 6308 } |
| 6309 | 6309 |
| 6310 static void raisesExceptionStringMethodMethodCallback(const v8::FunctionCallback
Info<v8::Value>& info) | 6310 static void raisesExceptionStringMethodMethodCallback(const v8::FunctionCallback
Info<v8::Value>& info) |
| 6311 { | 6311 { |
| 6312 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 6312 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 6313 TestObjectPythonV8Internal::raisesExceptionStringMethodMethod(info); | 6313 TestObjectPythonV8Internal::raisesExceptionStringMethodMethod(info); |
| 6314 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 6314 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 6315 } | 6315 } |
| 6316 | 6316 |
| 6317 static void raisesExceptionVoidMethodOptionalLongArgMethod(const v8::FunctionCal
lbackInfo<v8::Value>& info) | 6317 static void raisesExceptionVoidMethodOptionalLongArgMethod(const v8::FunctionCal
lbackInfo<v8::Value>& info) |
| 6318 { | 6318 { |
| 6319 ExceptionState exceptionState(ExceptionState::ExecutionContext, "raisesExcep
tionVoidMethodOptionalLongArg", "TestObjectPython", info.Holder(), info.GetIsola
te()); | 6319 ExceptionState exceptionState(ExceptionState::ExecutionContext, "raisesExcep
tionVoidMethodOptionalLongArg", "TestObjectPython", info.Holder(), info.GetIsola
te()); |
| 6320 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 6320 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 6321 if (UNLIKELY(info.Length() <= 0)) { | 6321 if (UNLIKELY(info.Length() <= 0)) { |
| 6322 imp->raisesExceptionVoidMethodOptionalLongArg(exceptionState); | 6322 imp->raisesExceptionVoidMethodOptionalLongArg(exceptionState); |
| 6323 if (exceptionState.throwIfNeeded()) | 6323 if (exceptionState.throwIfNeeded()) |
| 6324 return; | 6324 return; |
| 6325 return; | 6325 return; |
| 6326 } | 6326 } |
| 6327 V8TRYCATCH_EXCEPTION_VOID(int, optionalLongArg, toInt32(info[0], exceptionSt
ate), exceptionState); | 6327 V8TRYCATCH_EXCEPTION_VOID(int, optionalLongArg, toInt32(info[0], exceptionSt
ate), exceptionState); |
| 6328 imp->raisesExceptionVoidMethodOptionalLongArg(optionalLongArg, exceptionStat
e); | 6328 imp->raisesExceptionVoidMethodOptionalLongArg(optionalLongArg, exceptionStat
e); |
| 6329 if (exceptionState.throwIfNeeded()) | 6329 if (exceptionState.throwIfNeeded()) |
| 6330 return; | 6330 return; |
| 6331 } | 6331 } |
| 6332 | 6332 |
| 6333 static void raisesExceptionVoidMethodOptionalLongArgMethodCallback(const v8::Fun
ctionCallbackInfo<v8::Value>& info) | 6333 static void raisesExceptionVoidMethodOptionalLongArgMethodCallback(const v8::Fun
ctionCallbackInfo<v8::Value>& info) |
| 6334 { | 6334 { |
| 6335 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 6335 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 6336 TestObjectPythonV8Internal::raisesExceptionVoidMethodOptionalLongArgMethod(i
nfo); | 6336 TestObjectPythonV8Internal::raisesExceptionVoidMethodOptionalLongArgMethod(i
nfo); |
| 6337 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 6337 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 6338 } | 6338 } |
| 6339 | 6339 |
| 6340 static void raisesExceptionVoidMethodTestCallbackInterfaceArgMethod(const v8::Fu
nctionCallbackInfo<v8::Value>& info) | 6340 static void raisesExceptionVoidMethodTestCallbackInterfaceArgMethod(const v8::Fu
nctionCallbackInfo<v8::Value>& info) |
| 6341 { | 6341 { |
| 6342 ExceptionState exceptionState(ExceptionState::ExecutionContext, "raisesExcep
tionVoidMethodTestCallbackInterfaceArg", "TestObjectPython", info.Holder(), info
.GetIsolate()); | 6342 ExceptionState exceptionState(ExceptionState::ExecutionContext, "raisesExcep
tionVoidMethodTestCallbackInterfaceArg", "TestObjectPython", info.Holder(), info
.GetIsolate()); |
| 6343 if (UNLIKELY(info.Length() < 1)) { | 6343 if (UNLIKELY(info.Length() < 1)) { |
| 6344 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); | 6344 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(1, i
nfo.Length())); |
| 6345 exceptionState.throwIfNeeded(); | 6345 exceptionState.throwIfNeeded(); |
| 6346 return; | 6346 return; |
| 6347 } | 6347 } |
| 6348 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 6348 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 6349 if (info.Length() <= 0 || !info[0]->IsFunction()) { | 6349 if (info.Length() <= 0 || !info[0]->IsFunction()) { |
| 6350 exceptionState.throwTypeError("The callback provided as parameter 1 is n
ot a function."); | 6350 exceptionState.throwTypeError("The callback provided as parameter 1 is n
ot a function."); |
| 6351 exceptionState.throwIfNeeded(); | 6351 exceptionState.throwIfNeeded(); |
| 6352 return; | 6352 return; |
| 6353 } | 6353 } |
| 6354 OwnPtr<TestCallbackInterface> testCallbackInterfaceArg = V8TestCallbackInter
face::create(v8::Handle<v8::Function>::Cast(info[0]), getExecutionContext()); | 6354 OwnPtr<TestCallbackInterface> testCallbackInterfaceArg = V8TestCallbackInter
face::create(v8::Handle<v8::Function>::Cast(info[0]), getExecutionContext()); |
| 6355 imp->raisesExceptionVoidMethodTestCallbackInterfaceArg(testCallbackInterface
Arg.release(), exceptionState); | 6355 imp->raisesExceptionVoidMethodTestCallbackInterfaceArg(testCallbackInterface
Arg.release(), exceptionState); |
| 6356 if (exceptionState.throwIfNeeded()) | 6356 if (exceptionState.throwIfNeeded()) |
| 6357 return; | 6357 return; |
| 6358 } | 6358 } |
| 6359 | 6359 |
| 6360 static void raisesExceptionVoidMethodTestCallbackInterfaceArgMethodCallback(cons
t v8::FunctionCallbackInfo<v8::Value>& info) | 6360 static void raisesExceptionVoidMethodTestCallbackInterfaceArgMethodCallback(cons
t v8::FunctionCallbackInfo<v8::Value>& info) |
| 6361 { | 6361 { |
| 6362 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 6362 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 6363 TestObjectPythonV8Internal::raisesExceptionVoidMethodTestCallbackInterfaceAr
gMethod(info); | 6363 TestObjectPythonV8Internal::raisesExceptionVoidMethodTestCallbackInterfaceAr
gMethod(info); |
| 6364 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 6364 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 6365 } | 6365 } |
| 6366 | 6366 |
| 6367 static void raisesExceptionVoidMethodOptionalTestCallbackInterfaceArgMethod(cons
t v8::FunctionCallbackInfo<v8::Value>& info) | 6367 static void raisesExceptionVoidMethodOptionalTestCallbackInterfaceArgMethod(cons
t v8::FunctionCallbackInfo<v8::Value>& info) |
| 6368 { | 6368 { |
| 6369 ExceptionState exceptionState(ExceptionState::ExecutionContext, "raisesExcep
tionVoidMethodOptionalTestCallbackInterfaceArg", "TestObjectPython", info.Holder
(), info.GetIsolate()); | 6369 ExceptionState exceptionState(ExceptionState::ExecutionContext, "raisesExcep
tionVoidMethodOptionalTestCallbackInterfaceArg", "TestObjectPython", info.Holder
(), info.GetIsolate()); |
| 6370 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 6370 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 6371 OwnPtr<TestCallbackInterface> optionalTestCallbackInterfaceArg; | 6371 OwnPtr<TestCallbackInterface> optionalTestCallbackInterfaceArg; |
| 6372 if (info.Length() > 0 && !isUndefinedOrNull(info[0])) { | 6372 if (info.Length() > 0 && !isUndefinedOrNull(info[0])) { |
| 6373 if (!info[0]->IsFunction()) { | 6373 if (!info[0]->IsFunction()) { |
| 6374 exceptionState.throwTypeError("The callback provided as parameter 1
is not a function."); | 6374 exceptionState.throwTypeError("The callback provided as parameter 1
is not a function."); |
| 6375 exceptionState.throwIfNeeded(); | 6375 exceptionState.throwIfNeeded(); |
| 6376 return; | 6376 return; |
| 6377 } | 6377 } |
| 6378 optionalTestCallbackInterfaceArg = V8TestCallbackInterface::create(v8::H
andle<v8::Function>::Cast(info[0]), getExecutionContext()); | 6378 optionalTestCallbackInterfaceArg = V8TestCallbackInterface::create(v8::H
andle<v8::Function>::Cast(info[0]), getExecutionContext()); |
| 6379 } | 6379 } |
| 6380 imp->raisesExceptionVoidMethodOptionalTestCallbackInterfaceArg(optionalTestC
allbackInterfaceArg.release(), exceptionState); | 6380 imp->raisesExceptionVoidMethodOptionalTestCallbackInterfaceArg(optionalTestC
allbackInterfaceArg.release(), exceptionState); |
| 6381 if (exceptionState.throwIfNeeded()) | 6381 if (exceptionState.throwIfNeeded()) |
| 6382 return; | 6382 return; |
| 6383 } | 6383 } |
| 6384 | 6384 |
| 6385 static void raisesExceptionVoidMethodOptionalTestCallbackInterfaceArgMethodCallb
ack(const v8::FunctionCallbackInfo<v8::Value>& info) | 6385 static void raisesExceptionVoidMethodOptionalTestCallbackInterfaceArgMethodCallb
ack(const v8::FunctionCallbackInfo<v8::Value>& info) |
| 6386 { | 6386 { |
| 6387 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 6387 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 6388 TestObjectPythonV8Internal::raisesExceptionVoidMethodOptionalTestCallbackInt
erfaceArgMethod(info); | 6388 TestObjectPythonV8Internal::raisesExceptionVoidMethodOptionalTestCallbackInt
erfaceArgMethod(info); |
| 6389 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 6389 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 6390 } | 6390 } |
| 6391 | 6391 |
| 6392 static void readOnlyVoidMethodMethod(const v8::FunctionCallbackInfo<v8::Value>&
info) | 6392 static void readOnlyVoidMethodMethod(const v8::FunctionCallbackInfo<v8::Value>&
info) |
| 6393 { | 6393 { |
| 6394 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 6394 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 6395 imp->readOnlyVoidMethod(); | 6395 imp->readOnlyVoidMethod(); |
| 6396 } | 6396 } |
| 6397 | 6397 |
| 6398 static void readOnlyVoidMethodMethodCallback(const v8::FunctionCallbackInfo<v8::
Value>& info) | 6398 static void readOnlyVoidMethodMethodCallback(const v8::FunctionCallbackInfo<v8::
Value>& info) |
| 6399 { | 6399 { |
| 6400 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 6400 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 6401 TestObjectPythonV8Internal::readOnlyVoidMethodMethod(info); | 6401 TestObjectPythonV8Internal::readOnlyVoidMethodMethod(info); |
| 6402 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 6402 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 6403 } | 6403 } |
| 6404 | 6404 |
| 6405 static void notEnumerableReadOnlyVoidMethodMethod(const v8::FunctionCallbackInfo
<v8::Value>& info) | 6405 static void notEnumerableReadOnlyVoidMethodMethod(const v8::FunctionCallbackInfo
<v8::Value>& info) |
| 6406 { | 6406 { |
| 6407 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 6407 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 6408 imp->notEnumerableReadOnlyVoidMethod(); | 6408 imp->notEnumerableReadOnlyVoidMethod(); |
| 6409 } | 6409 } |
| 6410 | 6410 |
| 6411 static void notEnumerableReadOnlyVoidMethodMethodCallback(const v8::FunctionCall
backInfo<v8::Value>& info) | 6411 static void notEnumerableReadOnlyVoidMethodMethodCallback(const v8::FunctionCall
backInfo<v8::Value>& info) |
| 6412 { | 6412 { |
| 6413 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 6413 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 6414 TestObjectPythonV8Internal::notEnumerableReadOnlyVoidMethodMethod(info); | 6414 TestObjectPythonV8Internal::notEnumerableReadOnlyVoidMethodMethod(info); |
| 6415 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 6415 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 6416 } | 6416 } |
| 6417 | 6417 |
| 6418 static void runtimeEnabledVoidMethodMethod(const v8::FunctionCallbackInfo<v8::Va
lue>& info) | 6418 static void runtimeEnabledVoidMethodMethod(const v8::FunctionCallbackInfo<v8::Va
lue>& info) |
| 6419 { | 6419 { |
| 6420 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 6420 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 6421 imp->runtimeEnabledVoidMethod(); | 6421 imp->runtimeEnabledVoidMethod(); |
| 6422 } | 6422 } |
| 6423 | 6423 |
| 6424 static void runtimeEnabledVoidMethodMethodCallback(const v8::FunctionCallbackInf
o<v8::Value>& info) | 6424 static void runtimeEnabledVoidMethodMethodCallback(const v8::FunctionCallbackInf
o<v8::Value>& info) |
| 6425 { | 6425 { |
| 6426 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 6426 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 6427 TestObjectPythonV8Internal::runtimeEnabledVoidMethodMethod(info); | 6427 TestObjectPythonV8Internal::runtimeEnabledVoidMethodMethod(info); |
| 6428 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 6428 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 6429 } | 6429 } |
| 6430 | 6430 |
| 6431 static void perWorldBindingsRuntimeEnabledVoidMethodMethod(const v8::FunctionCal
lbackInfo<v8::Value>& info) | 6431 static void perWorldBindingsRuntimeEnabledVoidMethodMethod(const v8::FunctionCal
lbackInfo<v8::Value>& info) |
| 6432 { | 6432 { |
| 6433 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 6433 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 6434 imp->perWorldBindingsRuntimeEnabledVoidMethod(); | 6434 imp->perWorldBindingsRuntimeEnabledVoidMethod(); |
| 6435 } | 6435 } |
| 6436 | 6436 |
| 6437 static void perWorldBindingsRuntimeEnabledVoidMethodMethodCallback(const v8::Fun
ctionCallbackInfo<v8::Value>& info) | 6437 static void perWorldBindingsRuntimeEnabledVoidMethodMethodCallback(const v8::Fun
ctionCallbackInfo<v8::Value>& info) |
| 6438 { | 6438 { |
| 6439 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 6439 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 6440 TestObjectPythonV8Internal::perWorldBindingsRuntimeEnabledVoidMethodMethod(i
nfo); | 6440 TestObjectPythonV8Internal::perWorldBindingsRuntimeEnabledVoidMethodMethod(i
nfo); |
| 6441 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 6441 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 6442 } | 6442 } |
| 6443 | 6443 |
| 6444 static void perWorldBindingsRuntimeEnabledVoidMethodMethodForMainWorld(const v8:
:FunctionCallbackInfo<v8::Value>& info) | 6444 static void perWorldBindingsRuntimeEnabledVoidMethodMethodForMainWorld(const v8:
:FunctionCallbackInfo<v8::Value>& info) |
| 6445 { | 6445 { |
| 6446 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 6446 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 6447 imp->perWorldBindingsRuntimeEnabledVoidMethod(); | 6447 imp->perWorldBindingsRuntimeEnabledVoidMethod(); |
| 6448 } | 6448 } |
| 6449 | 6449 |
| 6450 static void perWorldBindingsRuntimeEnabledVoidMethodMethodCallbackForMainWorld(c
onst v8::FunctionCallbackInfo<v8::Value>& info) | 6450 static void perWorldBindingsRuntimeEnabledVoidMethodMethodCallbackForMainWorld(c
onst v8::FunctionCallbackInfo<v8::Value>& info) |
| 6451 { | 6451 { |
| 6452 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 6452 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 6453 TestObjectPythonV8Internal::perWorldBindingsRuntimeEnabledVoidMethodMethodFo
rMainWorld(info); | 6453 TestObjectPythonV8Internal::perWorldBindingsRuntimeEnabledVoidMethodMethodFo
rMainWorld(info); |
| 6454 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 6454 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 6455 } | 6455 } |
| 6456 | 6456 |
| 6457 static void strictTypeCheckingVoidMethodTestInterfaceEmptyArgMethod(const v8::Fu
nctionCallbackInfo<v8::Value>& info) | 6457 static void strictTypeCheckingVoidMethodTestInterfaceEmptyArgMethod(const v8::Fu
nctionCallbackInfo<v8::Value>& info) |
| 6458 { | 6458 { |
| 6459 if (UNLIKELY(info.Length() < 1)) { | 6459 if (UNLIKELY(info.Length() < 1)) { |
| 6460 throwTypeError(ExceptionMessages::failedToExecute("strictTypeCheckingVoi
dMethodTestInterfaceEmptyArg", "TestObjectPython", ExceptionMessages::notEnoughA
rguments(1, info.Length())), info.GetIsolate()); | 6460 throwTypeError(ExceptionMessages::failedToExecute("strictTypeCheckingVoi
dMethodTestInterfaceEmptyArg", "TestObjectPython", ExceptionMessages::notEnoughA
rguments(1, info.Length())), info.GetIsolate()); |
| 6461 return; | 6461 return; |
| 6462 } | 6462 } |
| 6463 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 6463 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 6464 if (info.Length() > 0 && !isUndefinedOrNull(info[0]) && !V8TestInterfaceEmpt
y::hasInstance(info[0], info.GetIsolate(), worldType(info.GetIsolate()))) { | 6464 if (info.Length() > 0 && !isUndefinedOrNull(info[0]) && !V8TestInterfaceEmpt
y::hasInstance(info[0], info.GetIsolate(), worldType(info.GetIsolate()))) { |
| 6465 throwTypeError(ExceptionMessages::failedToExecute("strictTypeCheckingVoi
dMethodTestInterfaceEmptyArg", "TestObjectPython", "parameter 1 is not of type '
TestInterfaceEmpty'."), info.GetIsolate()); | 6465 throwTypeError(ExceptionMessages::failedToExecute("strictTypeCheckingVoi
dMethodTestInterfaceEmptyArg", "TestObjectPython", "parameter 1 is not of type '
TestInterfaceEmpty'."), info.GetIsolate()); |
| 6466 return; | 6466 return; |
| 6467 } | 6467 } |
| 6468 V8TRYCATCH_VOID(TestInterfaceEmpty*, testInterfaceEmptyArg, V8TestInterfaceE
mpty::hasInstance(info[0], info.GetIsolate(), worldType(info.GetIsolate())) ? V8
TestInterfaceEmpty::toNative(v8::Handle<v8::Object>::Cast(info[0])) : 0); | 6468 V8TRYCATCH_VOID(TestInterfaceEmpty*, testInterfaceEmptyArg, V8TestInterfaceE
mpty::hasInstance(info[0], info.GetIsolate(), worldType(info.GetIsolate())) ? V8
TestInterfaceEmpty::toNative(v8::Handle<v8::Object>::Cast(info[0])) : 0); |
| 6469 imp->strictTypeCheckingVoidMethodTestInterfaceEmptyArg(testInterfaceEmptyArg
); | 6469 imp->strictTypeCheckingVoidMethodTestInterfaceEmptyArg(testInterfaceEmptyArg
); |
| 6470 } | 6470 } |
| 6471 | 6471 |
| 6472 static void strictTypeCheckingVoidMethodTestInterfaceEmptyArgMethodCallback(cons
t v8::FunctionCallbackInfo<v8::Value>& info) | 6472 static void strictTypeCheckingVoidMethodTestInterfaceEmptyArgMethodCallback(cons
t v8::FunctionCallbackInfo<v8::Value>& info) |
| 6473 { | 6473 { |
| 6474 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 6474 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 6475 TestObjectPythonV8Internal::strictTypeCheckingVoidMethodTestInterfaceEmptyAr
gMethod(info); | 6475 TestObjectPythonV8Internal::strictTypeCheckingVoidMethodTestInterfaceEmptyAr
gMethod(info); |
| 6476 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 6476 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 6477 } | 6477 } |
| 6478 | 6478 |
| 6479 static void treatReturnedNullStringAsNullStringMethodMethod(const v8::FunctionCa
llbackInfo<v8::Value>& info) | 6479 static void treatReturnedNullStringAsNullStringMethodMethod(const v8::FunctionCa
llbackInfo<v8::Value>& info) |
| 6480 { | 6480 { |
| 6481 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 6481 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 6482 v8SetReturnValueStringOrNull(info, imp->treatReturnedNullStringAsNullStringM
ethod(), info.GetIsolate()); | 6482 v8SetReturnValueStringOrNull(info, imp->treatReturnedNullStringAsNullStringM
ethod(), info.GetIsolate()); |
| 6483 } | 6483 } |
| 6484 | 6484 |
| 6485 static void treatReturnedNullStringAsNullStringMethodMethodCallback(const v8::Fu
nctionCallbackInfo<v8::Value>& info) | 6485 static void treatReturnedNullStringAsNullStringMethodMethodCallback(const v8::Fu
nctionCallbackInfo<v8::Value>& info) |
| 6486 { | 6486 { |
| 6487 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 6487 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 6488 TestObjectPythonV8Internal::treatReturnedNullStringAsNullStringMethodMethod(
info); | 6488 TestObjectPythonV8Internal::treatReturnedNullStringAsNullStringMethodMethod(
info); |
| 6489 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 6489 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 6490 } | 6490 } |
| 6491 | 6491 |
| 6492 static void treatReturnedNullStringAsUndefinedStringMethodMethod(const v8::Funct
ionCallbackInfo<v8::Value>& info) | 6492 static void treatReturnedNullStringAsUndefinedStringMethodMethod(const v8::Funct
ionCallbackInfo<v8::Value>& info) |
| 6493 { | 6493 { |
| 6494 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 6494 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 6495 v8SetReturnValueStringOrUndefined(info, imp->treatReturnedNullStringAsUndefi
nedStringMethod(), info.GetIsolate()); | 6495 v8SetReturnValueStringOrUndefined(info, imp->treatReturnedNullStringAsUndefi
nedStringMethod(), info.GetIsolate()); |
| 6496 } | 6496 } |
| 6497 | 6497 |
| 6498 static void treatReturnedNullStringAsUndefinedStringMethodMethodCallback(const v
8::FunctionCallbackInfo<v8::Value>& info) | 6498 static void treatReturnedNullStringAsUndefinedStringMethodMethodCallback(const v
8::FunctionCallbackInfo<v8::Value>& info) |
| 6499 { | 6499 { |
| 6500 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 6500 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 6501 TestObjectPythonV8Internal::treatReturnedNullStringAsUndefinedStringMethodMe
thod(info); | 6501 TestObjectPythonV8Internal::treatReturnedNullStringAsUndefinedStringMethodMe
thod(info); |
| 6502 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 6502 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 6503 } | 6503 } |
| 6504 | 6504 |
| 6505 static void unforgeableVoidMethodMethod(const v8::FunctionCallbackInfo<v8::Value
>& info) | 6505 static void unforgeableVoidMethodMethod(const v8::FunctionCallbackInfo<v8::Value
>& info) |
| 6506 { | 6506 { |
| 6507 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); | 6507 TestObjectPython* imp = V8TestObjectPython::toNative(info.Holder()); |
| 6508 imp->unforgeableVoidMethod(); | 6508 imp->unforgeableVoidMethod(); |
| 6509 } | 6509 } |
| 6510 | 6510 |
| 6511 static void unforgeableVoidMethodMethodCallback(const v8::FunctionCallbackInfo<v
8::Value>& info) | 6511 static void unforgeableVoidMethodMethodCallback(const v8::FunctionCallbackInfo<v
8::Value>& info) |
| 6512 { | 6512 { |
| 6513 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 6513 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 6514 TestObjectPythonV8Internal::unforgeableVoidMethodMethod(info); | 6514 TestObjectPythonV8Internal::unforgeableVoidMethodMethod(info); |
| 6515 TRACE_EVENT_SET_SAMPLING_STATE("V8", "Execution"); | 6515 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 6516 } | 6516 } |
| 6517 | 6517 |
| 6518 } // namespace TestObjectPythonV8Internal | 6518 } // namespace TestObjectPythonV8Internal |
| 6519 | 6519 |
| 6520 static const V8DOMConfiguration::AttributeConfiguration V8TestObjectPythonAttrib
utes[] = { | 6520 static const V8DOMConfiguration::AttributeConfiguration V8TestObjectPythonAttrib
utes[] = { |
| 6521 {"readonlyStringAttribute", TestObjectPythonV8Internal::readonlyStringAttrib
uteAttributeGetterCallback, 0, 0, 0, 0, static_cast<v8::AccessControl>(v8::DEFAU
LT), static_cast<v8::PropertyAttribute>(v8::None), 0 /* on instance */}, | 6521 {"readonlyStringAttribute", TestObjectPythonV8Internal::readonlyStringAttrib
uteAttributeGetterCallback, 0, 0, 0, 0, static_cast<v8::AccessControl>(v8::DEFAU
LT), static_cast<v8::PropertyAttribute>(v8::None), 0 /* on instance */}, |
| 6522 {"readonlyTestInterfaceEmptyAttribute", TestObjectPythonV8Internal::readonly
TestInterfaceEmptyAttributeAttributeGetterCallback, 0, 0, 0, 0, static_cast<v8::
AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::None), 0 /*
on instance */}, | 6522 {"readonlyTestInterfaceEmptyAttribute", TestObjectPythonV8Internal::readonly
TestInterfaceEmptyAttributeAttributeGetterCallback, 0, 0, 0, 0, static_cast<v8::
AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::None), 0 /*
on instance */}, |
| 6523 {"readonlyLongAttribute", TestObjectPythonV8Internal::readonlyLongAttributeA
ttributeGetterCallback, 0, 0, 0, 0, static_cast<v8::AccessControl>(v8::DEFAULT),
static_cast<v8::PropertyAttribute>(v8::None), 0 /* on instance */}, | 6523 {"readonlyLongAttribute", TestObjectPythonV8Internal::readonlyLongAttributeA
ttributeGetterCallback, 0, 0, 0, 0, static_cast<v8::AccessControl>(v8::DEFAULT),
static_cast<v8::PropertyAttribute>(v8::None), 0 /* on instance */}, |
| 6524 {"dateAttribute", TestObjectPythonV8Internal::dateAttributeAttributeGetterCa
llback, TestObjectPythonV8Internal::dateAttributeAttributeSetterCallback, 0, 0,
0, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribut
e>(v8::None), 0 /* on instance */}, | 6524 {"dateAttribute", TestObjectPythonV8Internal::dateAttributeAttributeGetterCa
llback, TestObjectPythonV8Internal::dateAttributeAttributeSetterCallback, 0, 0,
0, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribut
e>(v8::None), 0 /* on instance */}, |
| 6525 {"stringAttribute", TestObjectPythonV8Internal::stringAttributeAttributeGett
erCallback, TestObjectPythonV8Internal::stringAttributeAttributeSetterCallback,
0, 0, 0, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAt
tribute>(v8::None), 0 /* on instance */}, | 6525 {"stringAttribute", TestObjectPythonV8Internal::stringAttributeAttributeGett
erCallback, TestObjectPythonV8Internal::stringAttributeAttributeSetterCallback,
0, 0, 0, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAt
tribute>(v8::None), 0 /* on instance */}, |
| (...skipping 437 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 6963 fromInternalPointer(object)->deref(); | 6963 fromInternalPointer(object)->deref(); |
| 6964 } | 6964 } |
| 6965 | 6965 |
| 6966 template<> | 6966 template<> |
| 6967 v8::Handle<v8::Value> toV8NoInline(TestObjectPython* impl, v8::Handle<v8::Object
> creationContext, v8::Isolate* isolate) | 6967 v8::Handle<v8::Value> toV8NoInline(TestObjectPython* impl, v8::Handle<v8::Object
> creationContext, v8::Isolate* isolate) |
| 6968 { | 6968 { |
| 6969 return toV8(impl, creationContext, isolate); | 6969 return toV8(impl, creationContext, isolate); |
| 6970 } | 6970 } |
| 6971 | 6971 |
| 6972 } // namespace WebCore | 6972 } // namespace WebCore |
| OLD | NEW |