NTNUJAVA Virtual Physics Laboratory
Enjoy the fun of physics with simulations!
Backup site http://enjoy.phy.ntnu.edu.tw/ntnujava/

Easy Java Simulations (2001- ) => Questions related to EJS => Topic started by: benkwang on May 07, 2008, 09:37:08 am

Title: Extracting Needed Class from Library?
Post by: benkwang on May 07, 2008, 09:37:08 am
Hi Proj..

I have this problem.. If i create an app, the whole of ejsBasic.jar is attached to it. But it has caused the file to be too huge.. Therefore i was thinking if theres a way i can extract the needed java classes instead of the whole 2MB library file. From what ive seen. My 14kb App becomes 2MB after attaching the required library files. Im asking this because i would need to upload them to the internet for students. But this causes the loading time to far exceed the normal loading time. Hope to hear from you soon. Thanks

Title: Re: Extracting Needed Class from Library?
Post by: Fu-Kwun Hwang on May 07, 2008, 12:09:07 pm
The same ejsBasic.jar is used for all the ejs created applets. So you only need to have one copy of ejsBasic.jar on your server. I think this is better than you have many copy of similar files. For examples, we have several hundreds ejs  applets and they all used the same ejsBasic.jar 
And if I update ejsBasic.jar to a new version, all the applets do not need to be re-compiled and all the applets will have new functions available.