Class JavacCompiler.Messages
- java.lang.Object
-
- org.codehaus.plexus.compiler.javac.JavacCompiler.Messages
-
- Enclosing class:
- JavacCompiler
protected static class JavacCompiler.Messages extends java.lang.ObjectMulti-language compiler messages to parse from forked javac output.- OpenJDK 8+ is delivered with 3 locales (en, ja, zh_CN).
- OpenJDK 21+ is delivered with 4 locales (en, ja, zh_CN, de).
Hoewever, due to JMS module protection, it would be necessary to run Plexus Compiler (and hence also Maven Compiler and the whole Maven JVM) withnew JavacMessages("com.sun.tools.javac.resources.javac", Locale.getDefault()) .getLocalizedString("javac.msg.proc.annotation.uncaught.exception")--add-exports jdk.compiler/com.sun.tools.javac.util=ALL-UNNAMEDon more recent JDK versions. As this cannot be reliably expected and using internal APIs - even though stable since at least JDK 8 - it is not a future-proof approach. So we refrain from doing so, even though during Plexus Compiler development it might come in handy.TODO: Check compiler.properties and javac.properties in OpenJDK javac source code for message changes, relevant new messages, new locales.
-
-
Field Summary
Fields Modifier and Type Field Description protected static java.lang.String[]ANNOTATION_PROCESSING_ERROR_HEADERSprotected static java.lang.String[]BOOT_LAYER_INIT_ERROR_HEADERSprotected static java.lang.String[]ERROR_PREFIXESprotected static java.lang.String[]FILE_A_BUG_ERROR_HEADERSprotected static java.lang.String[]IO_ERROR_HEADERSprotected static java.lang.String[]JAVAC_GENERIC_ERROR_PREFIXESprotected static java.lang.String[]MISC_PREFIXESprotected static java.lang.String[]NOTE_PREFIXESprotected static java.lang.String[]PLUGIN_ERROR_HEADERSprotected static java.lang.String[]SYSTEM_OUT_OF_RESOURCES_ERROR_HEADERSprotected static java.lang.String[]VM_INIT_ERROR_HEADERSprotected static java.lang.String[]WARNING_PREFIXES
-
Constructor Summary
Constructors Modifier Constructor Description protectedMessages()
-
-
-
Field Detail
-
ERROR_PREFIXES
protected static final java.lang.String[] ERROR_PREFIXES
-
WARNING_PREFIXES
protected static final java.lang.String[] WARNING_PREFIXES
-
NOTE_PREFIXES
protected static final java.lang.String[] NOTE_PREFIXES
-
MISC_PREFIXES
protected static final java.lang.String[] MISC_PREFIXES
-
JAVAC_GENERIC_ERROR_PREFIXES
protected static final java.lang.String[] JAVAC_GENERIC_ERROR_PREFIXES
-
VM_INIT_ERROR_HEADERS
protected static final java.lang.String[] VM_INIT_ERROR_HEADERS
-
BOOT_LAYER_INIT_ERROR_HEADERS
protected static final java.lang.String[] BOOT_LAYER_INIT_ERROR_HEADERS
-
ANNOTATION_PROCESSING_ERROR_HEADERS
protected static final java.lang.String[] ANNOTATION_PROCESSING_ERROR_HEADERS
-
FILE_A_BUG_ERROR_HEADERS
protected static final java.lang.String[] FILE_A_BUG_ERROR_HEADERS
-
SYSTEM_OUT_OF_RESOURCES_ERROR_HEADERS
protected static final java.lang.String[] SYSTEM_OUT_OF_RESOURCES_ERROR_HEADERS
-
IO_ERROR_HEADERS
protected static final java.lang.String[] IO_ERROR_HEADERS
-
PLUGIN_ERROR_HEADERS
protected static final java.lang.String[] PLUGIN_ERROR_HEADERS
-
-