diff options
author | aefimov <none@none> | 2015-10-16 19:07:08 +0300 |
---|---|---|
committer | aefimov <none@none> | 2015-10-16 19:07:08 +0300 |
commit | e68565a618ce43c2eefc697fef1244c900a0fc49 (patch) | |
tree | 3cac15e60318f0c09c4461fe2f94f418f92a1ad9 | |
parent | eb2140d572ee517bed138f858f8128f3c9b58e67 (diff) | |
download | jdk8u_jaxws-e68565a618ce43c2eefc697fef1244c900a0fc49.tar.gz |
8073519: schemagen does not report errors while generating xsd files
Reviewed-by: dfuchs
-rw-r--r-- | src/share/jaxws_classes/com/sun/tools/internal/jxc/SchemaGenerator.java | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/share/jaxws_classes/com/sun/tools/internal/jxc/SchemaGenerator.java b/src/share/jaxws_classes/com/sun/tools/internal/jxc/SchemaGenerator.java index cd4619ad..f1f675e2 100644 --- a/src/share/jaxws_classes/com/sun/tools/internal/jxc/SchemaGenerator.java +++ b/src/share/jaxws_classes/com/sun/tools/internal/jxc/SchemaGenerator.java @@ -30,6 +30,7 @@ import com.sun.tools.internal.xjc.BadCommandLineException; import com.sun.xml.internal.bind.util.Which; import javax.lang.model.SourceVersion; +import javax.tools.Diagnostic; import javax.tools.DiagnosticCollector; import javax.tools.JavaCompiler; import javax.tools.JavaFileObject; @@ -239,7 +240,12 @@ public class SchemaGenerator { if (episode != null) r.setEpisodeFile(episode); task.setProcessors(Collections.singleton(r)); - return task.call(); + boolean res = task.call(); + //Print messages generated by compiler + for (Diagnostic<? extends JavaFileObject> d : diagnostics.getDiagnostics()) { + System.err.println(d.toString()); + } + return res; } } |