|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--edu.rice.cs.drjava.model.compiler.GJv6Compiler
The GJ compiler used by DrJava.
Inner Class Summary | |
private class |
GJv6Compiler.OurLog
put your documentation comment here |
Field Summary | |
private gjc.v6.JavaCompiler |
_compiler
|
private GJv6Compiler.OurLog |
_compilerLog
We need to explicitly make the compiler's log and pass it to JavaCompiler.make() so we can keep a pointer to the log, since the log is not retrievable from the compiler. |
private String |
_extraClassPath
|
static String |
COMPILER_CLASS_NAME
|
static CompilerInterface |
ONLY
Singleton instance. |
Constructor Summary | |
private |
GJv6Compiler()
Create the compiler. |
Method Summary | |
private void |
_initCompiler(File[] sourceRoots)
Set up new instance of the GJ compiler. |
void |
addToBootClassPath(File cp)
This method allows us to set the JSR14 collections path across a class loader. |
CompilerError[] |
compile(File[] sourceRoots,
File[] files)
Compile the given files. |
CompilerError[] |
compile(File sourceRoot,
File[] files)
Compile the given files. |
String |
getName()
Returns the name of this compiler, appropriate to show to the user. |
protected String |
getSourceRootString(File[] sourceRoots)
Utility method for getting a properly formatted string with several source paths from an array of files. |
boolean |
isAvailable()
Indicates whether this compiler is actually available. |
void |
setAllowAssertions(boolean allow)
Sets whether to allow assertions in Java 1.4. |
void |
setExtraClassPath(String extraClassPath)
Allows us to set the extra classpath for the compilers without referencing the config object in a loaded class file |
String |
toString()
Should return info about compiler, at least including name. |
Methods inherited from class java.lang.Object |
|
Field Detail |
private String _extraClassPath
public static final CompilerInterface ONLY
public static final String COMPILER_CLASS_NAME
private gjc.v6.JavaCompiler _compiler
private GJv6Compiler.OurLog _compilerLog
Constructor Detail |
private GJv6Compiler()
Method Detail |
private void _initCompiler(File[] sourceRoots)
public CompilerError[] compile(File sourceRoot, File[] files)
compile
in interface CompilerInterface
files
- Source files to compile.sourceRoot
- Source root directory, the base of the package structure.public CompilerError[] compile(File[] sourceRoots, File[] files)
compile
in interface CompilerInterface
files
- Source files to compile.sourceRoots
- Array of source root directories, the base of
the package structure for all files to compile.public boolean isAvailable()
CompilerInterface
CompilerInterface.compile(java.io.File, java.io.File[])
method
should not fail due to class not being found.isAvailable
in interface CompilerInterface
public String getName()
CompilerInterface
getName
in interface CompilerInterface
public String toString()
CompilerInterface
toString
in interface CompilerInterface
toString
in class Object
public void setExtraClassPath(String extraClassPath)
setExtraClassPath
in interface CompilerInterface
public void setAllowAssertions(boolean allow)
setAllowAssertions
in interface CompilerInterface
public void addToBootClassPath(File cp)
addToBootClassPath
in interface CompilerInterface
protected String getSourceRootString(File[] sourceRoots)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |