The IDE provides several options for running a Java program. You can simply run your program or you can run and debug it at the same time. You can run individual files and or you can run a project.
For help with running a Java program, see:
The Running Workspace
Running a Java Program
Running and Debugging an Applet
Specifying the Main Class to Run for a Project
Running a Class When the IDE Starts
Running Java Sources in a Specific Locale