summaryrefslogtreecommitdiff
path: root/include/git2
diff options
context:
space:
mode:
authorVicent Martí <tanoku@gmail.com>2011-06-06 18:33:38 -0700
committerVicent Martí <tanoku@gmail.com>2011-06-06 18:33:38 -0700
commit1097dacd7d796e0c56492b717baf153ba88dff65 (patch)
tree75e58cc0e0e18fac2142a70d13c76156c33b1e59 /include/git2
parent9b1692ebfcc4b91e8171d0614530133ac2b032e1 (diff)
parentff9a4c130d09629af86a90ac64a89198faf4ffd8 (diff)
downloadlibgit2-1097dacd7d796e0c56492b717baf153ba88dff65.tar.gz
Merge pull request #240 from Romain-Geissler/tree-object-type
Tree: Added a function that returns the type of a tree entry.
Diffstat (limited to 'include/git2')
-rw-r--r--include/git2/tree.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/include/git2/tree.h b/include/git2/tree.h
index a98d2d6e8..80b90604f 100644
--- a/include/git2/tree.h
+++ b/include/git2/tree.h
@@ -146,6 +146,14 @@ GIT_EXTERN(const char *) git_tree_entry_name(const git_tree_entry *entry);
GIT_EXTERN(const git_oid *) git_tree_entry_id(const git_tree_entry *entry);
/**
+ * Get the type of the object pointed by the entry
+ *
+ * @param entry a tree entry
+ * @return the type of the pointed object
+ */
+GIT_EXTERN(git_otype) git_tree_entry_type(const git_tree_entry *entry);
+
+/**
* Convert a tree entry to the git_object it points too.
*
* @param object pointer to the converted object