X-Git-Url: http://source.jalview.org/gitweb/?a=blobdiff_plain;ds=sidebyside;f=src%2Fjalview%2Fext%2Fensembl%2FEnsemblSeqProxy.java;h=001e18e73d2f7a6d9526091ab041d6f05c94c61d;hb=456e5c765ac1e85336fd9f9b1a35453069bb2298;hp=648272c2a98bfae54643e38824d1a6497d2e5bf8;hpb=6a102719db960765b1e7111b7f51227248eaa802;p=jalview.git diff --git a/src/jalview/ext/ensembl/EnsemblSeqProxy.java b/src/jalview/ext/ensembl/EnsemblSeqProxy.java index 648272c..001e18e 100644 --- a/src/jalview/ext/ensembl/EnsemblSeqProxy.java +++ b/src/jalview/ext/ensembl/EnsemblSeqProxy.java @@ -62,8 +62,6 @@ import org.json.simple.parser.ParseException; */ public abstract class EnsemblSeqProxy extends EnsemblRestClient { - protected static final String NAME = "Name"; - protected static final String DESCRIPTION = "description"; /* @@ -867,9 +865,8 @@ public abstract class EnsemblSeqProxy extends EnsemblRestClient protected boolean featureMayBelong(SequenceFeature sf, String identifier) { String parent = (String) sf.getValue(PARENT); - // using contains to allow for prefix "gene:", "transcript:" etc if (parent != null - && !parent.toUpperCase().contains(identifier.toUpperCase())) + && !parent.equalsIgnoreCase(identifier)) { // this genomic feature belongs to a different transcript return false; @@ -877,6 +874,9 @@ public abstract class EnsemblSeqProxy extends EnsemblRestClient return true; } + /** + * Answers a short description of the sequence fetcher + */ @Override public String getDescription() { @@ -915,10 +915,14 @@ public abstract class EnsemblSeqProxy extends EnsemblRestClient /** * Answers true if the feature type is either 'NMD_transcript_variant' or - * 'transcript' or one of its sub-types in the Sequence Ontology. This is - * needed because NMD_transcript_variant behaves like 'transcript' in Ensembl + * 'transcript' (or one of its sub-types in the Sequence Ontology). This is + * because NMD_transcript_variant behaves like 'transcript' in Ensembl * although strictly speaking it is not (it is a sub-type of * sequence_variant). + *

+ * (This test was needed when fetching transcript features as GFF. As we are + * now fetching as JSON, all features have type 'transcript' so the check for + * NMD_transcript_variant is redundant. Left in for any future case arising.) * * @param featureType * @return