/ref - Recompile Referenced Classes

Syntax

/ref[-]

The option causes the compiler to check for a matching .java source file when loading class information from a class file on the class path. If this option is set, whenever the compiler is about to load class information from a .java class file, it checks for a presence of a .java source file of the same base name in the same directory. If such a source file is found, and the source file has a modification date later than that of the .java class file, the .java source file is compiled instead of reading the .java class file.

If this option is not set, the compiler will always read the .java class file, regardless of the presence of a source file.

This option is on by default when compiling from the command line; use /ref- to turn it off. This option is off by default when compiling from the integrated development environment.

CAUTION   It is recommend that you do not turn this option on in the integrated development environment; doing so may cause the build operation to fail to perform as designed.

Example

The following command compiles the myclass.java files, and tells the compiler not to recompile any referenced classes:

JVC /ref- myClass.java