Java Applications in a Nutshell
All Java programs are written into a file with a ".java" extension.
Applications are .java files with a main method which is excuted first.
How to compile and run a Java application (via bytecodes):
- Run the compiler on a .java file:
- javac MyProgram.java
- producing a file "MyProgram.class" of Java bytecodes
- Run the interpreter on a .class file:
- java MyProgram
- which executes the bytecodes
The resources javac and java are part of JDK and are not in Netscape and so are not necessarily available on the same machine as your web server.