Saideira
Saideira

Reputation: 2404

API for Java backend

Is there an API for the javac backend? Instead of hacking the call to main with command line args and what not like they do it here. Ideally I'd like to specify in/out streams for source and generated bytecode - do not want to deal with classloaders and class paths headache.

I couldn't find any javadoc for the com.sun.tools.javac either.

Upvotes: 0

Views: 132

Answers (1)

Michael Borgwardt
Michael Borgwardt

Reputation: 346260

Take a look at javax.tools.JavaCompiler (available since Java 6).

Upvotes: 2

Related Questions