Is there a Java 5.0 equivalent to the Java 6.0 Compiler API? I'm trying to compile and jar some XmlBean schemas at runtime.
1 Answer
You can write the files to disk and call javac using System.exec()
Perhaps its time to updated to Java 6 or 7.
6 Comments
Joachim Sauer
I'm tempted to edit this answer to add a
<strike>-tag around "Perhaps" ;-)Mister Smith
I think it is to soon to switch to 7.
Peter Lawrey
I have been watching the developer mail-list for Java 8 and have been tempted to give it a go. ;)
Peter Lawrey
The scheduled proposed final draft (read beta) is May 2012, about seven months way. jcp.org/en/jsr/detail?id=337
Joachim Sauer
@MisterSmith: that might be (depending on your development schedule and when you plan to deploy), but I've seen far to many projects still held back on 1.4.2.
|