public String formatKind(JCDiagnostic d, Locale l) { switch (d.getType()) { case FRAGMENT: return ""; case NOTE: return localize(l, "compiler.note.note"); case WARNING: return localize(l, "compiler.warn.warning"); case ERROR: return localize(l, "compiler.err.error"); default: throw new AssertionError("Unknown diagnostic type: " + d.getType()); } }
public boolean displaySource(JCDiagnostic d) { return config.getVisible().contains(DiagnosticPart.SOURCE) && d.getType() != FRAGMENT && d.getIntPosition() != Position.NOPOS; }