public class JavaCompilationEnvironment extends Object
javac compilation environment.
Note that this class is not used yet... we should refactor so that the transpiler uses it instead of inlined javac management.
| Modifier and Type | Field and Description |
|---|---|
com.sun.tools.javac.main.JavaCompiler |
compiler
The Java compiler.
|
JSweetContext |
context
The compilation context.
|
JavaFileManager |
fileManager
The Java file manager.
|
com.sun.tools.javac.util.Log |
log
The log object.
|
com.sun.tools.javac.util.Names |
names
The compiler's name holder.
|
com.sun.tools.javac.util.Options |
options
The compiler's options.
|
com.sun.tools.javac.code.Symtab |
symtab
The compiler's symbol table.
|
com.sun.tools.javac.code.Types |
types
The compiler's type holder.
|
| Modifier and Type | Method and Description |
|---|---|
static JavaCompilationEnvironment |
create(JSweetOptions jsweetOptions,
String classPath)
Creates a new compilation environment with the given options and
classpath.
|
List<com.sun.tools.javac.tree.JCTree.JCCompilationUnit> |
parseAndAttributeJavaFiles(List<File> javaFiles)
Parses and attributes the given files within this compilation
environment.
|
public final JavaFileManager fileManager
public final com.sun.tools.javac.main.JavaCompiler compiler
public final JSweetContext context
public final com.sun.tools.javac.util.Log log
public final com.sun.tools.javac.code.Types types
public final com.sun.tools.javac.code.Symtab symtab
public final com.sun.tools.javac.util.Names names
public final com.sun.tools.javac.util.Options options
public static JavaCompilationEnvironment create(JSweetOptions jsweetOptions, String classPath)
public List<com.sun.tools.javac.tree.JCTree.JCCompilationUnit> parseAndAttributeJavaFiles(List<File> javaFiles) throws IOException
IOException