Java Reference
In-Depth Information
All of the remaining classes can be compiled individually; however,
compiling the initial log on class causes all classes used in the application to
compile also.
The following steps open the initial log on class and compile the remaining
related classes for the Stock Tracker application.
To Compile Related Classes
1. Click the Open button on the Standard toolbar.
2. When the Open File(s) dialog box is displayed, if necessary, click the
Look in box arrow and select the Chapter11 folder (or the location
specified by your instructor).
3. Click the file, STLogon.java, and then click the Open button.
4. Compile the class, STLogon.
TextPad displays the code for the STLogon class (Figure 11-56). The remain-
ing classes for the application are compiled also.
STLogon.java
FIGURE 11-56
The remaining classes were compiled because the compiler tries to locate all
classes used in the initial log on GUI and, if not found, attempts to locate and
compile the source code. As each class depends on another related class, the
compiles cascade until all needed classes are compiled. This cascade of compiles
works only for source code files without existing matching class files. If a class
file exists, its source code file must be explicitly compiled.
 
Search WWH ::




Custom Search