[v8-users] how to return a data structure from c to java

2014-03-28 Thread eric . chen
I am writing a addon for javascript. EX: In my addon, define a car structure. struct car { int carId; string carName; .. }; v8::Handlev8::Value GetCar(const v8::Arguments args) { struct car my_car; ... // how can I return V8 handle so that I can use this vector in

Re: [v8-users] Enter/Exit an Isolate.

2014-03-28 Thread Sven Panne
On Fri, Mar 28, 2014 at 2:46 AM, Jane Chen jxche...@gmail.com wrote: With a model where I always have one isolate per thread, and a thread may serve multiple requests and live around for some time, is there any reason why I want to Enter the isolate every time I make v8 calls and Exit

Re: [v8-users] Re: v8 API changes

2014-03-28 Thread Sven Panne
On Fri, Mar 28, 2014 at 2:50 AM, Jane Chen jxche...@gmail.com wrote: May I know what would be the svn repository branch version for this? http://v8.googlecode.com/svn/branches/3.24 is the SVN branch for the v8 version in the upcoming Chrome 34, http://v8.googlecode.com/svn/branches/3.25 will

Re: [v8-users] Re: Size limitation on the snapshot file?

2014-03-28 Thread Yong Wang
Maybe you should use --extra_code flag to snapshot external js file. and how do you handle DOM objects used in jquery? I don't think mksnapshot can hanlde this case. 在 2014年2月28日星期五UTC+8上午1时16分22秒,Zhao Cheng写道: No, it is still unsolved. The snapshot was created with the mksnapshot tool

Re: [v8-users] v8::Object destructor callback?

2014-03-28 Thread Ben Noordhuis
On Fri, Mar 28, 2014 at 6:03 PM, Jane Chen jxche...@gmail.com wrote: I create a v8::Object from my ObjectTemplate and embed my own data with SetAlignedPointerInInternalField. I want to get a call back when that v8::Object is destructed by v8, so that I can clean up my own stuff. Does such an

Re: [v8-users] v8::Object destructor callback?

2014-03-28 Thread Jane Chen
Ah! Thanks Ben! I got it just after I wrote my own book-keeping for them. :-) Will check it out anyway. On Friday, March 28, 2014 10:32:07 AM UTC-7, Ben Noordhuis wrote: On Fri, Mar 28, 2014 at 6:03 PM, Jane Chen jxch...@gmail.comjavascript: wrote: I create a v8::Object from my