Merge branch 'releases/Release_2_10_Branch' into develop
[jalview.git] / src / jalview / datamodel / DBRefEntry.java
index 66a075e..a641b1b 100755 (executable)
@@ -25,8 +25,6 @@ import jalview.api.DBRefEntryI;
 public class DBRefEntry implements DBRefEntryI
 {
   String source = "", version = "", accessionId = "";
-
-  private int startRes, endRes;
   /**
    * maps from associated sequence to the database sequence's coordinate system
    */
@@ -150,6 +148,7 @@ public class DBRefEntry implements DBRefEntryI
      * otherwise the versions have to match
      */
     String otherVersion = other.getVersion();
+      
     if ((version == null || version.equals("0") || version.endsWith(":0"))
             && otherVersion != null)
     {
@@ -157,7 +156,9 @@ public class DBRefEntry implements DBRefEntryI
     }
     else
     {
-      if (!version.equalsIgnoreCase(otherVersion))
+      if (version != null
+              && (otherVersion == null || !version
+                      .equalsIgnoreCase(otherVersion)))
       {
         return false;
       }
@@ -279,28 +280,4 @@ public class DBRefEntry implements DBRefEntryI
   {
     return getSrcAccString();
   }
-
-  @Override
-  public int getStartRes()
-  {
-    return startRes;
-  }
-
-  @Override
-  public void setStartRes(int startRes)
-  {
-    this.startRes = startRes;
-  }
-
-  @Override
-  public int getEndRes()
-  {
-    return endRes;
-  }
-
-  @Override
-  public void setEndRes(int endRes)
-  {
-    this.endRes = endRes;
-  }
 }