[webkit-dev] JSObjectCallAsFunctionCallback question
Xiong
browserwk at gmail.com
Thu May 14 20:46:01 PDT 2009
Darin, thanks for you help.
I think we must implement the extra member for "function object" in my
program architecture.
Maybe more work.
Thanks again.
-Xiong
On Fri, May 15, 2009 at 11:32 AM, Darin Adler <darin at apple.com> wrote:
> On May 14, 2009, at 7:53 PM, Xiong wrote:
>
> So,can we add a member for the "function object" to store the method
>> name[here is "getValues"] in theoretical ?
>>
>
> Yes, in theory you could do that. Although that’s not the typical pattern.
>
> And this also like the "JSObjectRef object" variable in the callback
>> prototype,we can get the class name like this:
>>
>> toJS(object)->className().data()
>>
>
> No, you can’t do that. Those three functions are part of the internals and
> not part of the JavaScriptCore API.
>
> Instead, if you want to know if an object has a particular class you can
> use JSValueIsObjectOfClass.
>
> -- Darin
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-dev/attachments/20090515/ef983863/attachment.html>
More information about the webkit-dev
mailing list