{"thread":{"id":"19261","subject":"[EGIT PATCH] Provide a more JavaBeans-style 'getName' accessor for the id Signed-off-by: Alex Blewitt <alex.blewitt@gmail.com>","startedAt":"2009-05-09T22:57:34Z","lastAt":"2009-08-12T19:09:29Z","messageCount":9,"participants":["Alex Blewitt","Shawn O. Pearce","Robin Rosenberg"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"113429","messageId":"1241909854-11498-1-git-send-email-alex.blewitt@gmail.com","threadId":"19261","inReplyTo":null,"subject":"[EGIT PATCH] Provide a more JavaBeans-style 'getName' accessor for the id Signed-off-by: Alex Blewitt <alex.blewitt@gmail.com>","fromName":"Alex Blewitt","fromEmail":"alex.blewitt@gmail.com","sentAt":"2009-05-09T22:57:34Z","receivedAt":"2009-05-09T22:57:34Z","isPatch":true,"sender":{"key":"alex.blewitt@gmail.com","avatar":"https://gravatar.com/avatar/fb95a3b593b290f03a8d3b022c20b2825205702c5651f731f65d33512dfe6ab2?d=mp&s=160"},"body":"---\n .../src/org/spearce/jgit/lib/AnyObjectId.java      |    6 ++++++\n 1 files changed, 6 insertions(+), 0 deletions(-)\n\ndiff --git a/org.spearce.jgit/src/org/spearce/jgit/lib/AnyObjectId.java b/org.spearce.jgit/src/org/spearce/jgit/lib/AnyObjectId.java\nindex acb3cb5..015042a 100644\n--- a/org.spearce.jgit/src/org/spearce/jgit/lib/AnyObjectId.java\n+++ b/org.spearce.jgit/src/org/spearce/jgit/lib/AnyObjectId.java\n@@ -448,6 +448,12 @@ public final String name() {\n \t}\n \n \t/**\n+\t * @return string form of the SHA-1, in lower case hexadecimal.\n+\t */\n+\tpublic final String getName() {\n+\t\treturn name();\n+\t}\n+\t/**\n \t * Return unique abbreviation (prefix) of this object SHA-1.\n \t * <p>\n \t * This method is a utility for <code>abbreviate(repo, 8)</code>.\n-- \n1.6.2.2\n"},{"id":"113489","messageId":"20090510211900.GB30527@spearce.org","threadId":"19261","inReplyTo":"1241909854-11498-1-git-send-email-alex.blewitt@gmail.com","subject":"Re: [EGIT PATCH] Provide a more JavaBeans-style 'getName' accessor for the id Signed-off-by: Alex Blewitt <alex.blewitt@gmail.com>","fromName":"Shawn O. Pearce","fromEmail":"spearce@spearce.org","sentAt":"2009-05-10T21:19:00Z","receivedAt":"2009-05-10T21:19:00Z","isPatch":true,"sender":{"key":"spearce@spearce.org","avatar":"https://avatars.githubusercontent.com/u/34844?v=4"},"body":"Alex Blewitt <alex.blewitt@gmail.com> wrote:\n>  \t/**\n> +\t * @return string form of the SHA-1, in lower case hexadecimal.\n> +\t */\n> +\tpublic final String getName() {\n> +\t\treturn name();\n> +\t}\n> +\t/**\n\nOk, but how about unit tests?\n\n-- \nShawn.\n"},{"id":"120177","messageId":"20090810155207.GW1033@spearce.org","threadId":"19261","inReplyTo":"1241909854-11498-1-git-send-email-alex.blewitt@gmail.com","subject":"Re: [EGIT PATCH] Provide a more JavaBeans-style 'getName' accessor for the id Signed-off-by: Alex Blewitt <alex.blewitt@gmail.com>","fromName":"Shawn O. Pearce","fromEmail":"spearce@spearce.org","sentAt":"2009-08-10T15:52:07Z","receivedAt":"2009-08-10T15:52:07Z","isPatch":true,"sender":{"key":"spearce@spearce.org","avatar":"https://avatars.githubusercontent.com/u/34844?v=4"},"body":"Alex Blewitt <alex.blewitt@gmail.com> wrote:\n> ---\n>  .../src/org/spearce/jgit/lib/AnyObjectId.java      |    6 ++++++\n>  1 files changed, 6 insertions(+), 0 deletions(-)\n> \n> diff --git a/org.spearce.jgit/src/org/spearce/jgit/lib/AnyObjectId.java b/org.spearce.jgit/src/org/spearce/jgit/lib/AnyObjectId.java\n> index acb3cb5..015042a 100644\n> --- a/org.spearce.jgit/src/org/spearce/jgit/lib/AnyObjectId.java\n> +++ b/org.spearce.jgit/src/org/spearce/jgit/lib/AnyObjectId.java\n> @@ -448,6 +448,12 @@ public final String name() {\n>  \t}\n>  \n>  \t/**\n> +\t * @return string form of the SHA-1, in lower case hexadecimal.\n> +\t */\n> +\tpublic final String getName() {\n> +\t\treturn name();\n> +\t}\n\nObviously you didn't compile test this in JGit:\n\n./org/spearce/jgit/revwalk/RevTag.java:206: getName() in\norg.spearce.jgit.revwalk.RevTag cannot override getName() in\norg.spearce.jgit.lib.AnyObjectId; overridden method is final\n\n:-(\n\n-- \nShawn.\n"},{"id":"120200","messageId":"A85D4F42-88A0-4508-80A2-22F069CB2F49@gmail.com","threadId":"19261","inReplyTo":"20090810155207.GW1033@spearce.org","subject":"Re: [EGIT PATCH] Provide a more JavaBeans-style 'getName' accessor for the id Signed-off-by: Alex Blewitt <alex.blewitt@gmail.com>","fromName":"Alex Blewitt","fromEmail":"alex.blewitt@gmail.com","sentAt":"2009-08-10T18:11:09Z","receivedAt":"2009-08-10T18:11:09Z","isPatch":true,"sender":{"key":"alex.blewitt@gmail.com","avatar":"https://gravatar.com/avatar/fb95a3b593b290f03a8d3b022c20b2825205702c5651f731f65d33512dfe6ab2?d=mp&s=160"},"body":"That was ages ago that I submitted that patch. I'm pretty sure that it  \ncompiled at the time for the version of JGit that I had back then.\n\nSent from my (new) iPhone\n\nOn 10 Aug 2009, at 16:52, \"Shawn O. Pearce\" <spearce@spearce.org> wrote:\n\n> Alex Blewitt <alex.blewitt@gmail.com> wrote:\n>> ---\n>> .../src/org/spearce/jgit/lib/AnyObjectId.java      |    6 ++++++\n>> 1 files changed, 6 insertions(+), 0 deletions(-)\n>>\n>> diff --git a/org.spearce.jgit/src/org/spearce/jgit/lib/ \n>> AnyObjectId.java b/org.spearce.jgit/src/org/spearce/jgit/lib/ \n>> AnyObjectId.java\n>> index acb3cb5..015042a 100644\n>> --- a/org.spearce.jgit/src/org/spearce/jgit/lib/AnyObjectId.java\n>> +++ b/org.spearce.jgit/src/org/spearce/jgit/lib/AnyObjectId.java\n>> @@ -448,6 +448,12 @@ public final String name() {\n>>    }\n>>\n>>    /**\n>> +     * @return string form of the SHA-1, in lower case hexadecimal.\n>> +     */\n>> +    public final String getName() {\n>> +        return name();\n>> +    }\n>\n> Obviously you didn't compile test this in JGit:\n>\n> ./org/spearce/jgit/revwalk/RevTag.java:206: getName() in\n> org.spearce.jgit.revwalk.RevTag cannot override getName() in\n> org.spearce.jgit.lib.AnyObjectId; overridden method is final\n>\n> :-(\n>\n> -- \n> Shawn.\n"},{"id":"120201","messageId":"E861EAC5-150C-4CF8-AD0F-EBF15CEAE114@gmail.com","threadId":"19261","inReplyTo":"20090810155207.GW1033@spearce.org","subject":"Re: [EGIT PATCH] Provide a more JavaBeans-style 'getName' accessor for the id Signed-off-by: Alex Blewitt <alex.blewitt@gmail.com>","fromName":"Alex Blewitt","fromEmail":"alex.blewitt@gmail.com","sentAt":"2009-08-10T18:19:05Z","receivedAt":"2009-08-10T18:19:05Z","isPatch":true,"sender":{"key":"alex.blewitt@gmail.com","avatar":"https://gravatar.com/avatar/fb95a3b593b290f03a8d3b022c20b2825205702c5651f731f65d33512dfe6ab2?d=mp&s=160"},"body":"That patch was originally mailed on the 11th May. Has it taken until  \nnow to notice the problem, or was the other method added in the last  \nmonth or so? If I'm to blame, I apologise but didn't note any compile  \ntime issues at the time.\n\nAlex\n\nSent from my (new) iPhone\n\nOn 10 Aug 2009, at 16:52, \"Shawn O. Pearce\" <spearce@spearce.org> wrote:\n\n> Alex Blewitt <alex.blewitt@gmail.com> wrote:\n>> ---\n>> .../src/org/spearce/jgit/lib/AnyObjectId.java      |    6 ++++++\n>> 1 files changed, 6 insertions(+), 0 deletions(-)\n>>\n>> diff --git a/org.spearce.jgit/src/org/spearce/jgit/lib/ \n>> AnyObjectId.java b/org.spearce.jgit/src/org/spearce/jgit/lib/ \n>> AnyObjectId.java\n>> index acb3cb5..015042a 100644\n>> --- a/org.spearce.jgit/src/org/spearce/jgit/lib/AnyObjectId.java\n>> +++ b/org.spearce.jgit/src/org/spearce/jgit/lib/AnyObjectId.java\n>> @@ -448,6 +448,12 @@ public final String name() {\n>>    }\n>>\n>>    /**\n>> +     * @return string form of the SHA-1, in lower case hexadecimal.\n>> +     */\n>> +    public final String getName() {\n>> +        return name();\n>> +    }\n>\n> Obviously you didn't compile test this in JGit:\n>\n> ./org/spearce/jgit/revwalk/RevTag.java:206: getName() in\n> org.spearce.jgit.revwalk.RevTag cannot override getName() in\n> org.spearce.jgit.lib.AnyObjectId; overridden method is final\n>\n> :-(\n>\n> -- \n> Shawn.\n"},{"id":"120207","messageId":"20090810205907.GY1033@spearce.org","threadId":"19261","inReplyTo":"E861EAC5-150C-4CF8-AD0F-EBF15CEAE114@gmail.com","subject":"Re: [EGIT PATCH] Provide a more JavaBeans-style 'getName' accessor for the id Signed-off-by: Alex Blewitt <alex.blewitt@gmail.com>","fromName":"Shawn O. Pearce","fromEmail":"spearce@spearce.org","sentAt":"2009-08-10T20:59:07Z","receivedAt":"2009-08-10T20:59:07Z","isPatch":true,"sender":{"key":"spearce@spearce.org","avatar":"https://avatars.githubusercontent.com/u/34844?v=4"},"body":"Alex Blewitt <alex.blewitt@gmail.com> wrote:\n> That patch was originally mailed on the 11th May. Has it taken until now \n> to notice the problem, or was the other method added in the last month or \n> so? If I'm to blame, I apologise but didn't note any compile time issues \n> at the time.\n\nArrgh, you are right, I lost this patch in my inbox, and in the\ninterm we applied new features to RevTag which added getName there.\n\n> On 10 Aug 2009, at 16:52, \"Shawn O. Pearce\" <spearce@spearce.org> wrote:\n>> Obviously you didn't compile test this in JGit:\n\nNever mind.\n\n>> ./org/spearce/jgit/revwalk/RevTag.java:206: getName() in\n>> org.spearce.jgit.revwalk.RevTag cannot override getName() in\n>> org.spearce.jgit.lib.AnyObjectId; overridden method is final\n\nI can't apply this patch because getName() on RevTag is already\ndefined with a different meaning.  :-(\n\n-- \nShawn.\n"},{"id":"120384","messageId":"8ACC6C83-75FD-477C-9083-96CA426FC069@gmail.com","threadId":"19261","inReplyTo":"20090810205907.GY1033@spearce.org","subject":"Re: [EGIT PATCH] Provide a more JavaBeans-style 'getName' accessor for the id Signed-off-by: Alex Blewitt <alex.blewitt@gmail.com>","fromName":"Alex Blewitt","fromEmail":"alex.blewitt@gmail.com","sentAt":"2009-08-11T12:53:38Z","receivedAt":"2009-08-11T12:53:38Z","isPatch":true,"sender":{"key":"alex.blewitt@gmail.com","avatar":"https://gravatar.com/avatar/fb95a3b593b290f03a8d3b022c20b2825205702c5651f731f65d33512dfe6ab2?d=mp&s=160"},"body":"On 10 Aug 2009, at 21:59, \"Shawn O.\" <spearce@spearce.org> wrote:\n\n> Alex Blewitt <alex.blewitt@gmail.com> wrote:\n>> That patch was originally mailed on the 11th May. Has it taken  \n>> until now\n>> to notice the problem, or was the other method added in the last  \n>> month or\n>> so? If I'm to blame, I apologise but didn't note any compile time  \n>> issues\n>> at the time.\n>\n> Arrgh, you are right, I lost this patch in my inbox, and in the\n> interm we applied new features to RevTag which added getName there. .\n>\n>>> ./org/spearce/jgit/revwalk/RevTag.java:206: getName() in\n>>> org.spearce.jgit.revwalk.RevTag cannot override getName() in\n>>> org.spearce.jgit.lib.AnyObjectId; overridden method is final\n>\n> I can't apply this patch because getName() on RevTag is already\n> defined with a different meaning.  :-(\n\nThat sounds dangerous. We now have a .name() and a .getName() with  \ndifferent semantics. Can we not change the RevTag method name to  \nsomething else so that we dont have an inconsistency?\n>\n\nAlex \n"},{"id":"120406","messageId":"20090812142049.GA1033@spearce.org","threadId":"19261","inReplyTo":"8ACC6C83-75FD-477C-9083-96CA426FC069@gmail.com","subject":"Re: [EGIT PATCH] Provide a more JavaBeans-style 'getName' accessor for the id Signed-off-by: Alex Blewitt <alex.blewitt@gmail.com>","fromName":"Shawn O. Pearce","fromEmail":"spearce@spearce.org","sentAt":"2009-08-12T14:20:49Z","receivedAt":"2009-08-12T14:20:49Z","isPatch":true,"sender":{"key":"spearce@spearce.org","avatar":"https://avatars.githubusercontent.com/u/34844?v=4"},"body":"Alex Blewitt <alex.blewitt@gmail.com> wrote:\n> On 10 Aug 2009, at 21:59, \"Shawn O.\" <spearce@spearce.org> wrote:\n>>\n>>>> ./org/spearce/jgit/revwalk/RevTag.java:206: getName() in\n>>>> org.spearce.jgit.revwalk.RevTag cannot override getName() in\n>>>> org.spearce.jgit.lib.AnyObjectId; overridden method is final\n>>\n>> I can't apply this patch because getName() on RevTag is already\n>> defined with a different meaning.  :-(\n>\n> That sounds dangerous. We now have a .name() and a .getName() with  \n> different semantics. Can we not change the RevTag method name to  \n> something else so that we dont have an inconsistency?\n\nGood point.  We didn't think that RevTag.getName method through\nvery well.  Rename it to getTagName() ?\n\n-- \nShawn.\n"},{"id":"120433","messageId":"200908122109.29560.robin.rosenberg.lists@dewire.com","threadId":"19261","inReplyTo":"20090812142049.GA1033@spearce.org","subject":"Re: [EGIT PATCH] Provide a more JavaBeans-style 'getName' accessor for the id Signed-off-by: Alex Blewitt <alex.blewitt@gmail.com>","fromName":"Robin Rosenberg","fromEmail":"robin.rosenberg.lists@dewire.com","sentAt":"2009-08-12T19:09:29Z","receivedAt":"2009-08-12T19:09:29Z","isPatch":true,"sender":{"key":"robin.rosenberg@dewire.com","avatar":"https://avatars.githubusercontent.com/u/46357?v=4"},"body":"onsdag 12 augusti 2009 16:20:49 skrev \"Shawn O. Pearce\" <spearce@spearce.org>:\n> Alex Blewitt <alex.blewitt@gmail.com> wrote:\n> > On 10 Aug 2009, at 21:59, \"Shawn O.\" <spearce@spearce.org> wrote:\n> >>\n> >>>> ./org/spearce/jgit/revwalk/RevTag.java:206: getName() in\n> >>>> org.spearce.jgit.revwalk.RevTag cannot override getName() in\n> >>>> org.spearce.jgit.lib.AnyObjectId; overridden method is final\n> >>\n> >> I can't apply this patch because getName() on RevTag is already\n> >> defined with a different meaning.  :-(\n> >\n> > That sounds dangerous. We now have a .name() and a .getName() with  \n> > different semantics. Can we not change the RevTag method name to  \n> > something else so that we dont have an inconsistency?\n> \n> Good point.  We didn't think that RevTag.getName method through\n> very well.  Rename it to getTagName() ?\n\nOk with me.\n\n-- robin\n"}]}