/** * Programmatic interface to the error-prone Java compiler. * * @param args the same args which would be passed to javac on the command line * @return result from the compiler invocation */ public static Result compile(String[] args) { return builder().build().run(args); }
/** * Compiles in-process. * * @param listener listens to the diagnostics produced by error-prone * @param args the same args which would be passed to javac on the command line * @return result from the compiler invocation */ public static Result compile(DiagnosticListener<JavaFileObject> listener, String[] args) { return ErrorProneCompiler.builder().listenToDiagnostics(listener).build().run(args); }
/** * Programmatic interface to the error-prone Java compiler. * * @param args the same args which would be passed to javac on the command line * @param out a {@link PrintWriter} to which to send diagnostic output * @return result from the compiler invocation */ public static Result compile(String[] args, PrintWriter out) { return ErrorProneCompiler.builder().redirectOutputTo(out).build().run(args); }
/** * Programmatic interface to the error-prone Java compiler. * * @param args the same args which would be passed to javac on the command line * @return result from the compiler invocation */ public static Result compile(String[] args) { return builder().build().run(args); }
/** * Compiles in-process. * * @param listener listens to the diagnostics produced by error-prone * @param args the same args which would be passed to javac on the command line * @return result from the compiler invocation */ public static Result compile(DiagnosticListener<JavaFileObject> listener, String[] args) { return ErrorProneCompiler.builder().listenToDiagnostics(listener).build().run(args); }
/** * Programmatic interface to the error-prone Java compiler. * * @param args the same args which would be passed to javac on the command line * @param out a {@link PrintWriter} to which to send diagnostic output * @return result from the compiler invocation */ public static Result compile(String[] args, PrintWriter out) { return ErrorProneCompiler.builder().redirectOutputTo(out).build().run(args); }