git://source.jalview.org
/
jalview.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge branch 'develop' into merge_JAL-2110
[jalview.git]
/
src
/
jalview
/
datamodel
/
xdb
/
embl
/
EmblEntry.java
diff --git
a/src/jalview/datamodel/xdb/embl/EmblEntry.java
b/src/jalview/datamodel/xdb/embl/EmblEntry.java
index
f8c0bbe
..
5409d5b
100644
(file)
--- a/
src/jalview/datamodel/xdb/embl/EmblEntry.java
+++ b/
src/jalview/datamodel/xdb/embl/EmblEntry.java
@@
-198,10
+198,15
@@
public class EmblEntry
retrievedref.setMap(new Mapping(null, new int[] { 1, dna.getLength() },
new int[] { 1, dna.getLength() }, 1, 1));
retrievedref.setMap(new Mapping(null, new int[] { 1, dna.getLength() },
new int[] { 1, dna.getLength() }, 1, 1));
+
+ /*
+ * transform EMBL Database refs to canonical form
+ */
if (dbRefs != null)
{
for (DBRefEntry dbref : dbRefs)
{
if (dbRefs != null)
{
for (DBRefEntry dbref : dbRefs)
{
+ dbref.setSource(DBRefUtils.getCanonicalName(dbref.getSource()));
dna.addDBRef(dbref);
}
}
dna.addDBRef(dbref);
}
}
@@
-211,13
+216,6
@@
public class EmblEntry
{
for (EmblFeature feature : features)
{
{
for (EmblFeature feature : features)
{
- if (feature.dbRefs != null)
- {
- for (DBRefEntry dbref : feature.dbRefs)
- {
- dna.addDBRef(dbref);
- }
- }
if (FeatureProperties.isCodingFeature(sourceDb, feature.getName()))
{
parseCodingFeature(feature, sourceDb, dna, peptides, matcher);
if (FeatureProperties.isCodingFeature(sourceDb, feature.getName()))
{
parseCodingFeature(feature, sourceDb, dna, peptides, matcher);
@@
-248,6
+246,8
@@
public class EmblEntry
* parent dna sequence for this record
* @param peptides
* list of protein product sequences for Embl entry
* parent dna sequence for this record
* @param peptides
* list of protein product sequences for Embl entry
+ * @param matcher
+ * helper to match xrefs in already retrieved sequences
*/
void parseCodingFeature(EmblFeature feature, String sourceDb,
SequenceI dna, List<SequenceI> peptides, SequenceIdMatcher matcher)
*/
void parseCodingFeature(EmblFeature feature, String sourceDb,
SequenceI dna, List<SequenceI> peptides, SequenceIdMatcher matcher)
@@
-428,6
+428,9
@@
public class EmblEntry
boolean mappingUsed = false;
for (DBRefEntry ref : feature.dbRefs)
{
boolean mappingUsed = false;
for (DBRefEntry ref : feature.dbRefs)
{
+ /*
+ * ensure UniProtKB/Swiss-Prot converted to UNIPROT
+ */
ref.setSource(DBRefUtils.getCanonicalName(ref.getSource()));
if (ref.getSource().equals(DBRefSource.UNIPROT))
{
ref.setSource(DBRefUtils.getCanonicalName(ref.getSource()));
if (ref.getSource().equals(DBRefSource.UNIPROT))
{