String (@NotNull Project project, boolean asHtml, @NotNull @Nls String prefix, @NotNull @NlsSafe String revision, @Nullable @Nls String commitMessage) { AnnotationTooltipBuilder builder = new AnnotationTooltipBuilder(project, asHtml); builder.append(prefix); builder.append(" "); builder.append(revision); if (commitMessage != null) { builder.append(": "); builder.appendTextWithLinks(commitMessage); } return builder.toString(); }