here is how I installed my J2sdk1.4.2
0.)Open a console (if you are using X), and go to the folder where the .bin is located. For the purposes of providing an example, let us say that your installer is j2sdk-1_4_2_04-linux-i586.bin (I believe this is the latest version of JDK1.4 series. Haven't tried 1.5 yet, though...
1.) since you might need root priveleges to install, type
and enter you password
chmod 777 j2sdk-1_4_2_04-linux-i586.bin
This would tell linux that the installer is executable
This will execute the binary installer
4.) There will be the some agreements to be agreed upon, some settings to set, (for example, the directory where you would want you java environment to be installed). Mine is installed in /usr/local/j2sdk1.4.2_04/.
5.) You now have installed your Java Environment. To use it, you might use /<java installation>/java myprogram