Class CommitGraphWriter

java.lang.Object
org.eclipse.jgit.internal.storage.commitgraph.CommitGraphWriter

public class CommitGraphWriter extends Object
Writes a commit-graph formatted file.
Since:
6.5
  • Constructor Details

    • CommitGraphWriter

      public CommitGraphWriter(@NonNull GraphCommits graphCommits)
      Create commit-graph writer for these commits.
      Parameters:
      graphCommits - the commits which will be writen to the commit-graph.
    • CommitGraphWriter

      public CommitGraphWriter(@NonNull GraphCommits graphCommits, boolean generateChangedPathFilters)
      Create commit-graph writer for these commits.
      Parameters:
      graphCommits - the commits which will be writen to the commit-graph.
      generateChangedPathFilters - whether changed path filters are generated
  • Method Details

    • write

      public CommitGraphWriter.Stats write(@NonNull ProgressMonitor monitor, @NonNull OutputStream commitGraphStream) throws IOException
      Write commit-graph to the supplied stream.
      Parameters:
      monitor - progress monitor to report the number of items written.
      commitGraphStream - output stream of commit-graph data. The stream should be buffered by the caller. The caller is responsible for closing the stream.
      Returns:
      statistics gathered during the run
      Throws:
      IOException - if an error occurred