org.tempuri.javac
Interface JavaCompiler

All Known Implementing Classes:
JavaCompilerImpl

public interface JavaCompiler

Generic interface to a Java compilation system


Method Summary
 void compile(java.lang.String[] classNames, JavaSourceReaderFactory sourceReaderFactory, JavaClassReaderFactory classReaderFactory, JavaClassWriterFactory classWriterFactory, JavaCompilerErrorHandler errorHandler)
          Compile a set of source classes.
 void setDebug(boolean debug)
          Choose whether the compiler should include the line number table and local variable table in generated class files
 void setSourceVersion(java.lang.String sourceVersion)
          Choose the Java source version, e.g "1.2", "1.3", or "1.4"
 void setTargetVersion(java.lang.String targetVersion)
          Choose the target Java platform version, e.g "1.2", "1.3", or "1.4"
 

Method Detail

setTargetVersion

public void setTargetVersion(java.lang.String targetVersion)
                      throws java.lang.IllegalArgumentException
Choose the target Java platform version, e.g "1.2", "1.3", or "1.4"

Parameters:
targetVersion -
java.lang.IllegalArgumentException

setSourceVersion

public void setSourceVersion(java.lang.String sourceVersion)
                      throws java.lang.IllegalArgumentException
Choose the Java source version, e.g "1.2", "1.3", or "1.4"

Parameters:
sourceVersion -
java.lang.IllegalArgumentException

setDebug

public void setDebug(boolean debug)
Choose whether the compiler should include the line number table and local variable table in generated class files

Parameters:
debug -

compile

public void compile(java.lang.String[] classNames,
                    JavaSourceReaderFactory sourceReaderFactory,
                    JavaClassReaderFactory classReaderFactory,
                    JavaClassWriterFactory classWriterFactory,
                    JavaCompilerErrorHandler errorHandler)
Compile a set of source classes. The compiler will attempt to compile the transitive closure of all classes in this set.

Parameters:
classNames - list of classes to be compiled
sourceReaderFactory - object used by compiler to locate source code
classReaderFactory - object used by compiler to locate existing compiled classes
classWriterFactory - object used by compiler to handle generated classes
errorHandler - object used by compiler to handle errors