From: jprocter Date: Fri, 18 Jan 2013 15:55:32 +0000 (+0000) Subject: JAL-1238 method to test if DAS source is a primary reference source X-Git-Tag: Jalview_2_9~253^2~2 X-Git-Url: http://source.jalview.org/gitweb/?a=commitdiff_plain;h=d96dccc4447e64d0fae5f5e8c77ba79737ba0bb1;p=jalview.git JAL-1238 method to test if DAS source is a primary reference source --- diff --git a/src/jalview/ws/dbsources/das/api/jalviewSourceI.java b/src/jalview/ws/dbsources/das/api/jalviewSourceI.java index 1511e6b..308bc21 100644 --- a/src/jalview/ws/dbsources/das/api/jalviewSourceI.java +++ b/src/jalview/ws/dbsources/das/api/jalviewSourceI.java @@ -74,4 +74,10 @@ public interface jalviewSourceI */ boolean isNewerThan(jalviewSourceI jalviewSourceI); + /** + * test if the source is a reference source for the authority + * @return + */ + boolean isReferenceSource(); + } diff --git a/src/jalview/ws/dbsources/das/datamodel/DasSequenceSource.java b/src/jalview/ws/dbsources/das/datamodel/DasSequenceSource.java index 7bb6436..9650b8c 100644 --- a/src/jalview/ws/dbsources/das/datamodel/DasSequenceSource.java +++ b/src/jalview/ws/dbsources/das/datamodel/DasSequenceSource.java @@ -99,6 +99,7 @@ public class DasSequenceSource extends DbSourceProxyImpl implements throw new Exception("Source " + source.getTitle() + " does not support the sequence command."); } + this.tier = 1+((jsrc.isLocal() || jsrc.isReferenceSource()) ? 0 : 1); this.source = source; this.dbname = dbname; this.dbrefname = dbrefname.toUpperCase();