From 61c62b2455f3e25a14587aa37e4a2949184041a2 Mon Sep 17 00:00:00 2001 From: Jim Procter Date: Tue, 17 Mar 2015 15:56:05 +0000 Subject: [PATCH] JAL-1617 toString for DBRefEntry --- src/jalview/datamodel/DBRefEntry.java | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/src/jalview/datamodel/DBRefEntry.java b/src/jalview/datamodel/DBRefEntry.java index bc1d610..16bd252 100755 --- a/src/jalview/datamodel/DBRefEntry.java +++ b/src/jalview/datamodel/DBRefEntry.java @@ -72,9 +72,13 @@ public class DBRefEntry public boolean equals(DBRefEntry entry) { if (entry == this) + { return true; + } if (entry == null) + { return false; + } if (equalRef(entry) && ((map == null && entry.map == null) || (map != null && entry.map != null && map.equals(entry.map)))) @@ -97,7 +101,9 @@ public class DBRefEntry return false; } if (entry == this) + { return true; + } if ((source != null && entry.source != null && source .equalsIgnoreCase(entry.source)) && (accessionId != null && entry.accessionId != null && accessionId @@ -183,4 +189,9 @@ public class DBRefEntry return ((source != null) ? source : "") + ":" + ((accessionId != null) ? accessionId : ""); } + + public String toString() + { + return getSrcAccString(); + } } -- 1.7.10.2