summaryrefslogtreecommitdiff
path: root/include/git2/refs.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/git2/refs.h')
-rw-r--r--include/git2/refs.h19
1 files changed, 19 insertions, 0 deletions
diff --git a/include/git2/refs.h b/include/git2/refs.h
index 8eeab7e92..c9cce2212 100644
--- a/include/git2/refs.h
+++ b/include/git2/refs.h
@@ -422,7 +422,26 @@ GIT_EXTERN(int) git_reference_remove(git_repository *repo, const char *name);
*/
GIT_EXTERN(int) git_reference_list(git_strarray *array, git_repository *repo);
+/**
+ * Callback used to iterate over references
+ *
+ * @see git_reference_foreach
+ *
+ * @param reference The reference object
+ * @param payload Payload passed to git_reference_foreach
+ * @return non-zero to terminate the iteration
+ */
typedef int GIT_CALLBACK(git_reference_foreach_cb)(git_reference *reference, void *payload);
+
+/**
+ * Callback used to iterate over reference names
+ *
+ * @see git_reference_foreach_name
+ *
+ * @param name The reference name
+ * @param payload Payload passed to git_reference_foreach_name
+ * @return non-zero to terminate the iteration
+ */
typedef int GIT_CALLBACK(git_reference_foreach_name_cb)(const char *name, void *payload);
/**