OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 // This file has been auto-generated by code_generator_v8.py. DO NOT MODIFY! | 5 // This file has been auto-generated by code_generator_v8.py. DO NOT MODIFY! |
6 | 6 |
7 #include "config.h" | 7 #include "config.h" |
8 #include "V8TestObject.h" | 8 #include "V8TestObject.h" |
9 | 9 |
10 #include "HTMLNames.h" | 10 #include "HTMLNames.h" |
(...skipping 4029 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4040 impl->setSetterCallWithExecutionContextStringAttribute(scriptContext, cppVal
ue); | 4040 impl->setSetterCallWithExecutionContextStringAttribute(scriptContext, cppVal
ue); |
4041 } | 4041 } |
4042 | 4042 |
4043 static void setterCallWithExecutionContextStringAttributeAttributeSetterCallback
(v8::Local<v8::String>, v8::Local<v8::Value> v8Value, const v8::PropertyCallback
Info<void>& info) | 4043 static void setterCallWithExecutionContextStringAttributeAttributeSetterCallback
(v8::Local<v8::String>, v8::Local<v8::Value> v8Value, const v8::PropertyCallback
Info<void>& info) |
4044 { | 4044 { |
4045 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 4045 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
4046 TestObjectV8Internal::setterCallWithExecutionContextStringAttributeAttribute
Setter(v8Value, info); | 4046 TestObjectV8Internal::setterCallWithExecutionContextStringAttributeAttribute
Setter(v8Value, info); |
4047 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); | 4047 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
4048 } | 4048 } |
4049 | 4049 |
4050 static void strictTypeCheckingInterfaceNullableStringFloatAttributeAttributeGett
er(const v8::PropertyCallbackInfo<v8::Value>& info) | 4050 static void treatNullAsNullStringStringAttributeAttributeGetter(const v8::Proper
tyCallbackInfo<v8::Value>& info) |
4051 { | 4051 { |
4052 v8::Handle<v8::Object> holder = info.Holder(); | 4052 v8::Handle<v8::Object> holder = info.Holder(); |
4053 TestObject* impl = V8TestObject::toNative(holder); | 4053 TestObject* impl = V8TestObject::toNative(holder); |
4054 v8SetReturnValue(info, impl->strictTypeCheckingInterfaceNullableStringFloatA
ttribute()); | 4054 v8SetReturnValueString(info, impl->treatNullAsNullStringStringAttribute(), i
nfo.GetIsolate()); |
4055 } | 4055 } |
4056 | 4056 |
4057 static void strictTypeCheckingInterfaceNullableStringFloatAttributeAttributeGett
erCallback(v8::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& inf
o) | 4057 static void treatNullAsNullStringStringAttributeAttributeGetterCallback(v8::Loca
l<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) |
4058 { | 4058 { |
4059 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 4059 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
4060 TestObjectV8Internal::strictTypeCheckingInterfaceNullableStringFloatAttribut
eAttributeGetter(info); | 4060 TestObjectV8Internal::treatNullAsNullStringStringAttributeAttributeGetter(in
fo); |
4061 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); | 4061 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
4062 } | 4062 } |
4063 | 4063 |
4064 static void strictTypeCheckingInterfaceNullableStringFloatAttributeAttributeSett
er(v8::Local<v8::Value> v8Value, const v8::PropertyCallbackInfo<void>& info) | 4064 static void treatNullAsNullStringStringAttributeAttributeSetter(v8::Local<v8::Va
lue> v8Value, const v8::PropertyCallbackInfo<void>& info) |
| 4065 { |
| 4066 v8::Handle<v8::Object> holder = info.Holder(); |
| 4067 TestObject* impl = V8TestObject::toNative(holder); |
| 4068 TOSTRING_VOID(V8StringResource<WithNullCheck>, cppValue, v8Value); |
| 4069 impl->setTreatNullAsNullStringStringAttribute(cppValue); |
| 4070 } |
| 4071 |
| 4072 static void treatNullAsNullStringStringAttributeAttributeSetterCallback(v8::Loca
l<v8::String>, v8::Local<v8::Value> v8Value, const v8::PropertyCallbackInfo<void
>& info) |
| 4073 { |
| 4074 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 4075 TestObjectV8Internal::treatNullAsNullStringStringAttributeAttributeSetter(v8
Value, info); |
| 4076 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4077 } |
| 4078 |
| 4079 static void treatReturnedNullStringAsNullStringAttributeAttributeGetter(const v8
::PropertyCallbackInfo<v8::Value>& info) |
| 4080 { |
| 4081 v8::Handle<v8::Object> holder = info.Holder(); |
| 4082 TestObject* impl = V8TestObject::toNative(holder); |
| 4083 v8SetReturnValueStringOrNull(info, impl->treatReturnedNullStringAsNullString
Attribute(), info.GetIsolate()); |
| 4084 } |
| 4085 |
| 4086 static void treatReturnedNullStringAsNullStringAttributeAttributeGetterCallback(
v8::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 4087 { |
| 4088 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 4089 TestObjectV8Internal::treatReturnedNullStringAsNullStringAttributeAttributeG
etter(info); |
| 4090 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4091 } |
| 4092 |
| 4093 static void treatReturnedNullStringAsNullStringAttributeAttributeSetter(v8::Loca
l<v8::Value> v8Value, const v8::PropertyCallbackInfo<void>& info) |
| 4094 { |
| 4095 v8::Handle<v8::Object> holder = info.Holder(); |
| 4096 TestObject* impl = V8TestObject::toNative(holder); |
| 4097 TOSTRING_VOID(V8StringResource<>, cppValue, v8Value); |
| 4098 impl->setTreatReturnedNullStringAsNullStringAttribute(cppValue); |
| 4099 } |
| 4100 |
| 4101 static void treatReturnedNullStringAsNullStringAttributeAttributeSetterCallback(
v8::Local<v8::String>, v8::Local<v8::Value> v8Value, const v8::PropertyCallbackI
nfo<void>& info) |
| 4102 { |
| 4103 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 4104 TestObjectV8Internal::treatReturnedNullStringAsNullStringAttributeAttributeS
etter(v8Value, info); |
| 4105 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4106 } |
| 4107 |
| 4108 static void treatReturnedNullStringAsUndefinedStringAttributeAttributeGetter(con
st v8::PropertyCallbackInfo<v8::Value>& info) |
| 4109 { |
| 4110 v8::Handle<v8::Object> holder = info.Holder(); |
| 4111 TestObject* impl = V8TestObject::toNative(holder); |
| 4112 v8SetReturnValueStringOrUndefined(info, impl->treatReturnedNullStringAsUndef
inedStringAttribute(), info.GetIsolate()); |
| 4113 } |
| 4114 |
| 4115 static void treatReturnedNullStringAsUndefinedStringAttributeAttributeGetterCall
back(v8::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 4116 { |
| 4117 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 4118 TestObjectV8Internal::treatReturnedNullStringAsUndefinedStringAttributeAttri
buteGetter(info); |
| 4119 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4120 } |
| 4121 |
| 4122 static void treatReturnedNullStringAsUndefinedStringAttributeAttributeSetter(v8:
:Local<v8::Value> v8Value, const v8::PropertyCallbackInfo<void>& info) |
| 4123 { |
| 4124 v8::Handle<v8::Object> holder = info.Holder(); |
| 4125 TestObject* impl = V8TestObject::toNative(holder); |
| 4126 TOSTRING_VOID(V8StringResource<>, cppValue, v8Value); |
| 4127 impl->setTreatReturnedNullStringAsUndefinedStringAttribute(cppValue); |
| 4128 } |
| 4129 |
| 4130 static void treatReturnedNullStringAsUndefinedStringAttributeAttributeSetterCall
back(v8::Local<v8::String>, v8::Local<v8::Value> v8Value, const v8::PropertyCall
backInfo<void>& info) |
| 4131 { |
| 4132 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
| 4133 TestObjectV8Internal::treatReturnedNullStringAsUndefinedStringAttributeAttri
buteSetter(v8Value, info); |
| 4134 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4135 } |
| 4136 |
| 4137 static void typeCheckingInterfaceNullableStringFloatAttributeAttributeGetter(con
st v8::PropertyCallbackInfo<v8::Value>& info) |
| 4138 { |
| 4139 v8::Handle<v8::Object> holder = info.Holder(); |
| 4140 TestObject* impl = V8TestObject::toNative(holder); |
| 4141 v8SetReturnValue(info, impl->typeCheckingInterfaceNullableStringFloatAttribu
te()); |
| 4142 } |
| 4143 |
| 4144 static void typeCheckingInterfaceNullableStringFloatAttributeAttributeGetterCall
back(v8::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) |
| 4145 { |
| 4146 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
| 4147 TestObjectV8Internal::typeCheckingInterfaceNullableStringFloatAttributeAttri
buteGetter(info); |
| 4148 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 4149 } |
| 4150 |
| 4151 static void typeCheckingInterfaceNullableStringFloatAttributeAttributeSetter(v8:
:Local<v8::Value> v8Value, const v8::PropertyCallbackInfo<void>& info) |
4065 { | 4152 { |
4066 v8::Handle<v8::Object> holder = info.Holder(); | 4153 v8::Handle<v8::Object> holder = info.Holder(); |
4067 TestObject* impl = V8TestObject::toNative(holder); | 4154 TestObject* impl = V8TestObject::toNative(holder); |
4068 TONATIVE_VOID(float, cppValue, static_cast<float>(v8Value->NumberValue())); | 4155 TONATIVE_VOID(float, cppValue, static_cast<float>(v8Value->NumberValue())); |
4069 impl->setStrictTypeCheckingInterfaceNullableStringFloatAttribute(cppValue); | 4156 impl->setTypeCheckingInterfaceNullableStringFloatAttribute(cppValue); |
4070 } | 4157 } |
4071 | 4158 |
4072 static void strictTypeCheckingInterfaceNullableStringFloatAttributeAttributeSett
erCallback(v8::Local<v8::String>, v8::Local<v8::Value> v8Value, const v8::Proper
tyCallbackInfo<void>& info) | 4159 static void typeCheckingInterfaceNullableStringFloatAttributeAttributeSetterCall
back(v8::Local<v8::String>, v8::Local<v8::Value> v8Value, const v8::PropertyCall
backInfo<void>& info) |
4073 { | 4160 { |
4074 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 4161 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
4075 TestObjectV8Internal::strictTypeCheckingInterfaceNullableStringFloatAttribut
eAttributeSetter(v8Value, info); | 4162 TestObjectV8Internal::typeCheckingInterfaceNullableStringFloatAttributeAttri
buteSetter(v8Value, info); |
4076 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); | 4163 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
4077 } | 4164 } |
4078 | 4165 |
4079 static void strictTypeCheckingInterfaceTestInterfaceAttributeAttributeGetter(con
st v8::PropertyCallbackInfo<v8::Value>& info) | 4166 static void typeCheckingInterfaceTestInterfaceAttributeAttributeGetter(const v8:
:PropertyCallbackInfo<v8::Value>& info) |
4080 { | 4167 { |
4081 v8::Handle<v8::Object> holder = info.Holder(); | 4168 v8::Handle<v8::Object> holder = info.Holder(); |
4082 TestObject* impl = V8TestObject::toNative(holder); | 4169 TestObject* impl = V8TestObject::toNative(holder); |
4083 v8SetReturnValueFast(info, WTF::getPtr(impl->strictTypeCheckingInterfaceTest
InterfaceAttribute()), impl); | 4170 v8SetReturnValueFast(info, WTF::getPtr(impl->typeCheckingInterfaceTestInterf
aceAttribute()), impl); |
4084 } | 4171 } |
4085 | 4172 |
4086 static void strictTypeCheckingInterfaceTestInterfaceAttributeAttributeGetterCall
back(v8::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) | 4173 static void typeCheckingInterfaceTestInterfaceAttributeAttributeGetterCallback(v
8::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) |
4087 { | 4174 { |
4088 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 4175 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
4089 TestObjectV8Internal::strictTypeCheckingInterfaceTestInterfaceAttributeAttri
buteGetter(info); | 4176 TestObjectV8Internal::typeCheckingInterfaceTestInterfaceAttributeAttributeGe
tter(info); |
4090 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); | 4177 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
4091 } | 4178 } |
4092 | 4179 |
4093 static void strictTypeCheckingInterfaceTestInterfaceAttributeAttributeSetter(v8:
:Local<v8::Value> v8Value, const v8::PropertyCallbackInfo<void>& info) | 4180 static void typeCheckingInterfaceTestInterfaceAttributeAttributeSetter(v8::Local
<v8::Value> v8Value, const v8::PropertyCallbackInfo<void>& info) |
4094 { | 4181 { |
4095 v8::Handle<v8::Object> holder = info.Holder(); | 4182 v8::Handle<v8::Object> holder = info.Holder(); |
4096 ExceptionState exceptionState(ExceptionState::SetterContext, "strictTypeChec
kingInterfaceTestInterfaceAttribute", "TestObject", holder, info.GetIsolate()); | 4183 ExceptionState exceptionState(ExceptionState::SetterContext, "typeCheckingIn
terfaceTestInterfaceAttribute", "TestObject", holder, info.GetIsolate()); |
4097 if (!V8TestInterface::hasInstance(v8Value, info.GetIsolate())) { | 4184 if (!V8TestInterface::hasInstance(v8Value, info.GetIsolate())) { |
4098 exceptionState.throwTypeError("The provided value is not of type 'TestIn
terface'."); | 4185 exceptionState.throwTypeError("The provided value is not of type 'TestIn
terface'."); |
4099 exceptionState.throwIfNeeded(); | 4186 exceptionState.throwIfNeeded(); |
4100 return; | 4187 return; |
4101 } | 4188 } |
4102 TestObject* impl = V8TestObject::toNative(holder); | 4189 TestObject* impl = V8TestObject::toNative(holder); |
4103 TONATIVE_VOID(TestInterfaceImplementation*, cppValue, V8TestInterface::toNat
iveWithTypeCheck(info.GetIsolate(), v8Value)); | 4190 TONATIVE_VOID(TestInterfaceImplementation*, cppValue, V8TestInterface::toNat
iveWithTypeCheck(info.GetIsolate(), v8Value)); |
4104 impl->setStrictTypeCheckingInterfaceTestInterfaceAttribute(WTF::getPtr(cppVa
lue)); | 4191 impl->setTypeCheckingInterfaceTestInterfaceAttribute(WTF::getPtr(cppValue)); |
4105 } | 4192 } |
4106 | 4193 |
4107 static void strictTypeCheckingInterfaceTestInterfaceAttributeAttributeSetterCall
back(v8::Local<v8::String>, v8::Local<v8::Value> v8Value, const v8::PropertyCall
backInfo<void>& info) | 4194 static void typeCheckingInterfaceTestInterfaceAttributeAttributeSetterCallback(v
8::Local<v8::String>, v8::Local<v8::Value> v8Value, const v8::PropertyCallbackIn
fo<void>& info) |
4108 { | 4195 { |
4109 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 4196 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
4110 TestObjectV8Internal::strictTypeCheckingInterfaceTestInterfaceAttributeAttri
buteSetter(v8Value, info); | 4197 TestObjectV8Internal::typeCheckingInterfaceTestInterfaceAttributeAttributeSe
tter(v8Value, info); |
4111 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); | 4198 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
4112 } | 4199 } |
4113 | 4200 |
4114 static void strictTypeCheckingNullableTestInterfaceOrNullAttributeAttributeGette
r(const v8::PropertyCallbackInfo<v8::Value>& info) | 4201 static void typeCheckingNullableTestInterfaceOrNullAttributeAttributeGetter(cons
t v8::PropertyCallbackInfo<v8::Value>& info) |
4115 { | 4202 { |
4116 v8::Handle<v8::Object> holder = info.Holder(); | 4203 v8::Handle<v8::Object> holder = info.Holder(); |
4117 TestObject* impl = V8TestObject::toNative(holder); | 4204 TestObject* impl = V8TestObject::toNative(holder); |
4118 RefPtr<TestInterfaceImplementation> v8Value = impl->strictTypeCheckingNullab
leTestInterfaceOrNullAttribute(); | 4205 RefPtr<TestInterfaceImplementation> v8Value = impl->typeCheckingNullableTest
InterfaceOrNullAttribute(); |
4119 if (!v8Value) { | 4206 if (!v8Value) { |
4120 v8SetReturnValueNull(info); | 4207 v8SetReturnValueNull(info); |
4121 return; | 4208 return; |
4122 } | 4209 } |
4123 v8SetReturnValueFast(info, WTF::getPtr(v8Value.release()), impl); | 4210 v8SetReturnValueFast(info, WTF::getPtr(v8Value.release()), impl); |
4124 } | 4211 } |
4125 | 4212 |
4126 static void strictTypeCheckingNullableTestInterfaceOrNullAttributeAttributeGette
rCallback(v8::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info
) | 4213 static void typeCheckingNullableTestInterfaceOrNullAttributeAttributeGetterCallb
ack(v8::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) |
4127 { | 4214 { |
4128 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 4215 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
4129 TestObjectV8Internal::strictTypeCheckingNullableTestInterfaceOrNullAttribute
AttributeGetter(info); | 4216 TestObjectV8Internal::typeCheckingNullableTestInterfaceOrNullAttributeAttrib
uteGetter(info); |
4130 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); | 4217 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
4131 } | 4218 } |
4132 | 4219 |
4133 static void strictTypeCheckingNullableTestInterfaceOrNullAttributeAttributeSette
r(v8::Local<v8::Value> v8Value, const v8::PropertyCallbackInfo<void>& info) | 4220 static void typeCheckingNullableTestInterfaceOrNullAttributeAttributeSetter(v8::
Local<v8::Value> v8Value, const v8::PropertyCallbackInfo<void>& info) |
4134 { | 4221 { |
4135 v8::Handle<v8::Object> holder = info.Holder(); | 4222 v8::Handle<v8::Object> holder = info.Holder(); |
4136 ExceptionState exceptionState(ExceptionState::SetterContext, "strictTypeChec
kingNullableTestInterfaceOrNullAttribute", "TestObject", holder, info.GetIsolate
()); | 4223 ExceptionState exceptionState(ExceptionState::SetterContext, "typeCheckingNu
llableTestInterfaceOrNullAttribute", "TestObject", holder, info.GetIsolate()); |
4137 TestObject* impl = V8TestObject::toNative(holder); | 4224 TestObject* impl = V8TestObject::toNative(holder); |
4138 TONATIVE_VOID(TestInterfaceImplementation*, cppValue, V8TestInterface::toNat
iveWithTypeCheck(info.GetIsolate(), v8Value)); | 4225 TONATIVE_VOID(TestInterfaceImplementation*, cppValue, V8TestInterface::toNat
iveWithTypeCheck(info.GetIsolate(), v8Value)); |
4139 impl->setStrictTypeCheckingNullableTestInterfaceOrNullAttribute(WTF::getPtr(
cppValue)); | 4226 impl->setTypeCheckingNullableTestInterfaceOrNullAttribute(WTF::getPtr(cppVal
ue)); |
4140 } | 4227 } |
4141 | 4228 |
4142 static void strictTypeCheckingNullableTestInterfaceOrNullAttributeAttributeSette
rCallback(v8::Local<v8::String>, v8::Local<v8::Value> v8Value, const v8::Propert
yCallbackInfo<void>& info) | 4229 static void typeCheckingNullableTestInterfaceOrNullAttributeAttributeSetterCallb
ack(v8::Local<v8::String>, v8::Local<v8::Value> v8Value, const v8::PropertyCallb
ackInfo<void>& info) |
4143 { | 4230 { |
4144 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 4231 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
4145 TestObjectV8Internal::strictTypeCheckingNullableTestInterfaceOrNullAttribute
AttributeSetter(v8Value, info); | 4232 TestObjectV8Internal::typeCheckingNullableTestInterfaceOrNullAttributeAttrib
uteSetter(v8Value, info); |
4146 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); | 4233 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
4147 } | 4234 } |
4148 | 4235 |
4149 static void strictTypeCheckingInterfaceNullableTestInterfaceOrNullAttributeAttri
buteGetter(const v8::PropertyCallbackInfo<v8::Value>& info) | 4236 static void typeCheckingInterfaceNullableTestInterfaceOrNullAttributeAttributeGe
tter(const v8::PropertyCallbackInfo<v8::Value>& info) |
4150 { | 4237 { |
4151 v8::Handle<v8::Object> holder = info.Holder(); | 4238 v8::Handle<v8::Object> holder = info.Holder(); |
4152 TestObject* impl = V8TestObject::toNative(holder); | 4239 TestObject* impl = V8TestObject::toNative(holder); |
4153 RefPtr<TestInterfaceImplementation> v8Value = impl->strictTypeCheckingInterf
aceNullableTestInterfaceOrNullAttribute(); | 4240 RefPtr<TestInterfaceImplementation> v8Value = impl->typeCheckingInterfaceNul
lableTestInterfaceOrNullAttribute(); |
4154 if (!v8Value) { | 4241 if (!v8Value) { |
4155 v8SetReturnValueNull(info); | 4242 v8SetReturnValueNull(info); |
4156 return; | 4243 return; |
4157 } | 4244 } |
4158 v8SetReturnValueFast(info, WTF::getPtr(v8Value.release()), impl); | 4245 v8SetReturnValueFast(info, WTF::getPtr(v8Value.release()), impl); |
4159 } | 4246 } |
4160 | 4247 |
4161 static void strictTypeCheckingInterfaceNullableTestInterfaceOrNullAttributeAttri
buteGetterCallback(v8::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Val
ue>& info) | 4248 static void typeCheckingInterfaceNullableTestInterfaceOrNullAttributeAttributeGe
tterCallback(v8::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& i
nfo) |
4162 { | 4249 { |
4163 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 4250 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
4164 TestObjectV8Internal::strictTypeCheckingInterfaceNullableTestInterfaceOrNull
AttributeAttributeGetter(info); | 4251 TestObjectV8Internal::typeCheckingInterfaceNullableTestInterfaceOrNullAttrib
uteAttributeGetter(info); |
4165 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); | 4252 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
4166 } | 4253 } |
4167 | 4254 |
4168 static void strictTypeCheckingInterfaceNullableTestInterfaceOrNullAttributeAttri
buteSetter(v8::Local<v8::Value> v8Value, const v8::PropertyCallbackInfo<void>& i
nfo) | 4255 static void typeCheckingInterfaceNullableTestInterfaceOrNullAttributeAttributeSe
tter(v8::Local<v8::Value> v8Value, const v8::PropertyCallbackInfo<void>& info) |
4169 { | 4256 { |
4170 v8::Handle<v8::Object> holder = info.Holder(); | 4257 v8::Handle<v8::Object> holder = info.Holder(); |
4171 ExceptionState exceptionState(ExceptionState::SetterContext, "strictTypeChec
kingInterfaceNullableTestInterfaceOrNullAttribute", "TestObject", holder, info.G
etIsolate()); | 4258 ExceptionState exceptionState(ExceptionState::SetterContext, "typeCheckingIn
terfaceNullableTestInterfaceOrNullAttribute", "TestObject", holder, info.GetIsol
ate()); |
4172 if (!isUndefinedOrNull(v8Value) && !V8TestInterface::hasInstance(v8Value, in
fo.GetIsolate())) { | 4259 if (!isUndefinedOrNull(v8Value) && !V8TestInterface::hasInstance(v8Value, in
fo.GetIsolate())) { |
4173 exceptionState.throwTypeError("The provided value is not of type 'TestIn
terface'."); | 4260 exceptionState.throwTypeError("The provided value is not of type 'TestIn
terface'."); |
4174 exceptionState.throwIfNeeded(); | 4261 exceptionState.throwIfNeeded(); |
4175 return; | 4262 return; |
4176 } | 4263 } |
4177 TestObject* impl = V8TestObject::toNative(holder); | 4264 TestObject* impl = V8TestObject::toNative(holder); |
4178 TONATIVE_VOID(TestInterfaceImplementation*, cppValue, V8TestInterface::toNat
iveWithTypeCheck(info.GetIsolate(), v8Value)); | 4265 TONATIVE_VOID(TestInterfaceImplementation*, cppValue, V8TestInterface::toNat
iveWithTypeCheck(info.GetIsolate(), v8Value)); |
4179 impl->setStrictTypeCheckingInterfaceNullableTestInterfaceOrNullAttribute(WTF
::getPtr(cppValue)); | 4266 impl->setTypeCheckingInterfaceNullableTestInterfaceOrNullAttribute(WTF::getP
tr(cppValue)); |
4180 } | 4267 } |
4181 | 4268 |
4182 static void strictTypeCheckingInterfaceNullableTestInterfaceOrNullAttributeAttri
buteSetterCallback(v8::Local<v8::String>, v8::Local<v8::Value> v8Value, const v8
::PropertyCallbackInfo<void>& info) | 4269 static void typeCheckingInterfaceNullableTestInterfaceOrNullAttributeAttributeSe
tterCallback(v8::Local<v8::String>, v8::Local<v8::Value> v8Value, const v8::Prop
ertyCallbackInfo<void>& info) |
4183 { | 4270 { |
4184 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | 4271 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); |
4185 TestObjectV8Internal::strictTypeCheckingInterfaceNullableTestInterfaceOrNull
AttributeAttributeSetter(v8Value, info); | 4272 TestObjectV8Internal::typeCheckingInterfaceNullableTestInterfaceOrNullAttrib
uteAttributeSetter(v8Value, info); |
4186 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); | 4273 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
4187 } | 4274 } |
4188 | 4275 |
4189 static void treatNullAsNullStringStringAttributeAttributeGetter(const v8::Proper
tyCallbackInfo<v8::Value>& info) | |
4190 { | |
4191 v8::Handle<v8::Object> holder = info.Holder(); | |
4192 TestObject* impl = V8TestObject::toNative(holder); | |
4193 v8SetReturnValueString(info, impl->treatNullAsNullStringStringAttribute(), i
nfo.GetIsolate()); | |
4194 } | |
4195 | |
4196 static void treatNullAsNullStringStringAttributeAttributeGetterCallback(v8::Loca
l<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) | |
4197 { | |
4198 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | |
4199 TestObjectV8Internal::treatNullAsNullStringStringAttributeAttributeGetter(in
fo); | |
4200 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); | |
4201 } | |
4202 | |
4203 static void treatNullAsNullStringStringAttributeAttributeSetter(v8::Local<v8::Va
lue> v8Value, const v8::PropertyCallbackInfo<void>& info) | |
4204 { | |
4205 v8::Handle<v8::Object> holder = info.Holder(); | |
4206 TestObject* impl = V8TestObject::toNative(holder); | |
4207 TOSTRING_VOID(V8StringResource<WithNullCheck>, cppValue, v8Value); | |
4208 impl->setTreatNullAsNullStringStringAttribute(cppValue); | |
4209 } | |
4210 | |
4211 static void treatNullAsNullStringStringAttributeAttributeSetterCallback(v8::Loca
l<v8::String>, v8::Local<v8::Value> v8Value, const v8::PropertyCallbackInfo<void
>& info) | |
4212 { | |
4213 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | |
4214 TestObjectV8Internal::treatNullAsNullStringStringAttributeAttributeSetter(v8
Value, info); | |
4215 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); | |
4216 } | |
4217 | |
4218 static void treatReturnedNullStringAsNullStringAttributeAttributeGetter(const v8
::PropertyCallbackInfo<v8::Value>& info) | |
4219 { | |
4220 v8::Handle<v8::Object> holder = info.Holder(); | |
4221 TestObject* impl = V8TestObject::toNative(holder); | |
4222 v8SetReturnValueStringOrNull(info, impl->treatReturnedNullStringAsNullString
Attribute(), info.GetIsolate()); | |
4223 } | |
4224 | |
4225 static void treatReturnedNullStringAsNullStringAttributeAttributeGetterCallback(
v8::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) | |
4226 { | |
4227 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | |
4228 TestObjectV8Internal::treatReturnedNullStringAsNullStringAttributeAttributeG
etter(info); | |
4229 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); | |
4230 } | |
4231 | |
4232 static void treatReturnedNullStringAsNullStringAttributeAttributeSetter(v8::Loca
l<v8::Value> v8Value, const v8::PropertyCallbackInfo<void>& info) | |
4233 { | |
4234 v8::Handle<v8::Object> holder = info.Holder(); | |
4235 TestObject* impl = V8TestObject::toNative(holder); | |
4236 TOSTRING_VOID(V8StringResource<>, cppValue, v8Value); | |
4237 impl->setTreatReturnedNullStringAsNullStringAttribute(cppValue); | |
4238 } | |
4239 | |
4240 static void treatReturnedNullStringAsNullStringAttributeAttributeSetterCallback(
v8::Local<v8::String>, v8::Local<v8::Value> v8Value, const v8::PropertyCallbackI
nfo<void>& info) | |
4241 { | |
4242 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | |
4243 TestObjectV8Internal::treatReturnedNullStringAsNullStringAttributeAttributeS
etter(v8Value, info); | |
4244 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); | |
4245 } | |
4246 | |
4247 static void treatReturnedNullStringAsUndefinedStringAttributeAttributeGetter(con
st v8::PropertyCallbackInfo<v8::Value>& info) | |
4248 { | |
4249 v8::Handle<v8::Object> holder = info.Holder(); | |
4250 TestObject* impl = V8TestObject::toNative(holder); | |
4251 v8SetReturnValueStringOrUndefined(info, impl->treatReturnedNullStringAsUndef
inedStringAttribute(), info.GetIsolate()); | |
4252 } | |
4253 | |
4254 static void treatReturnedNullStringAsUndefinedStringAttributeAttributeGetterCall
back(v8::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info) | |
4255 { | |
4256 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | |
4257 TestObjectV8Internal::treatReturnedNullStringAsUndefinedStringAttributeAttri
buteGetter(info); | |
4258 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); | |
4259 } | |
4260 | |
4261 static void treatReturnedNullStringAsUndefinedStringAttributeAttributeSetter(v8:
:Local<v8::Value> v8Value, const v8::PropertyCallbackInfo<void>& info) | |
4262 { | |
4263 v8::Handle<v8::Object> holder = info.Holder(); | |
4264 TestObject* impl = V8TestObject::toNative(holder); | |
4265 TOSTRING_VOID(V8StringResource<>, cppValue, v8Value); | |
4266 impl->setTreatReturnedNullStringAsUndefinedStringAttribute(cppValue); | |
4267 } | |
4268 | |
4269 static void treatReturnedNullStringAsUndefinedStringAttributeAttributeSetterCall
back(v8::Local<v8::String>, v8::Local<v8::Value> v8Value, const v8::PropertyCall
backInfo<void>& info) | |
4270 { | |
4271 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter"); | |
4272 TestObjectV8Internal::treatReturnedNullStringAsUndefinedStringAttributeAttri
buteSetter(v8Value, info); | |
4273 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); | |
4274 } | |
4275 | |
4276 static void urlStringAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8:
:Value>& info) | 4276 static void urlStringAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8:
:Value>& info) |
4277 { | 4277 { |
4278 v8::Handle<v8::Object> holder = info.Holder(); | 4278 v8::Handle<v8::Object> holder = info.Holder(); |
4279 TestObject* impl = V8TestObject::toNative(holder); | 4279 TestObject* impl = V8TestObject::toNative(holder); |
4280 v8SetReturnValueString(info, impl->getURLAttribute(HTMLNames::urlstringattri
buteAttr), info.GetIsolate()); | 4280 v8SetReturnValueString(info, impl->getURLAttribute(HTMLNames::urlstringattri
buteAttr), info.GetIsolate()); |
4281 } | 4281 } |
4282 | 4282 |
4283 static void urlStringAttributeAttributeGetterCallback(v8::Local<v8::String>, con
st v8::PropertyCallbackInfo<v8::Value>& info) | 4283 static void urlStringAttributeAttributeGetterCallback(v8::Local<v8::String>, con
st v8::PropertyCallbackInfo<v8::Value>& info) |
4284 { | 4284 { |
4285 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); | 4285 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter"); |
(...skipping 3514 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
7800 impl->perWorldBindingsRuntimeEnabledVoidMethod(); | 7800 impl->perWorldBindingsRuntimeEnabledVoidMethod(); |
7801 } | 7801 } |
7802 | 7802 |
7803 static void perWorldBindingsRuntimeEnabledVoidMethodMethodCallbackForMainWorld(c
onst v8::FunctionCallbackInfo<v8::Value>& info) | 7803 static void perWorldBindingsRuntimeEnabledVoidMethodMethodCallbackForMainWorld(c
onst v8::FunctionCallbackInfo<v8::Value>& info) |
7804 { | 7804 { |
7805 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 7805 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
7806 TestObjectV8Internal::perWorldBindingsRuntimeEnabledVoidMethodMethodForMainW
orld(info); | 7806 TestObjectV8Internal::perWorldBindingsRuntimeEnabledVoidMethodMethodForMainW
orld(info); |
7807 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); | 7807 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
7808 } | 7808 } |
7809 | 7809 |
7810 static void strictTypeCheckingInterfaceVoidMethodTestInterfaceEmptyArgMethod(con
st v8::FunctionCallbackInfo<v8::Value>& info) | |
7811 { | |
7812 if (UNLIKELY(info.Length() < 1)) { | |
7813 throwArityTypeErrorForMethod("strictTypeCheckingInterfaceVoidMethodTestI
nterfaceEmptyArg", "TestObject", 1, info.Length(), info.GetIsolate()); | |
7814 return; | |
7815 } | |
7816 TestObject* impl = V8TestObject::toNative(info.Holder()); | |
7817 if (info.Length() > 0 && !V8TestInterfaceEmpty::hasInstance(info[0], info.Ge
tIsolate())) { | |
7818 throwTypeError(ExceptionMessages::failedToExecute("strictTypeCheckingInt
erfaceVoidMethodTestInterfaceEmptyArg", "TestObject", "parameter 1 is not of typ
e 'TestInterfaceEmpty'."), info.GetIsolate()); | |
7819 return; | |
7820 } | |
7821 TONATIVE_VOID(TestInterfaceEmpty*, testInterfaceEmptyArg, V8TestInterfaceEmp
ty::toNativeWithTypeCheck(info.GetIsolate(), info[0])); | |
7822 impl->strictTypeCheckingInterfaceVoidMethodTestInterfaceEmptyArg(testInterfa
ceEmptyArg); | |
7823 } | |
7824 | |
7825 static void strictTypeCheckingInterfaceVoidMethodTestInterfaceEmptyArgMethodCall
back(const v8::FunctionCallbackInfo<v8::Value>& info) | |
7826 { | |
7827 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | |
7828 TestObjectV8Internal::strictTypeCheckingInterfaceVoidMethodTestInterfaceEmpt
yArgMethod(info); | |
7829 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); | |
7830 } | |
7831 | |
7832 static void strictTypeCheckingNullableVoidMethodTestInterfaceEmptyOrNullArgMetho
d(const v8::FunctionCallbackInfo<v8::Value>& info) | |
7833 { | |
7834 if (UNLIKELY(info.Length() < 1)) { | |
7835 throwArityTypeErrorForMethod("strictTypeCheckingNullableVoidMethodTestIn
terfaceEmptyOrNullArg", "TestObject", 1, info.Length(), info.GetIsolate()); | |
7836 return; | |
7837 } | |
7838 TestObject* impl = V8TestObject::toNative(info.Holder()); | |
7839 TONATIVE_VOID(TestInterfaceEmpty*, testInterfaceEmptyOrNullArg, V8TestInterf
aceEmpty::toNativeWithTypeCheck(info.GetIsolate(), info[0])); | |
7840 impl->strictTypeCheckingNullableVoidMethodTestInterfaceEmptyOrNullArg(testIn
terfaceEmptyOrNullArg); | |
7841 } | |
7842 | |
7843 static void strictTypeCheckingNullableVoidMethodTestInterfaceEmptyOrNullArgMetho
dCallback(const v8::FunctionCallbackInfo<v8::Value>& info) | |
7844 { | |
7845 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | |
7846 TestObjectV8Internal::strictTypeCheckingNullableVoidMethodTestInterfaceEmpty
OrNullArgMethod(info); | |
7847 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); | |
7848 } | |
7849 | |
7850 static void strictTypeCheckingInterfaceNullableVoidMethodTestInterfaceEmptyOrNul
lArgMethod(const v8::FunctionCallbackInfo<v8::Value>& info) | |
7851 { | |
7852 if (UNLIKELY(info.Length() < 1)) { | |
7853 throwArityTypeErrorForMethod("strictTypeCheckingInterfaceNullableVoidMet
hodTestInterfaceEmptyOrNullArg", "TestObject", 1, info.Length(), info.GetIsolate
()); | |
7854 return; | |
7855 } | |
7856 TestObject* impl = V8TestObject::toNative(info.Holder()); | |
7857 if (info.Length() > 0 && !isUndefinedOrNull(info[0]) && !V8TestInterfaceEmpt
y::hasInstance(info[0], info.GetIsolate())) { | |
7858 throwTypeError(ExceptionMessages::failedToExecute("strictTypeCheckingInt
erfaceNullableVoidMethodTestInterfaceEmptyOrNullArg", "TestObject", "parameter 1
is not of type 'TestInterfaceEmpty'."), info.GetIsolate()); | |
7859 return; | |
7860 } | |
7861 TONATIVE_VOID(TestInterfaceEmpty*, testInterfaceEmptyOrNullArg, V8TestInterf
aceEmpty::toNativeWithTypeCheck(info.GetIsolate(), info[0])); | |
7862 impl->strictTypeCheckingInterfaceNullableVoidMethodTestInterfaceEmptyOrNullA
rg(testInterfaceEmptyOrNullArg); | |
7863 } | |
7864 | |
7865 static void strictTypeCheckingInterfaceNullableVoidMethodTestInterfaceEmptyOrNul
lArgMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) | |
7866 { | |
7867 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | |
7868 TestObjectV8Internal::strictTypeCheckingInterfaceNullableVoidMethodTestInter
faceEmptyOrNullArgMethod(info); | |
7869 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); | |
7870 } | |
7871 | |
7872 static void treatReturnedNullStringAsNullStringMethodMethod(const v8::FunctionCa
llbackInfo<v8::Value>& info) | 7810 static void treatReturnedNullStringAsNullStringMethodMethod(const v8::FunctionCa
llbackInfo<v8::Value>& info) |
7873 { | 7811 { |
7874 TestObject* impl = V8TestObject::toNative(info.Holder()); | 7812 TestObject* impl = V8TestObject::toNative(info.Holder()); |
7875 v8SetReturnValueStringOrNull(info, impl->treatReturnedNullStringAsNullString
Method(), info.GetIsolate()); | 7813 v8SetReturnValueStringOrNull(info, impl->treatReturnedNullStringAsNullString
Method(), info.GetIsolate()); |
7876 } | 7814 } |
7877 | 7815 |
7878 static void treatReturnedNullStringAsNullStringMethodMethodCallback(const v8::Fu
nctionCallbackInfo<v8::Value>& info) | 7816 static void treatReturnedNullStringAsNullStringMethodMethodCallback(const v8::Fu
nctionCallbackInfo<v8::Value>& info) |
7879 { | 7817 { |
7880 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 7818 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
7881 TestObjectV8Internal::treatReturnedNullStringAsNullStringMethodMethod(info); | 7819 TestObjectV8Internal::treatReturnedNullStringAsNullStringMethodMethod(info); |
7882 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); | 7820 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
7883 } | 7821 } |
7884 | 7822 |
7885 static void treatReturnedNullStringAsUndefinedStringMethodMethod(const v8::Funct
ionCallbackInfo<v8::Value>& info) | 7823 static void treatReturnedNullStringAsUndefinedStringMethodMethod(const v8::Funct
ionCallbackInfo<v8::Value>& info) |
7886 { | 7824 { |
7887 TestObject* impl = V8TestObject::toNative(info.Holder()); | 7825 TestObject* impl = V8TestObject::toNative(info.Holder()); |
7888 v8SetReturnValueStringOrUndefined(info, impl->treatReturnedNullStringAsUndef
inedStringMethod(), info.GetIsolate()); | 7826 v8SetReturnValueStringOrUndefined(info, impl->treatReturnedNullStringAsUndef
inedStringMethod(), info.GetIsolate()); |
7889 } | 7827 } |
7890 | 7828 |
7891 static void treatReturnedNullStringAsUndefinedStringMethodMethodCallback(const v
8::FunctionCallbackInfo<v8::Value>& info) | 7829 static void treatReturnedNullStringAsUndefinedStringMethodMethodCallback(const v
8::FunctionCallbackInfo<v8::Value>& info) |
7892 { | 7830 { |
7893 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 7831 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
7894 TestObjectV8Internal::treatReturnedNullStringAsUndefinedStringMethodMethod(i
nfo); | 7832 TestObjectV8Internal::treatReturnedNullStringAsUndefinedStringMethodMethod(i
nfo); |
7895 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); | 7833 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
7896 } | 7834 } |
7897 | 7835 |
| 7836 static void typeCheckingInterfaceVoidMethodTestInterfaceEmptyArgMethod(const v8:
:FunctionCallbackInfo<v8::Value>& info) |
| 7837 { |
| 7838 if (UNLIKELY(info.Length() < 1)) { |
| 7839 throwArityTypeErrorForMethod("typeCheckingInterfaceVoidMethodTestInterfa
ceEmptyArg", "TestObject", 1, info.Length(), info.GetIsolate()); |
| 7840 return; |
| 7841 } |
| 7842 TestObject* impl = V8TestObject::toNative(info.Holder()); |
| 7843 if (info.Length() > 0 && !V8TestInterfaceEmpty::hasInstance(info[0], info.Ge
tIsolate())) { |
| 7844 throwTypeError(ExceptionMessages::failedToExecute("typeCheckingInterface
VoidMethodTestInterfaceEmptyArg", "TestObject", "parameter 1 is not of type 'Tes
tInterfaceEmpty'."), info.GetIsolate()); |
| 7845 return; |
| 7846 } |
| 7847 TONATIVE_VOID(TestInterfaceEmpty*, testInterfaceEmptyArg, V8TestInterfaceEmp
ty::toNativeWithTypeCheck(info.GetIsolate(), info[0])); |
| 7848 impl->typeCheckingInterfaceVoidMethodTestInterfaceEmptyArg(testInterfaceEmpt
yArg); |
| 7849 } |
| 7850 |
| 7851 static void typeCheckingInterfaceVoidMethodTestInterfaceEmptyArgMethodCallback(c
onst v8::FunctionCallbackInfo<v8::Value>& info) |
| 7852 { |
| 7853 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 7854 TestObjectV8Internal::typeCheckingInterfaceVoidMethodTestInterfaceEmptyArgMe
thod(info); |
| 7855 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 7856 } |
| 7857 |
| 7858 static void typeCheckingNullableVoidMethodTestInterfaceEmptyOrNullArgMethod(cons
t v8::FunctionCallbackInfo<v8::Value>& info) |
| 7859 { |
| 7860 if (UNLIKELY(info.Length() < 1)) { |
| 7861 throwArityTypeErrorForMethod("typeCheckingNullableVoidMethodTestInterfac
eEmptyOrNullArg", "TestObject", 1, info.Length(), info.GetIsolate()); |
| 7862 return; |
| 7863 } |
| 7864 TestObject* impl = V8TestObject::toNative(info.Holder()); |
| 7865 TONATIVE_VOID(TestInterfaceEmpty*, testInterfaceEmptyOrNullArg, V8TestInterf
aceEmpty::toNativeWithTypeCheck(info.GetIsolate(), info[0])); |
| 7866 impl->typeCheckingNullableVoidMethodTestInterfaceEmptyOrNullArg(testInterfac
eEmptyOrNullArg); |
| 7867 } |
| 7868 |
| 7869 static void typeCheckingNullableVoidMethodTestInterfaceEmptyOrNullArgMethodCallb
ack(const v8::FunctionCallbackInfo<v8::Value>& info) |
| 7870 { |
| 7871 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 7872 TestObjectV8Internal::typeCheckingNullableVoidMethodTestInterfaceEmptyOrNull
ArgMethod(info); |
| 7873 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 7874 } |
| 7875 |
| 7876 static void typeCheckingInterfaceNullableVoidMethodTestInterfaceEmptyOrNullArgMe
thod(const v8::FunctionCallbackInfo<v8::Value>& info) |
| 7877 { |
| 7878 if (UNLIKELY(info.Length() < 1)) { |
| 7879 throwArityTypeErrorForMethod("typeCheckingInterfaceNullableVoidMethodTes
tInterfaceEmptyOrNullArg", "TestObject", 1, info.Length(), info.GetIsolate()); |
| 7880 return; |
| 7881 } |
| 7882 TestObject* impl = V8TestObject::toNative(info.Holder()); |
| 7883 if (info.Length() > 0 && !isUndefinedOrNull(info[0]) && !V8TestInterfaceEmpt
y::hasInstance(info[0], info.GetIsolate())) { |
| 7884 throwTypeError(ExceptionMessages::failedToExecute("typeCheckingInterface
NullableVoidMethodTestInterfaceEmptyOrNullArg", "TestObject", "parameter 1 is no
t of type 'TestInterfaceEmpty'."), info.GetIsolate()); |
| 7885 return; |
| 7886 } |
| 7887 TONATIVE_VOID(TestInterfaceEmpty*, testInterfaceEmptyOrNullArg, V8TestInterf
aceEmpty::toNativeWithTypeCheck(info.GetIsolate(), info[0])); |
| 7888 impl->typeCheckingInterfaceNullableVoidMethodTestInterfaceEmptyOrNullArg(tes
tInterfaceEmptyOrNullArg); |
| 7889 } |
| 7890 |
| 7891 static void typeCheckingInterfaceNullableVoidMethodTestInterfaceEmptyOrNullArgMe
thodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
| 7892 { |
| 7893 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 7894 TestObjectV8Internal::typeCheckingInterfaceNullableVoidMethodTestInterfaceEm
ptyOrNullArgMethod(info); |
| 7895 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 7896 } |
| 7897 |
| 7898 static void typeCheckingUnrestrictedVoidMethodFloatArgDoubleArgMethod(const v8::
FunctionCallbackInfo<v8::Value>& info) |
| 7899 { |
| 7900 if (UNLIKELY(info.Length() < 2)) { |
| 7901 throwArityTypeErrorForMethod("typeCheckingUnrestrictedVoidMethodFloatArg
DoubleArg", "TestObject", 2, info.Length(), info.GetIsolate()); |
| 7902 return; |
| 7903 } |
| 7904 TestObject* impl = V8TestObject::toNative(info.Holder()); |
| 7905 TONATIVE_VOID(float, floatArg, static_cast<float>(info[0]->NumberValue())); |
| 7906 if (!std::isfinite(floatArg)) { |
| 7907 throwTypeError(ExceptionMessages::failedToExecute("typeCheckingUnrestric
tedVoidMethodFloatArgDoubleArg", "TestObject", "float parameter 1 is non-finite.
"), info.GetIsolate()); |
| 7908 return; |
| 7909 } |
| 7910 TONATIVE_VOID(double, doubleArg, static_cast<double>(info[1]->NumberValue())
); |
| 7911 if (!std::isfinite(doubleArg)) { |
| 7912 throwTypeError(ExceptionMessages::failedToExecute("typeCheckingUnrestric
tedVoidMethodFloatArgDoubleArg", "TestObject", "double parameter 2 is non-finite
."), info.GetIsolate()); |
| 7913 return; |
| 7914 } |
| 7915 impl->typeCheckingUnrestrictedVoidMethodFloatArgDoubleArg(floatArg, doubleAr
g); |
| 7916 } |
| 7917 |
| 7918 static void typeCheckingUnrestrictedVoidMethodFloatArgDoubleArgMethodCallback(co
nst v8::FunctionCallbackInfo<v8::Value>& info) |
| 7919 { |
| 7920 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
| 7921 TestObjectV8Internal::typeCheckingUnrestrictedVoidMethodFloatArgDoubleArgMet
hod(info); |
| 7922 TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution"); |
| 7923 } |
| 7924 |
7898 static void unforgeableVoidMethodMethod(const v8::FunctionCallbackInfo<v8::Value
>& info) | 7925 static void unforgeableVoidMethodMethod(const v8::FunctionCallbackInfo<v8::Value
>& info) |
7899 { | 7926 { |
7900 TestObject* impl = V8TestObject::toNative(info.Holder()); | 7927 TestObject* impl = V8TestObject::toNative(info.Holder()); |
7901 impl->unforgeableVoidMethod(); | 7928 impl->unforgeableVoidMethod(); |
7902 } | 7929 } |
7903 | 7930 |
7904 static void unforgeableVoidMethodMethodCallback(const v8::FunctionCallbackInfo<v
8::Value>& info) | 7931 static void unforgeableVoidMethodMethodCallback(const v8::FunctionCallbackInfo<v
8::Value>& info) |
7905 { | 7932 { |
7906 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); | 7933 TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod"); |
7907 TestObjectV8Internal::unforgeableVoidMethodMethod(info); | 7934 TestObjectV8Internal::unforgeableVoidMethodMethod(info); |
(...skipping 200 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
8108 {"limitedToOnlyAttribute", TestObjectV8Internal::limitedToOnlyAttributeAttri
buteGetterCallback, TestObjectV8Internal::limitedToOnlyAttributeAttributeSetterC
allback, 0, 0, 0, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::P
ropertyAttribute>(v8::None), 0 /* on instance */}, | 8135 {"limitedToOnlyAttribute", TestObjectV8Internal::limitedToOnlyAttributeAttri
buteGetterCallback, TestObjectV8Internal::limitedToOnlyAttributeAttributeSetterC
allback, 0, 0, 0, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::P
ropertyAttribute>(v8::None), 0 /* on instance */}, |
8109 {"limitedToOnlyOtherAttribute", TestObjectV8Internal::limitedToOnlyOtherAttr
ibuteAttributeGetterCallback, TestObjectV8Internal::limitedToOnlyOtherAttributeA
ttributeSetterCallback, 0, 0, 0, static_cast<v8::AccessControl>(v8::DEFAULT), st
atic_cast<v8::PropertyAttribute>(v8::None), 0 /* on instance */}, | 8136 {"limitedToOnlyOtherAttribute", TestObjectV8Internal::limitedToOnlyOtherAttr
ibuteAttributeGetterCallback, TestObjectV8Internal::limitedToOnlyOtherAttributeA
ttributeSetterCallback, 0, 0, 0, static_cast<v8::AccessControl>(v8::DEFAULT), st
atic_cast<v8::PropertyAttribute>(v8::None), 0 /* on instance */}, |
8110 {"limitedWithMissingDefaultAttribute", TestObjectV8Internal::limitedWithMiss
ingDefaultAttributeAttributeGetterCallback, TestObjectV8Internal::limitedWithMis
singDefaultAttributeAttributeSetterCallback, 0, 0, 0, static_cast<v8::AccessCont
rol>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::None), 0 /* on instanc
e */}, | 8137 {"limitedWithMissingDefaultAttribute", TestObjectV8Internal::limitedWithMiss
ingDefaultAttributeAttributeGetterCallback, TestObjectV8Internal::limitedWithMis
singDefaultAttributeAttributeSetterCallback, 0, 0, 0, static_cast<v8::AccessCont
rol>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::None), 0 /* on instanc
e */}, |
8111 {"limitedWithInvalidMissingDefaultAttribute", TestObjectV8Internal::limitedW
ithInvalidMissingDefaultAttributeAttributeGetterCallback, TestObjectV8Internal::
limitedWithInvalidMissingDefaultAttributeAttributeSetterCallback, 0, 0, 0, stati
c_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::N
one), 0 /* on instance */}, | 8138 {"limitedWithInvalidMissingDefaultAttribute", TestObjectV8Internal::limitedW
ithInvalidMissingDefaultAttributeAttributeGetterCallback, TestObjectV8Internal::
limitedWithInvalidMissingDefaultAttributeAttributeSetterCallback, 0, 0, 0, stati
c_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::N
one), 0 /* on instance */}, |
8112 {"corsSettingAttribute", TestObjectV8Internal::corsSettingAttributeAttribute
GetterCallback, 0, 0, 0, 0, static_cast<v8::AccessControl>(v8::DEFAULT), static_
cast<v8::PropertyAttribute>(v8::None), 0 /* on instance */}, | 8139 {"corsSettingAttribute", TestObjectV8Internal::corsSettingAttributeAttribute
GetterCallback, 0, 0, 0, 0, static_cast<v8::AccessControl>(v8::DEFAULT), static_
cast<v8::PropertyAttribute>(v8::None), 0 /* on instance */}, |
8113 {"limitedWithEmptyMissingInvalidAttribute", TestObjectV8Internal::limitedWit
hEmptyMissingInvalidAttributeAttributeGetterCallback, 0, 0, 0, 0, static_cast<v8
::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::None), 0 /
* on instance */}, | 8140 {"limitedWithEmptyMissingInvalidAttribute", TestObjectV8Internal::limitedWit
hEmptyMissingInvalidAttributeAttributeGetterCallback, 0, 0, 0, 0, static_cast<v8
::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::None), 0 /
* on instance */}, |
8114 {"replaceableReadonlyLongAttribute", TestObjectV8Internal::replaceableReadon
lyLongAttributeAttributeGetterCallback, TestObjectV8Internal::TestObjectReplacea
bleAttributeSetterCallback, 0, 0, 0, static_cast<v8::AccessControl>(v8::DEFAULT)
, static_cast<v8::PropertyAttribute>(v8::None), 0 /* on instance */}, | 8141 {"replaceableReadonlyLongAttribute", TestObjectV8Internal::replaceableReadon
lyLongAttributeAttributeGetterCallback, TestObjectV8Internal::TestObjectReplacea
bleAttributeSetterCallback, 0, 0, 0, static_cast<v8::AccessControl>(v8::DEFAULT)
, static_cast<v8::PropertyAttribute>(v8::None), 0 /* on instance */}, |
8115 {"locationReplaceable", TestObjectV8Internal::locationReplaceableAttributeGe
tterCallback, TestObjectV8Internal::locationReplaceableAttributeSetterCallback,
0, 0, 0, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAt
tribute>(v8::None), 0 /* on instance */}, | 8142 {"locationReplaceable", TestObjectV8Internal::locationReplaceableAttributeGe
tterCallback, TestObjectV8Internal::locationReplaceableAttributeSetterCallback,
0, 0, 0, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAt
tribute>(v8::None), 0 /* on instance */}, |
8116 {"setterCallWithActiveWindowAndFirstWindowStringAttribute", TestObjectV8Inte
rnal::setterCallWithActiveWindowAndFirstWindowStringAttributeAttributeGetterCall
back, TestObjectV8Internal::setterCallWithActiveWindowAndFirstWindowStringAttrib
uteAttributeSetterCallback, 0, 0, 0, static_cast<v8::AccessControl>(v8::DEFAULT)
, static_cast<v8::PropertyAttribute>(v8::None), 0 /* on instance */}, | 8143 {"setterCallWithActiveWindowAndFirstWindowStringAttribute", TestObjectV8Inte
rnal::setterCallWithActiveWindowAndFirstWindowStringAttributeAttributeGetterCall
back, TestObjectV8Internal::setterCallWithActiveWindowAndFirstWindowStringAttrib
uteAttributeSetterCallback, 0, 0, 0, static_cast<v8::AccessControl>(v8::DEFAULT)
, static_cast<v8::PropertyAttribute>(v8::None), 0 /* on instance */}, |
8117 {"setterCallWithExecutionContextStringAttribute", TestObjectV8Internal::sett
erCallWithExecutionContextStringAttributeAttributeGetterCallback, TestObjectV8In
ternal::setterCallWithExecutionContextStringAttributeAttributeSetterCallback, 0,
0, 0, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttr
ibute>(v8::None), 0 /* on instance */}, | 8144 {"setterCallWithExecutionContextStringAttribute", TestObjectV8Internal::sett
erCallWithExecutionContextStringAttributeAttributeGetterCallback, TestObjectV8In
ternal::setterCallWithExecutionContextStringAttributeAttributeSetterCallback, 0,
0, 0, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttr
ibute>(v8::None), 0 /* on instance */}, |
8118 {"strictTypeCheckingInterfaceNullableStringFloatAttribute", TestObjectV8Inte
rnal::strictTypeCheckingInterfaceNullableStringFloatAttributeAttributeGetterCall
back, TestObjectV8Internal::strictTypeCheckingInterfaceNullableStringFloatAttrib
uteAttributeSetterCallback, 0, 0, 0, static_cast<v8::AccessControl>(v8::DEFAULT)
, static_cast<v8::PropertyAttribute>(v8::None), 0 /* on instance */}, | |
8119 {"strictTypeCheckingInterfaceTestInterfaceAttribute", TestObjectV8Internal::
strictTypeCheckingInterfaceTestInterfaceAttributeAttributeGetterCallback, TestOb
jectV8Internal::strictTypeCheckingInterfaceTestInterfaceAttributeAttributeSetter
Callback, 0, 0, 0, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::
PropertyAttribute>(v8::None), 0 /* on instance */}, | |
8120 {"strictTypeCheckingNullableTestInterfaceOrNullAttribute", TestObjectV8Inter
nal::strictTypeCheckingNullableTestInterfaceOrNullAttributeAttributeGetterCallba
ck, TestObjectV8Internal::strictTypeCheckingNullableTestInterfaceOrNullAttribute
AttributeSetterCallback, 0, 0, 0, static_cast<v8::AccessControl>(v8::DEFAULT), s
tatic_cast<v8::PropertyAttribute>(v8::None), 0 /* on instance */}, | |
8121 {"strictTypeCheckingInterfaceNullableTestInterfaceOrNullAttribute", TestObje
ctV8Internal::strictTypeCheckingInterfaceNullableTestInterfaceOrNullAttributeAtt
ributeGetterCallback, TestObjectV8Internal::strictTypeCheckingInterfaceNullableT
estInterfaceOrNullAttributeAttributeSetterCallback, 0, 0, 0, static_cast<v8::Acc
essControl>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::None), 0 /* on
instance */}, | |
8122 {"treatNullAsNullStringStringAttribute", TestObjectV8Internal::treatNullAsNu
llStringStringAttributeAttributeGetterCallback, TestObjectV8Internal::treatNullA
sNullStringStringAttributeAttributeSetterCallback, 0, 0, 0, static_cast<v8::Acce
ssControl>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::None), 0 /* on i
nstance */}, | 8145 {"treatNullAsNullStringStringAttribute", TestObjectV8Internal::treatNullAsNu
llStringStringAttributeAttributeGetterCallback, TestObjectV8Internal::treatNullA
sNullStringStringAttributeAttributeSetterCallback, 0, 0, 0, static_cast<v8::Acce
ssControl>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::None), 0 /* on i
nstance */}, |
8123 {"treatReturnedNullStringAsNullStringAttribute", TestObjectV8Internal::treat
ReturnedNullStringAsNullStringAttributeAttributeGetterCallback, TestObjectV8Inte
rnal::treatReturnedNullStringAsNullStringAttributeAttributeSetterCallback, 0, 0,
0, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribu
te>(v8::None), 0 /* on instance */}, | 8146 {"treatReturnedNullStringAsNullStringAttribute", TestObjectV8Internal::treat
ReturnedNullStringAsNullStringAttributeAttributeGetterCallback, TestObjectV8Inte
rnal::treatReturnedNullStringAsNullStringAttributeAttributeSetterCallback, 0, 0,
0, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribu
te>(v8::None), 0 /* on instance */}, |
8124 {"treatReturnedNullStringAsUndefinedStringAttribute", TestObjectV8Internal::
treatReturnedNullStringAsUndefinedStringAttributeAttributeGetterCallback, TestOb
jectV8Internal::treatReturnedNullStringAsUndefinedStringAttributeAttributeSetter
Callback, 0, 0, 0, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::
PropertyAttribute>(v8::None), 0 /* on instance */}, | 8147 {"treatReturnedNullStringAsUndefinedStringAttribute", TestObjectV8Internal::
treatReturnedNullStringAsUndefinedStringAttributeAttributeGetterCallback, TestOb
jectV8Internal::treatReturnedNullStringAsUndefinedStringAttributeAttributeSetter
Callback, 0, 0, 0, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::
PropertyAttribute>(v8::None), 0 /* on instance */}, |
| 8148 {"typeCheckingInterfaceNullableStringFloatAttribute", TestObjectV8Internal::
typeCheckingInterfaceNullableStringFloatAttributeAttributeGetterCallback, TestOb
jectV8Internal::typeCheckingInterfaceNullableStringFloatAttributeAttributeSetter
Callback, 0, 0, 0, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::
PropertyAttribute>(v8::None), 0 /* on instance */}, |
| 8149 {"typeCheckingInterfaceTestInterfaceAttribute", TestObjectV8Internal::typeCh
eckingInterfaceTestInterfaceAttributeAttributeGetterCallback, TestObjectV8Intern
al::typeCheckingInterfaceTestInterfaceAttributeAttributeSetterCallback, 0, 0, 0,
static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribute>
(v8::None), 0 /* on instance */}, |
| 8150 {"typeCheckingNullableTestInterfaceOrNullAttribute", TestObjectV8Internal::t
ypeCheckingNullableTestInterfaceOrNullAttributeAttributeGetterCallback, TestObje
ctV8Internal::typeCheckingNullableTestInterfaceOrNullAttributeAttributeSetterCal
lback, 0, 0, 0, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::Pro
pertyAttribute>(v8::None), 0 /* on instance */}, |
| 8151 {"typeCheckingInterfaceNullableTestInterfaceOrNullAttribute", TestObjectV8In
ternal::typeCheckingInterfaceNullableTestInterfaceOrNullAttributeAttributeGetter
Callback, TestObjectV8Internal::typeCheckingInterfaceNullableTestInterfaceOrNull
AttributeAttributeSetterCallback, 0, 0, 0, static_cast<v8::AccessControl>(v8::DE
FAULT), static_cast<v8::PropertyAttribute>(v8::None), 0 /* on instance */}, |
8125 {"urlStringAttribute", TestObjectV8Internal::urlStringAttributeAttributeGett
erCallback, TestObjectV8Internal::urlStringAttributeAttributeSetterCallback, 0,
0, 0, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttri
bute>(v8::None), 0 /* on instance */}, | 8152 {"urlStringAttribute", TestObjectV8Internal::urlStringAttributeAttributeGett
erCallback, TestObjectV8Internal::urlStringAttributeAttributeSetterCallback, 0,
0, 0, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttri
bute>(v8::None), 0 /* on instance */}, |
8126 {"urlStringAttribute", TestObjectV8Internal::urlStringAttributeAttributeGett
erCallback, TestObjectV8Internal::urlStringAttributeAttributeSetterCallback, 0,
0, 0, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttri
bute>(v8::None), 0 /* on instance */}, | 8153 {"urlStringAttribute", TestObjectV8Internal::urlStringAttributeAttributeGett
erCallback, TestObjectV8Internal::urlStringAttributeAttributeSetterCallback, 0,
0, 0, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttri
bute>(v8::None), 0 /* on instance */}, |
8127 {"unforgeableLongAttribute", TestObjectV8Internal::unforgeableLongAttributeA
ttributeGetterCallback, TestObjectV8Internal::unforgeableLongAttributeAttributeS
etterCallback, 0, 0, 0, static_cast<v8::AccessControl>(v8::PROHIBITS_OVERWRITING
), static_cast<v8::PropertyAttribute>(v8::DontDelete), 0 /* on instance */}, | 8154 {"unforgeableLongAttribute", TestObjectV8Internal::unforgeableLongAttributeA
ttributeGetterCallback, TestObjectV8Internal::unforgeableLongAttributeAttributeS
etterCallback, 0, 0, 0, static_cast<v8::AccessControl>(v8::PROHIBITS_OVERWRITING
), static_cast<v8::PropertyAttribute>(v8::DontDelete), 0 /* on instance */}, |
8128 {"testInterfaceAttribute", TestObjectV8Internal::testInterfaceAttributeAttri
buteGetterCallback, TestObjectV8Internal::testInterfaceAttributeAttributeSetterC
allback, 0, 0, 0, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::P
ropertyAttribute>(v8::None), 0 /* on instance */}, | 8155 {"testInterfaceAttribute", TestObjectV8Internal::testInterfaceAttributeAttri
buteGetterCallback, TestObjectV8Internal::testInterfaceAttributeAttributeSetterC
allback, 0, 0, 0, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::P
ropertyAttribute>(v8::None), 0 /* on instance */}, |
8129 {"testInterfaceGarbageCollectedAttribute", TestObjectV8Internal::testInterfa
ceGarbageCollectedAttributeAttributeGetterCallback, TestObjectV8Internal::testIn
terfaceGarbageCollectedAttributeAttributeSetterCallback, 0, 0, 0, static_cast<v8
::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::None), 0 /
* on instance */}, | 8156 {"testInterfaceGarbageCollectedAttribute", TestObjectV8Internal::testInterfa
ceGarbageCollectedAttributeAttributeGetterCallback, TestObjectV8Internal::testIn
terfaceGarbageCollectedAttributeAttributeSetterCallback, 0, 0, 0, static_cast<v8
::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::None), 0 /
* on instance */}, |
8130 {"testInterfaceGarbageCollectedOrNullAttribute", TestObjectV8Internal::testI
nterfaceGarbageCollectedOrNullAttributeAttributeGetterCallback, TestObjectV8Inte
rnal::testInterfaceGarbageCollectedOrNullAttributeAttributeSetterCallback, 0, 0,
0, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribu
te>(v8::None), 0 /* on instance */}, | 8157 {"testInterfaceGarbageCollectedOrNullAttribute", TestObjectV8Internal::testI
nterfaceGarbageCollectedOrNullAttributeAttributeGetterCallback, TestObjectV8Inte
rnal::testInterfaceGarbageCollectedOrNullAttributeAttributeSetterCallback, 0, 0,
0, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribu
te>(v8::None), 0 /* on instance */}, |
8131 {"testInterfaceWillBeGarbageCollectedAttribute", TestObjectV8Internal::testI
nterfaceWillBeGarbageCollectedAttributeAttributeGetterCallback, TestObjectV8Inte
rnal::testInterfaceWillBeGarbageCollectedAttributeAttributeSetterCallback, 0, 0,
0, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribu
te>(v8::None), 0 /* on instance */}, | 8158 {"testInterfaceWillBeGarbageCollectedAttribute", TestObjectV8Internal::testI
nterfaceWillBeGarbageCollectedAttributeAttributeGetterCallback, TestObjectV8Inte
rnal::testInterfaceWillBeGarbageCollectedAttributeAttributeSetterCallback, 0, 0,
0, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribu
te>(v8::None), 0 /* on instance */}, |
8132 {"testInterfaceWillBeGarbageCollectedOrNullAttribute", TestObjectV8Internal:
:testInterfaceWillBeGarbageCollectedOrNullAttributeAttributeGetterCallback, Test
ObjectV8Internal::testInterfaceWillBeGarbageCollectedOrNullAttributeAttributeSet
terCallback, 0, 0, 0, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v
8::PropertyAttribute>(v8::None), 0 /* on instance */}, | 8159 {"testInterfaceWillBeGarbageCollectedOrNullAttribute", TestObjectV8Internal:
:testInterfaceWillBeGarbageCollectedOrNullAttributeAttributeGetterCallback, Test
ObjectV8Internal::testInterfaceWillBeGarbageCollectedOrNullAttributeAttributeSet
terCallback, 0, 0, 0, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v
8::PropertyAttribute>(v8::None), 0 /* on instance */}, |
8133 }; | 8160 }; |
8134 | 8161 |
(...skipping 156 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
8291 {"perWorldBindingsVoidMethodTestInterfaceEmptyArg", TestObjectV8Internal::pe
rWorldBindingsVoidMethodTestInterfaceEmptyArgMethodCallback, TestObjectV8Interna
l::perWorldBindingsVoidMethodTestInterfaceEmptyArgMethodCallbackForMainWorld, 1}
, | 8318 {"perWorldBindingsVoidMethodTestInterfaceEmptyArg", TestObjectV8Internal::pe
rWorldBindingsVoidMethodTestInterfaceEmptyArgMethodCallback, TestObjectV8Interna
l::perWorldBindingsVoidMethodTestInterfaceEmptyArgMethodCallbackForMainWorld, 1}
, |
8292 {"activityLoggingForAllWorldsPerWorldBindingsVoidMethod", TestObjectV8Intern
al::activityLoggingForAllWorldsPerWorldBindingsVoidMethodMethodCallback, TestObj
ectV8Internal::activityLoggingForAllWorldsPerWorldBindingsVoidMethodMethodCallba
ckForMainWorld, 0}, | 8319 {"activityLoggingForAllWorldsPerWorldBindingsVoidMethod", TestObjectV8Intern
al::activityLoggingForAllWorldsPerWorldBindingsVoidMethodMethodCallback, TestObj
ectV8Internal::activityLoggingForAllWorldsPerWorldBindingsVoidMethodMethodCallba
ckForMainWorld, 0}, |
8293 {"activityLoggingForIsolatedWorldsPerWorldBindingsVoidMethod", TestObjectV8I
nternal::activityLoggingForIsolatedWorldsPerWorldBindingsVoidMethodMethodCallbac
k, TestObjectV8Internal::activityLoggingForIsolatedWorldsPerWorldBindingsVoidMet
hodMethodCallbackForMainWorld, 0}, | 8320 {"activityLoggingForIsolatedWorldsPerWorldBindingsVoidMethod", TestObjectV8I
nternal::activityLoggingForIsolatedWorldsPerWorldBindingsVoidMethodMethodCallbac
k, TestObjectV8Internal::activityLoggingForIsolatedWorldsPerWorldBindingsVoidMet
hodMethodCallbackForMainWorld, 0}, |
8294 {"raisesExceptionVoidMethod", TestObjectV8Internal::raisesExceptionVoidMetho
dMethodCallback, 0, 0}, | 8321 {"raisesExceptionVoidMethod", TestObjectV8Internal::raisesExceptionVoidMetho
dMethodCallback, 0, 0}, |
8295 {"raisesExceptionStringMethod", TestObjectV8Internal::raisesExceptionStringM
ethodMethodCallback, 0, 0}, | 8322 {"raisesExceptionStringMethod", TestObjectV8Internal::raisesExceptionStringM
ethodMethodCallback, 0, 0}, |
8296 {"raisesExceptionVoidMethodOptionalLongArg", TestObjectV8Internal::raisesExc
eptionVoidMethodOptionalLongArgMethodCallback, 0, 0}, | 8323 {"raisesExceptionVoidMethodOptionalLongArg", TestObjectV8Internal::raisesExc
eptionVoidMethodOptionalLongArgMethodCallback, 0, 0}, |
8297 {"raisesExceptionVoidMethodTestCallbackInterfaceArg", TestObjectV8Internal::
raisesExceptionVoidMethodTestCallbackInterfaceArgMethodCallback, 0, 1}, | 8324 {"raisesExceptionVoidMethodTestCallbackInterfaceArg", TestObjectV8Internal::
raisesExceptionVoidMethodTestCallbackInterfaceArgMethodCallback, 0, 1}, |
8298 {"raisesExceptionVoidMethodOptionalTestCallbackInterfaceArg", TestObjectV8In
ternal::raisesExceptionVoidMethodOptionalTestCallbackInterfaceArgMethodCallback,
0, 0}, | 8325 {"raisesExceptionVoidMethodOptionalTestCallbackInterfaceArg", TestObjectV8In
ternal::raisesExceptionVoidMethodOptionalTestCallbackInterfaceArgMethodCallback,
0, 0}, |
8299 {"raisesExceptionTestInterfaceEmptyVoidMethod", TestObjectV8Internal::raises
ExceptionTestInterfaceEmptyVoidMethodMethodCallback, 0, 0}, | 8326 {"raisesExceptionTestInterfaceEmptyVoidMethod", TestObjectV8Internal::raises
ExceptionTestInterfaceEmptyVoidMethodMethodCallback, 0, 0}, |
8300 {"callWithExecutionContextRaisesExceptionVoidMethodLongArg", TestObjectV8Int
ernal::callWithExecutionContextRaisesExceptionVoidMethodLongArgMethodCallback, 0
, 1}, | 8327 {"callWithExecutionContextRaisesExceptionVoidMethodLongArg", TestObjectV8Int
ernal::callWithExecutionContextRaisesExceptionVoidMethodLongArgMethodCallback, 0
, 1}, |
8301 {"strictTypeCheckingInterfaceVoidMethodTestInterfaceEmptyArg", TestObjectV8I
nternal::strictTypeCheckingInterfaceVoidMethodTestInterfaceEmptyArgMethodCallbac
k, 0, 1}, | |
8302 {"strictTypeCheckingNullableVoidMethodTestInterfaceEmptyOrNullArg", TestObje
ctV8Internal::strictTypeCheckingNullableVoidMethodTestInterfaceEmptyOrNullArgMet
hodCallback, 0, 1}, | |
8303 {"strictTypeCheckingInterfaceNullableVoidMethodTestInterfaceEmptyOrNullArg",
TestObjectV8Internal::strictTypeCheckingInterfaceNullableVoidMethodTestInterfac
eEmptyOrNullArgMethodCallback, 0, 1}, | |
8304 {"treatReturnedNullStringAsNullStringMethod", TestObjectV8Internal::treatRet
urnedNullStringAsNullStringMethodMethodCallback, 0, 0}, | 8328 {"treatReturnedNullStringAsNullStringMethod", TestObjectV8Internal::treatRet
urnedNullStringAsNullStringMethodMethodCallback, 0, 0}, |
8305 {"treatReturnedNullStringAsUndefinedStringMethod", TestObjectV8Internal::tre
atReturnedNullStringAsUndefinedStringMethodMethodCallback, 0, 0}, | 8329 {"treatReturnedNullStringAsUndefinedStringMethod", TestObjectV8Internal::tre
atReturnedNullStringAsUndefinedStringMethodMethodCallback, 0, 0}, |
| 8330 {"typeCheckingInterfaceVoidMethodTestInterfaceEmptyArg", TestObjectV8Interna
l::typeCheckingInterfaceVoidMethodTestInterfaceEmptyArgMethodCallback, 0, 1}, |
| 8331 {"typeCheckingNullableVoidMethodTestInterfaceEmptyOrNullArg", TestObjectV8In
ternal::typeCheckingNullableVoidMethodTestInterfaceEmptyOrNullArgMethodCallback,
0, 1}, |
| 8332 {"typeCheckingInterfaceNullableVoidMethodTestInterfaceEmptyOrNullArg", TestO
bjectV8Internal::typeCheckingInterfaceNullableVoidMethodTestInterfaceEmptyOrNull
ArgMethodCallback, 0, 1}, |
| 8333 {"typeCheckingUnrestrictedVoidMethodFloatArgDoubleArg", TestObjectV8Internal
::typeCheckingUnrestrictedVoidMethodFloatArgDoubleArgMethodCallback, 0, 2}, |
8306 {"voidMethodTestInterfaceGarbageCollectedSequenceArg", TestObjectV8Internal:
:voidMethodTestInterfaceGarbageCollectedSequenceArgMethodCallback, 0, 1}, | 8334 {"voidMethodTestInterfaceGarbageCollectedSequenceArg", TestObjectV8Internal:
:voidMethodTestInterfaceGarbageCollectedSequenceArgMethodCallback, 0, 1}, |
8307 {"voidMethodTestInterfaceGarbageCollectedArrayArg", TestObjectV8Internal::vo
idMethodTestInterfaceGarbageCollectedArrayArgMethodCallback, 0, 1}, | 8335 {"voidMethodTestInterfaceGarbageCollectedArrayArg", TestObjectV8Internal::vo
idMethodTestInterfaceGarbageCollectedArrayArgMethodCallback, 0, 1}, |
8308 {"voidMethodTestInterfaceWillBeGarbageCollectedSequenceArg", TestObjectV8Int
ernal::voidMethodTestInterfaceWillBeGarbageCollectedSequenceArgMethodCallback, 0
, 1}, | 8336 {"voidMethodTestInterfaceWillBeGarbageCollectedSequenceArg", TestObjectV8Int
ernal::voidMethodTestInterfaceWillBeGarbageCollectedSequenceArgMethodCallback, 0
, 1}, |
8309 {"voidMethodTestInterfaceWillBeGarbageCollectedArrayArg", TestObjectV8Intern
al::voidMethodTestInterfaceWillBeGarbageCollectedArrayArgMethodCallback, 0, 1}, | 8337 {"voidMethodTestInterfaceWillBeGarbageCollectedArrayArg", TestObjectV8Intern
al::voidMethodTestInterfaceWillBeGarbageCollectedArrayArgMethodCallback, 0, 1}, |
8310 }; | 8338 }; |
8311 | 8339 |
8312 static void configureV8TestObjectTemplate(v8::Handle<v8::FunctionTemplate> funct
ionTemplate, v8::Isolate* isolate) | 8340 static void configureV8TestObjectTemplate(v8::Handle<v8::FunctionTemplate> funct
ionTemplate, v8::Isolate* isolate) |
8313 { | 8341 { |
8314 functionTemplate->ReadOnlyPrototype(); | 8342 functionTemplate->ReadOnlyPrototype(); |
8315 | 8343 |
(...skipping 163 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
8479 fromInternalPointer(object)->deref(); | 8507 fromInternalPointer(object)->deref(); |
8480 } | 8508 } |
8481 | 8509 |
8482 template<> | 8510 template<> |
8483 v8::Handle<v8::Value> toV8NoInline(TestObject* impl, v8::Handle<v8::Object> crea
tionContext, v8::Isolate* isolate) | 8511 v8::Handle<v8::Value> toV8NoInline(TestObject* impl, v8::Handle<v8::Object> crea
tionContext, v8::Isolate* isolate) |
8484 { | 8512 { |
8485 return toV8(impl, creationContext, isolate); | 8513 return toV8(impl, creationContext, isolate); |
8486 } | 8514 } |
8487 | 8515 |
8488 } // namespace WebCore | 8516 } // namespace WebCore |
OLD | NEW |