[Go back to MCell Home] | [Go back to MJCell applet]
Due to the high demand I decided to make the MJCell's source code open. I don't force you to tell me what you need this source for; I also don't ask for your name or e-mail. But if you are going to modify/extend the applet, I have a proposal: let's make the next version of it together. I'm a very busy man and I hardly find time to extend the applet with all the features I dream about. But working in a team we could do much more, faster, and better.
Here are all source modules that build the applet. You can also download the whole zipped package.
Note! This chapter is intended for beginners only. If you know how to compile Java applets, reading it is probably a waste of time.
I won't retype the Java compiler manuals here; I will only give you some hints to allow you a faster start. I wish I had such a brief tutorial when I was starting :(
The simplest method of compiling the applet is using the Sun's JDK in the command-line mode. Download the Java Development Kit 1.1, install it, go to the folder where you unpacked the MJCell's source, and execute the command
jdkpath\bin\javac.exe -classpath jdkpath\lib\classes.zip *.java
where jdkpath is the folder where you installed JDK.
In my case it's like this:
D:\Java\jdk1.1.8\bin\javac.exe -classpath D:\Java\jdk1.1.8\lib\classes.zip *.java
To make my life easier, I created a batch file (I work with Windows), called jc11.bat, with the following command:
D:\Java\jdk1.1.8\bin\javac.exe -classpath D:\Java\jdk1.1.8\lib\classes.zip %1 %2 %3 %4 %5
With such batch file I can compile my source code typing only jc11 *.java
After compiling you should find in the same folder a set of .class files. If there were no error messages, the applet is ready to start. To run it open the sample HTML page I provided in the package in your Java-enabled browser, or use the Sun's Applet Viewer. For the Viewer use the following command:
Of course I don't type it, I use the jv11.bat batch file for viewing applets.
I regularly compile the applet using 3 different compilers: Sun Microsystems' JDK 1.1.8, Microsoft Visual Java 6.0, and Borland Java Builder 2.1. The applet compiles with all of them without problems. You will only see some notes about deprecated functions; there are still many inside, they remained from the first version compiled with JDK 1.0.2. I never find time (and motivation) to eliminate them.
|Webmaster: Mirek Wojtowicz