void (@NotNull PatchHunk hunk, @NotNull List<String> lines, @NotNull PatchLine.Type type, int index, boolean noNewlineAtEOF) { String line = lines.get(index); boolean isLastLine = index == lines.size() - 1; PatchLine patchLine = new PatchLine(type, line); patchLine.setSuppressNewLine(noNewlineAtEOF && isLastLine); hunk.addLine(patchLine); }