| Index: Source/bindings/tests/results/V8TestObject.cpp
|
| diff --git a/Source/bindings/tests/results/V8TestObject.cpp b/Source/bindings/tests/results/V8TestObject.cpp
|
| index d5d3aa395eac3235eb7b5ae56bb3ae2a86bbe8f6..a21cf7faf8eb92b7bf83b52d2098542cedaaeb33 100644
|
| --- a/Source/bindings/tests/results/V8TestObject.cpp
|
| +++ b/Source/bindings/tests/results/V8TestObject.cpp
|
| @@ -220,6 +220,36 @@ static void byteStringAttributeAttributeSetterCallback(v8::Local<v8::String>, v8
|
| TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution");
|
| }
|
|
|
| +static void scalarValueStringAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::Value>& info)
|
| +{
|
| + v8::Handle<v8::Object> holder = info.Holder();
|
| + TestObject* impl = V8TestObject::toNative(holder);
|
| + v8SetReturnValueString(info, impl->scalarValueStringAttribute(), info.GetIsolate());
|
| +}
|
| +
|
| +static void scalarValueStringAttributeAttributeGetterCallback(v8::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info)
|
| +{
|
| + TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter");
|
| + TestObjectV8Internal::scalarValueStringAttributeAttributeGetter(info);
|
| + TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution");
|
| +}
|
| +
|
| +static void scalarValueStringAttributeAttributeSetter(v8::Local<v8::Value> v8Value, const v8::PropertyCallbackInfo<void>& info)
|
| +{
|
| + v8::Handle<v8::Object> holder = info.Holder();
|
| + ExceptionState exceptionState(ExceptionState::SetterContext, "scalarValueStringAttribute", "TestObject", holder, info.GetIsolate());
|
| + TestObject* impl = V8TestObject::toNative(holder);
|
| + TONATIVE_VOID_EXCEPTIONSTATE(V8StringResource<>, cppValue, toScalarValueString(v8Value, exceptionState), exceptionState);
|
| + impl->setScalarValueStringAttribute(cppValue);
|
| +}
|
| +
|
| +static void scalarValueStringAttributeAttributeSetterCallback(v8::Local<v8::String>, v8::Local<v8::Value> v8Value, const v8::PropertyCallbackInfo<void>& info)
|
| +{
|
| + TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMSetter");
|
| + TestObjectV8Internal::scalarValueStringAttributeAttributeSetter(v8Value, info);
|
| + TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution");
|
| +}
|
| +
|
| static void domTimeStampAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::Value>& info)
|
| {
|
| v8::Handle<v8::Object> holder = info.Holder();
|
| @@ -4679,6 +4709,19 @@ static void byteStringMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Va
|
| TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution");
|
| }
|
|
|
| +static void scalarValueStringMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info)
|
| +{
|
| + TestObject* impl = V8TestObject::toNative(info.Holder());
|
| + v8SetReturnValueString(info, impl->scalarValueStringMethod(), info.GetIsolate());
|
| +}
|
| +
|
| +static void scalarValueStringMethodMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info)
|
| +{
|
| + TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod");
|
| + TestObjectV8Internal::scalarValueStringMethodMethod(info);
|
| + TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution");
|
| +}
|
| +
|
| static void readonlyDOMTimeStampMethodMethod(const v8::FunctionCallbackInfo<v8::Value>& info)
|
| {
|
| TestObject* impl = V8TestObject::toNative(info.Holder());
|
| @@ -4903,6 +4946,30 @@ static void voidMethodByteStringArgMethodCallback(const v8::FunctionCallbackInfo
|
| TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution");
|
| }
|
|
|
| +static void voidMethodScalarValueStringArgMethod(const v8::FunctionCallbackInfo<v8::Value>& info)
|
| +{
|
| + ExceptionState exceptionState(ExceptionState::ExecutionContext, "voidMethodScalarValueStringArg", "TestObject", info.Holder(), info.GetIsolate());
|
| + if (UNLIKELY(info.Length() < 1)) {
|
| + throwMinimumArityTypeError(exceptionState, 1, info.Length());
|
| + return;
|
| + }
|
| + TestObject* impl = V8TestObject::toNative(info.Holder());
|
| + V8StringResource<> scalarValueStringArg;
|
| + {
|
| + v8::TryCatch block;
|
| + V8RethrowTryCatchScope rethrow(block);
|
| + TONATIVE_VOID_EXCEPTIONSTATE_INTERNAL(scalarValueStringArg, toScalarValueString(info[0], exceptionState), exceptionState);
|
| + }
|
| + impl->voidMethodScalarValueStringArg(scalarValueStringArg);
|
| +}
|
| +
|
| +static void voidMethodScalarValueStringArgMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info)
|
| +{
|
| + TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMMethod");
|
| + TestObjectV8Internal::voidMethodScalarValueStringArgMethod(info);
|
| + TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution");
|
| +}
|
| +
|
| static void voidMethodDOMTimeStampArgMethod(const v8::FunctionCallbackInfo<v8::Value>& info)
|
| {
|
| ExceptionState exceptionState(ExceptionState::ExecutionContext, "voidMethodDOMTimeStampArg", "TestObject", info.Holder(), info.GetIsolate());
|
| @@ -9032,6 +9099,7 @@ static const V8DOMConfiguration::AttributeConfiguration V8TestObjectAttributes[]
|
| {"dateAttribute", TestObjectV8Internal::dateAttributeAttributeGetterCallback, TestObjectV8Internal::dateAttributeAttributeSetterCallback, 0, 0, 0, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::None), 0 /* on instance */},
|
| {"stringAttribute", TestObjectV8Internal::stringAttributeAttributeGetterCallback, TestObjectV8Internal::stringAttributeAttributeSetterCallback, 0, 0, 0, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::None), 0 /* on instance */},
|
| {"byteStringAttribute", TestObjectV8Internal::byteStringAttributeAttributeGetterCallback, TestObjectV8Internal::byteStringAttributeAttributeSetterCallback, 0, 0, 0, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::None), 0 /* on instance */},
|
| + {"scalarValueStringAttribute", TestObjectV8Internal::scalarValueStringAttributeAttributeGetterCallback, TestObjectV8Internal::scalarValueStringAttributeAttributeSetterCallback, 0, 0, 0, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::None), 0 /* on instance */},
|
| {"domTimeStampAttribute", TestObjectV8Internal::domTimeStampAttributeAttributeGetterCallback, TestObjectV8Internal::domTimeStampAttributeAttributeSetterCallback, 0, 0, 0, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::None), 0 /* on instance */},
|
| {"booleanAttribute", TestObjectV8Internal::booleanAttributeAttributeGetterCallback, TestObjectV8Internal::booleanAttributeAttributeSetterCallback, 0, 0, 0, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::None), 0 /* on instance */},
|
| {"byteAttribute", TestObjectV8Internal::byteAttributeAttributeGetterCallback, TestObjectV8Internal::byteAttributeAttributeSetterCallback, 0, 0, 0, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::None), 0 /* on instance */},
|
| @@ -9186,6 +9254,7 @@ static const V8DOMConfiguration::MethodConfiguration V8TestObjectMethods[] = {
|
| {"dateMethod", TestObjectV8Internal::dateMethodMethodCallback, 0, 0},
|
| {"stringMethod", TestObjectV8Internal::stringMethodMethodCallback, 0, 0},
|
| {"byteStringMethod", TestObjectV8Internal::byteStringMethodMethodCallback, 0, 0},
|
| + {"scalarValueStringMethod", TestObjectV8Internal::scalarValueStringMethodMethodCallback, 0, 0},
|
| {"readonlyDOMTimeStampMethod", TestObjectV8Internal::readonlyDOMTimeStampMethodMethodCallback, 0, 0},
|
| {"booleanMethod", TestObjectV8Internal::booleanMethodMethodCallback, 0, 0},
|
| {"byteMethod", TestObjectV8Internal::byteMethodMethodCallback, 0, 0},
|
| @@ -9201,6 +9270,7 @@ static const V8DOMConfiguration::MethodConfiguration V8TestObjectMethods[] = {
|
| {"voidMethodDateArg", TestObjectV8Internal::voidMethodDateArgMethodCallback, 0, 1},
|
| {"voidMethodStringArg", TestObjectV8Internal::voidMethodStringArgMethodCallback, 0, 1},
|
| {"voidMethodByteStringArg", TestObjectV8Internal::voidMethodByteStringArgMethodCallback, 0, 1},
|
| + {"voidMethodScalarValueStringArg", TestObjectV8Internal::voidMethodScalarValueStringArgMethodCallback, 0, 1},
|
| {"voidMethodDOMTimeStampArg", TestObjectV8Internal::voidMethodDOMTimeStampArgMethodCallback, 0, 1},
|
| {"voidMethodBooleanArg", TestObjectV8Internal::voidMethodBooleanArgMethodCallback, 0, 1},
|
| {"voidMethodByteArg", TestObjectV8Internal::voidMethodByteArgMethodCallback, 0, 1},
|
|
|