libgit2

git_diff_foreach

Version:

Iterate over a diff list issuing callbacks.

If the hunk and/or line callbacks are not NULL, then this will calculate text diffs for all files it thinks are not binary. If those are both NULL, then this will not bother with the text diffs, so it can be efficient.

Signature

int git_diff_foreach(git_diff_list *diff, void *cb_data, git_diff_file_fn file_cb, git_diff_hunk_fn hunk_cb, git_diff_data_fn line_cb);

Parameters

In
diff
void *
In
cb_data
In
file_cb
In
hunk_cb
In
line_cb

Returns

int

Versions