diff options
author | yorah <yoram.harmelin@gmail.com> | 2013-06-19 19:20:24 +0400 |
---|---|---|
committer | yorah <yoram.harmelin@gmail.com> | 2013-06-19 19:20:24 +0400 |
commit | e2aeb989779543da43401a4660f058f025f2e363 (patch) | |
tree | 6f5b3f71d3d2a3339dad13f8ac513f5f4ec84439 /LibGit2Sharp/ObjectDatabase.cs | |
parent | 7b8472d0afefb06b3668061f35baa619054e2637 (diff) |
Rename ObjectDatabase.CreateTag into ObjectDatabase.CreateTagAnnotation
Diffstat (limited to 'LibGit2Sharp/ObjectDatabase.cs')
-rw-r--r-- | LibGit2Sharp/ObjectDatabase.cs | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/LibGit2Sharp/ObjectDatabase.cs b/LibGit2Sharp/ObjectDatabase.cs index 8b4795f1..00fcdef2 100644 --- a/LibGit2Sharp/ObjectDatabase.cs +++ b/LibGit2Sharp/ObjectDatabase.cs @@ -167,9 +167,23 @@ namespace LibGit2Sharp /// <param name="target">The <see cref="GitObject"/> being pointed at.</param> /// <param name="tagger">The tagger.</param> /// <param name="message">The message.</param> - /// <returns>The created <see cref = "Commit"/>.</returns> + /// <returns>The created <see cref = "TagAnnotation"/>.</returns> + [Obsolete("This method will be removed in the next release. Please use CreateTagAnnontation(string, GitObject, Signature, string) instead.")] public virtual TagAnnotation CreateTag(string name, GitObject target, Signature tagger, string message) { + return CreateTagAnnotation(name, target, tagger, message); + } + + /// <summary> + /// Inserts a <see cref = "TagAnnotation"/> into the object database, pointing to a specific <see cref = "GitObject"/>. + /// </summary> + /// <param name="name">The name.</param> + /// <param name="target">The <see cref="GitObject"/> being pointed at.</param> + /// <param name="tagger">The tagger.</param> + /// <param name="message">The message.</param> + /// <returns>The created <see cref = "TagAnnotation"/>.</returns> + public virtual TagAnnotation CreateTagAnnotation(string name, GitObject target, Signature tagger, string message) + { string prettifiedMessage = Proxy.git_message_prettify(message); ObjectId tagId = Proxy.git_tag_annotation_create(repo.Handle, name, target, tagger, prettifiedMessage); |