HighlightSeverity (@Nullable String level) { if ("error".equals(level)) { return HighlightSeverity.ERROR; } if ("warning".equals(level)) { return HighlightSeverity.WARNING; } return HighlightSeverity.WEAK_WARNING; }