1 Clazz.declarePackage ("jalview.datamodel");
\r
2 Clazz.load (["jalview.datamodel.ASequence", "$.SequenceI", "jalview.jsdev.RegExp"], "jalview.datamodel.Sequence", ["jalview.analysis.AlignSeq", "jalview.datamodel.AlignmentAnnotation", "$.DBRefEntry", "$.DBRefSource", "$.PDBEntry", "$.SequenceFeature", "jalview.schemes.ResidueProperties", "jalview.util.Comparison", "$.StringUtils", "java.lang.StringBuffer", "java.util.ArrayList", "$.Vector"], function () {
\r
3 c$ = Clazz.decorateAsClass (function () {
\r
4 this.datasetSequence = null;
\r
6 this.sequence = null;
\r
7 this.description = null;
\r
11 this.vamsasId = null;
\r
14 this.annotation = null;
\r
16 this.sequenceFeatures = null;
\r
17 this.limitrx = null;
\r
19 Clazz.instantialize (this, arguments);
\r
20 }, jalview.datamodel, "Sequence", jalview.datamodel.ASequence, jalview.datamodel.SequenceI);
\r
21 Clazz.prepareFields (c$, function () {
\r
22 this.limitrx = jalview.jsdev.RegExp.newRegex (["[/][0-9]{1,}[-][0-9]{1,}$"]);
\r
23 this.endrx = jalview.jsdev.RegExp.newRegex (["[0-9]{1,}$"]);
\r
25 Clazz.makeConstructor (c$,
\r
26 function (name, sequence, start, end) {
\r
27 Clazz.superConstructor (this, jalview.datamodel.Sequence, []);
\r
28 this.initSeqAndName (name, sequence.toCharArray (), start, end);
\r
30 Clazz.makeConstructor (c$,
\r
31 function (name, sequence, start, end) {
\r
32 Clazz.superConstructor (this, jalview.datamodel.Sequence, []);
\r
33 this.initSeqAndName (name, sequence, start, end);
\r
35 Clazz.defineMethod (c$, "initSeqAndName",
\r
36 function (name2, sequence2, start2, end2) {
\r
38 this.sequence = sequence2;
\r
39 this.start = start2;
\r
42 this.checkValidRange ();
\r
44 Clazz.defineMethod (c$, "parseId",
\r
46 if (this.name == null) {
\r
47 System.err.println ("POSSIBLE IMPLEMENTATION ERROR: null sequence name passed to constructor.");
\r
49 }if (this.limitrx.search (this.name)) {
\r
50 this.name = this.limitrx.left ();
\r
51 this.endrx.search (this.limitrx.stringMatched ());
\r
52 this.setStart (Integer.parseInt (this.limitrx.stringMatched ().substring (1, this.endrx.matchedFrom () - 1)));
\r
53 this.setEnd (Integer.parseInt (this.endrx.stringMatched ()));
\r
55 Clazz.defineMethod (c$, "checkValidRange",
\r
59 for (var j = 0; j < this.sequence.length; j++) {
\r
60 if (!jalview.util.Comparison.isGap (this.sequence[j])) {
\r
64 endRes += this.start - 1;
\r
65 }if (this.end < endRes) {
\r
68 Clazz.makeConstructor (c$,
\r
69 function (name, sequence) {
\r
70 this.construct (name, sequence, 1, -1);
\r
72 Clazz.makeConstructor (c$,
\r
74 this.construct (seq, seq.getAnnotation ());
\r
75 }, "jalview.datamodel.SequenceI");
\r
76 Clazz.makeConstructor (c$,
\r
77 function (seq, alAnnotation) {
\r
78 Clazz.superConstructor (this, jalview.datamodel.Sequence, []);
\r
79 this.initSeqFrom (seq, alAnnotation);
\r
80 }, "jalview.datamodel.SequenceI,~A");
\r
81 Clazz.defineMethod (c$, "initSeqFrom",
\r
82 function (seq, alAnnotation) {
\r
83 this.initSeqAndName (seq.getName (), seq.getSequence (), seq.getStart (), seq.getEnd ());
\r
84 this.description = seq.getDescription ();
\r
85 if (seq.getSequenceFeatures () != null) {
\r
86 var sf = seq.getSequenceFeatures ();
\r
87 for (var i = 0; i < sf.length; i++) {
\r
88 this.addSequenceFeature ( new jalview.datamodel.SequenceFeature (sf[i]));
\r
90 }this.setDatasetSequence (seq.getDatasetSequence ());
\r
91 if (this.datasetSequence == null && seq.getDBRef () != null) {
\r
92 var dbr = seq.getDBRef ();
\r
93 for (var i = 0; i < dbr.length; i++) {
\r
94 this.addDBRef ( new jalview.datamodel.DBRefEntry (dbr[i]));
\r
96 }if (seq.getAnnotation () != null) {
\r
97 var sqann = seq.getAnnotation ();
\r
98 for (var i = 0; i < sqann.length; i++) {
\r
99 if (sqann[i] == null) {
\r
101 }var found = (alAnnotation == null);
\r
103 for (var apos = 0; !found && apos < alAnnotation.length; apos++) {
\r
104 found = (alAnnotation[apos] === sqann[i]);
\r
107 var newann = new jalview.datamodel.AlignmentAnnotation (sqann[i]);
\r
108 this.addAlignmentAnnotation (newann);
\r
110 }if (seq.getPDBId () != null) {
\r
111 var ids = seq.getPDBId ();
\r
112 var e = ids.elements ();
\r
113 while (e.hasMoreElements ()) {
\r
114 this.addPDBId ( new jalview.datamodel.PDBEntry (e.nextElement ()));
\r
116 }}, "jalview.datamodel.SequenceI,~A");
\r
117 Clazz.defineMethod (c$, "setSequenceFeatures",
\r
118 function (features) {
\r
119 this.sequenceFeatures = features;
\r
121 Clazz.overrideMethod (c$, "addSequenceFeature",
\r
123 if (this.sequenceFeatures == null) {
\r
124 this.sequenceFeatures = new Array (0);
\r
125 }for (var i = 0; i < this.sequenceFeatures.length; i++) {
\r
126 if (this.sequenceFeatures[i].equals (sf)) {
\r
129 var temp = new Array (this.sequenceFeatures.length + 1);
\r
130 System.arraycopy (this.sequenceFeatures, 0, temp, 0, this.sequenceFeatures.length);
\r
131 temp[this.sequenceFeatures.length] = sf;
\r
132 this.sequenceFeatures = temp;
\r
133 }, "jalview.datamodel.SequenceFeature");
\r
134 Clazz.overrideMethod (c$, "deleteFeature",
\r
136 if (this.sequenceFeatures == null) {
\r
139 for (index = 0; index < this.sequenceFeatures.length; index++) {
\r
140 if (this.sequenceFeatures[index].equals (sf)) {
\r
143 if (index == this.sequenceFeatures.length) {
\r
145 }var sfLength = this.sequenceFeatures.length;
\r
146 if (sfLength < 2) {
\r
147 this.sequenceFeatures = null;
\r
149 var temp = new Array (sfLength - 1);
\r
150 System.arraycopy (this.sequenceFeatures, 0, temp, 0, index);
\r
151 if (index < sfLength) {
\r
152 System.arraycopy (this.sequenceFeatures, index + 1, temp, index, this.sequenceFeatures.length - index - 1);
\r
153 }this.sequenceFeatures = temp;
\r
154 }}, "jalview.datamodel.SequenceFeature");
\r
155 Clazz.defineMethod (c$, "getSequenceFeatures",
\r
157 var features = this.sequenceFeatures;
\r
160 while (features == null && seq.getDatasetSequence () != null && count++ < 10) {
\r
161 seq = seq.getDatasetSequence ();
\r
162 features = (seq).sequenceFeatures;
\r
166 Clazz.overrideMethod (c$, "addPDBId",
\r
168 if (this.pdbIds == null) {
\r
169 this.pdbIds = new java.util.Vector ();
\r
170 }if (this.pdbIds.contains (entry)) {
\r
171 jalview.datamodel.Sequence.updatePDBEntry (this.pdbIds.get (this.pdbIds.indexOf (entry)), entry);
\r
173 this.pdbIds.addElement (entry);
\r
174 }}, "jalview.datamodel.PDBEntry");
\r
175 c$.updatePDBEntry = Clazz.defineMethod (c$, "updatePDBEntry",
\r
176 function (oldEntry, newEntry) {
\r
177 if (newEntry.getFile () != null) {
\r
178 oldEntry.setFile (newEntry.getFile ());
\r
179 }}, "jalview.datamodel.PDBEntry,jalview.datamodel.PDBEntry");
\r
180 Clazz.defineMethod (c$, "setPDBId",
\r
183 }, "java.util.Vector");
\r
184 Clazz.defineMethod (c$, "getPDBId",
\r
186 return this.pdbIds;
\r
188 Clazz.overrideMethod (c$, "getDisplayId",
\r
189 function (jvsuffix) {
\r
190 var result = new StringBuffer (this.name);
\r
192 result.append ("/" + this.start + "-" + this.end);
\r
193 }return result.toString ();
\r
195 Clazz.overrideMethod (c$, "setName",
\r
200 Clazz.defineMethod (c$, "getName",
\r
204 Clazz.overrideMethod (c$, "setStart",
\r
206 this.start = start;
\r
208 Clazz.defineMethod (c$, "getStart",
\r
212 Clazz.overrideMethod (c$, "setEnd",
\r
216 Clazz.defineMethod (c$, "getEnd",
\r
220 Clazz.overrideMethod (c$, "getLength",
\r
222 return this.sequence.length;
\r
224 Clazz.defineMethod (c$, "setSequence",
\r
226 this.sequence = seq.toCharArray ();
\r
227 this.checkValidRange ();
\r
229 Clazz.defineMethod (c$, "getSequenceAsString",
\r
231 return String.instantialize (this.sequence);
\r
233 Clazz.defineMethod (c$, "getSequenceAsString",
\r
234 function (start, end) {
\r
235 return String.instantialize (this.getSequence (start, end));
\r
237 Clazz.defineMethod (c$, "getSequence",
\r
239 return this.sequence;
\r
241 Clazz.defineMethod (c$, "getSequence",
\r
242 function (start, end) {
\r
245 }if (start >= this.sequence.length) {
\r
246 return Clazz.newCharArray (0, '\0');
\r
247 }if (end >= this.sequence.length) {
\r
248 end = this.sequence.length;
\r
249 }var reply = Clazz.newCharArray (end - start, '\0');
\r
250 System.arraycopy (this.sequence, start, reply, 0, end - start);
\r
253 Clazz.overrideMethod (c$, "getSubSequence",
\r
254 function (start, end) {
\r
257 }var seq = this.getSequence (start, end);
\r
258 if (seq.length == 0) {
\r
260 }var nstart = this.findPosition (start);
\r
261 var nend = this.findPosition (end) - 1;
\r
262 var nseq = new jalview.datamodel.Sequence (this.getName (), seq, nstart, nend);
\r
263 nseq.setDescription (this.description);
\r
264 if (this.datasetSequence != null) {
\r
265 nseq.setDatasetSequence (this.datasetSequence);
\r
267 nseq.setDatasetSequence (this);
\r
270 Clazz.overrideMethod (c$, "getCharAt",
\r
272 if (i < this.sequence.length) {
\r
273 return this.sequence[i];
\r
277 Clazz.defineMethod (c$, "setDescription",
\r
279 this.description = desc;
\r
281 Clazz.defineMethod (c$, "getDescription",
\r
283 return this.description;
\r
285 Clazz.overrideMethod (c$, "findIndex",
\r
287 var j = this.start;
\r
289 while ((i < this.sequence.length) && (j <= this.end) && (j <= pos)) {
\r
290 if (!jalview.util.Comparison.isGap (this.sequence[i])) {
\r
294 if ((j == this.end) && (j < pos)) {
\r
295 return this.end + 1;
\r
299 Clazz.overrideMethod (c$, "findPosition",
\r
302 var pos = this.start;
\r
303 var seqlen = this.sequence.length;
\r
304 while ((j < i) && (j < seqlen)) {
\r
305 if (!jalview.util.Comparison.isGap (this.sequence[j])) {
\r
311 Clazz.overrideMethod (c$, "gapMap",
\r
313 var seq = jalview.analysis.AlignSeq.extractGaps (jalview.util.Comparison.GapChars, String.instantialize (this.sequence));
\r
314 var map = Clazz.newIntArray (seq.length, 0);
\r
317 while (j < this.sequence.length) {
\r
318 if (!jalview.util.Comparison.isGap (this.sequence[j])) {
\r
324 Clazz.overrideMethod (c$, "findPositionMap",
\r
326 var map = Clazz.newIntArray (this.sequence.length, 0);
\r
328 var pos = this.start;
\r
329 var seqlen = this.sequence.length;
\r
330 while ((j < seqlen)) {
\r
332 if (!jalview.util.Comparison.isGap (this.sequence[j])) {
\r
338 Clazz.overrideMethod (c$, "getInsertions",
\r
340 var map = new java.util.ArrayList ();
\r
343 var pos = this.start;
\r
344 var seqlen = this.sequence.length;
\r
345 while ((j < seqlen)) {
\r
346 if (jalview.util.Comparison.isGap (this.sequence[j])) {
\r
351 map.add ( Clazz.newIntArray (-1, [lastj, j - 1]));
\r
356 map.add ( Clazz.newIntArray (-1, [lastj, j - 1]));
\r
360 Clazz.overrideMethod (c$, "deleteChars",
\r
362 var newstart = this.start;
\r
363 var newend = this.end;
\r
364 if (i >= this.sequence.length || i < 0) {
\r
366 }var tmp = jalview.util.StringUtils.deleteChars (this.sequence, i, j);
\r
367 var createNewDs = false;
\r
372 for (var s = i; s < j; s++) {
\r
373 if (jalview.schemes.ResidueProperties.aaIndex[this.sequence[s].charCodeAt (0)] != 23) {
\r
378 sindex = this.findIndex (this.start) - 1;
\r
380 }if (sindex == s) {
\r
381 newstart = this.findPosition (j);
\r
385 eindex = this.findIndex (this.end) - 1;
\r
388 newend = this.findPosition (i - 1);
\r
391 createNewDs = true;
\r
394 if (createNewDs && this.datasetSequence != null) {
\r
395 var ds = new jalview.datamodel.Sequence (this.datasetSequence);
\r
396 ds.deleteChars (i, j);
\r
397 this.datasetSequence = ds;
\r
398 }this.start = newstart;
\r
400 this.sequence = tmp;
\r
402 Clazz.defineMethod (c$, "insertCharAt",
\r
403 function (i, length, c) {
\r
404 var tmp = Clazz.newCharArray (this.sequence.length + length, '\0');
\r
405 if (i >= this.sequence.length) {
\r
406 System.arraycopy (this.sequence, 0, tmp, 0, this.sequence.length);
\r
407 i = this.sequence.length;
\r
409 System.arraycopy (this.sequence, 0, tmp, 0, i);
\r
411 while (length > 0) {
\r
415 if (i < this.sequence.length) {
\r
416 System.arraycopy (this.sequence, i, tmp, index, this.sequence.length - i);
\r
417 }this.sequence = tmp;
\r
419 Clazz.defineMethod (c$, "insertCharAt",
\r
421 this.insertCharAt (i, 1, c);
\r
423 Clazz.overrideMethod (c$, "getVamsasId",
\r
425 return this.vamsasId;
\r
427 Clazz.overrideMethod (c$, "setVamsasId",
\r
429 this.vamsasId = id;
\r
431 Clazz.defineMethod (c$, "setDBRef",
\r
433 this.dbrefs = dbref;
\r
435 Clazz.defineMethod (c$, "getDBRef",
\r
437 if (this.dbrefs == null && this.datasetSequence != null && this !== this.datasetSequence) {
\r
438 return this.datasetSequence.getDBRef ();
\r
439 }return this.dbrefs;
\r
441 Clazz.overrideMethod (c$, "addDBRef",
\r
443 if (this.dbrefs == null) {
\r
444 this.dbrefs = new Array (0);
\r
446 var iSize = this.dbrefs.length;
\r
447 for (i = 0; i < iSize; i++) {
\r
448 if (this.dbrefs[i].equalRef (entry)) {
\r
449 if (entry.getMap () != null) {
\r
450 if (this.dbrefs[i].getMap () == null) {
\r
451 this.dbrefs[i] = entry;
\r
454 var temp = new Array (iSize + 1);
\r
455 System.arraycopy (this.dbrefs, 0, temp, 0, iSize);
\r
456 temp[temp.length - 1] = entry;
\r
457 this.dbrefs = temp;
\r
458 }, "jalview.datamodel.DBRefEntry");
\r
459 Clazz.defineMethod (c$, "setDatasetSequence",
\r
461 this.datasetSequence = seq;
\r
462 }, "jalview.datamodel.SequenceI");
\r
463 Clazz.defineMethod (c$, "getDatasetSequence",
\r
465 return this.datasetSequence;
\r
467 Clazz.defineMethod (c$, "getAnnotation",
\r
469 return this.annotation == null ? null : this.annotation.toArray ( new Array (this.annotation.size ()));
\r
471 Clazz.overrideMethod (c$, "hasAnnotation",
\r
473 return this.annotation == null ? false : this.annotation.contains (ann);
\r
474 }, "jalview.datamodel.AlignmentAnnotation");
\r
475 Clazz.defineMethod (c$, "addAlignmentAnnotation",
\r
476 function (annotation) {
\r
477 if (this.annotation == null) {
\r
478 this.annotation = new java.util.Vector ();
\r
479 }if (!this.annotation.contains (annotation)) {
\r
480 this.annotation.addElement (annotation);
\r
481 }annotation.setSequenceRef (this);
\r
482 }, "jalview.datamodel.AlignmentAnnotation");
\r
483 Clazz.overrideMethod (c$, "removeAlignmentAnnotation",
\r
484 function (annotation) {
\r
485 if (this.annotation != null) {
\r
486 this.annotation.removeElement (annotation);
\r
487 if (this.annotation.size () == 0) {
\r
488 this.annotation = null;
\r
489 }}}, "jalview.datamodel.AlignmentAnnotation");
\r
490 Clazz.defineMethod (c$, "isValidDatasetSequence",
\r
492 if (this.datasetSequence != null) {
\r
494 }for (var i = 0; i < this.sequence.length; i++) {
\r
495 if (jalview.util.Comparison.isGap (this.sequence[i])) {
\r
500 Clazz.overrideMethod (c$, "deriveSequence",
\r
502 var seq = new jalview.datamodel.Sequence (this);
\r
503 if (this.datasetSequence != null) {
\r
504 seq.setDatasetSequence (this.datasetSequence);
\r
506 if (this.isValidDatasetSequence ()) {
\r
507 seq.setDatasetSequence (this);
\r
510 ds.setSequence (jalview.analysis.AlignSeq.extractGaps (jalview.util.Comparison.GapChars, String.instantialize (this.sequence)));
\r
511 this.setDatasetSequence (ds);
\r
512 ds.setSequenceFeatures (this.getSequenceFeatures ());
\r
516 Clazz.overrideMethod (c$, "createDatasetSequence",
\r
518 if (this.datasetSequence == null) {
\r
519 this.datasetSequence = new jalview.datamodel.Sequence (this.getName (), jalview.analysis.AlignSeq.extractGaps (jalview.util.Comparison.GapChars, this.getSequenceAsString ()), this.getStart (), this.getEnd ());
\r
520 this.datasetSequence.setSequenceFeatures (this.getSequenceFeatures ());
\r
521 this.datasetSequence.setDescription (this.getDescription ());
\r
522 this.setSequenceFeatures (null);
\r
523 this.datasetSequence.setDBRef (this.getDBRef ());
\r
524 this.setDBRef (null);
\r
525 this.datasetSequence.setPDBId (this.getPDBId ());
\r
526 this.setPDBId (null);
\r
527 this.datasetSequence.updatePDBIds ();
\r
528 if (this.annotation != null) {
\r
529 for (var aa, $aa = this.annotation.iterator (); $aa.hasNext () && ((aa = $aa.next ()) || true);) {
\r
530 var _aa = new jalview.datamodel.AlignmentAnnotation (aa);
\r
531 _aa.sequenceRef = this.datasetSequence;
\r
532 _aa.adjustForAlignment ();
\r
533 this.datasetSequence.addAlignmentAnnotation (_aa);
\r
535 }}return this.datasetSequence;
\r
537 Clazz.overrideMethod (c$, "setAlignmentAnnotation",
\r
538 function (annotations) {
\r
539 if (this.annotation != null) {
\r
540 this.annotation.removeAllElements ();
\r
541 }if (annotations != null) {
\r
542 for (var i = 0; i < annotations.length; i++) {
\r
543 if (annotations[i] != null) {
\r
544 this.addAlignmentAnnotation (annotations[i]);
\r
547 Clazz.defineMethod (c$, "getAnnotation",
\r
549 if (this.annotation == null || this.annotation.size () == 0) {
\r
551 }var subset = new java.util.Vector ();
\r
552 var e = this.annotation.elements ();
\r
553 while (e.hasMoreElements ()) {
\r
554 var ann = e.nextElement ();
\r
555 if (ann.label != null && ann.label.equals (label)) {
\r
556 subset.addElement (ann);
\r
558 if (subset.size () == 0) {
\r
560 }var anns = new Array (subset.size ());
\r
562 e = subset.elements ();
\r
563 while (e.hasMoreElements ()) {
\r
564 anns[i++] = e.nextElement ();
\r
566 subset.removeAllElements ();
\r
569 Clazz.defineMethod (c$, "updatePDBIds",
\r
571 if (this.datasetSequence != null) {
\r
572 return this.datasetSequence.updatePDBIds ();
\r
573 }if (this.dbrefs == null || this.dbrefs.length == 0) {
\r
575 }var newpdb = new java.util.Vector ();
\r
576 for (var i = 0; i < this.dbrefs.length; i++) {
\r
577 if (jalview.datamodel.DBRefSource.PDB.equals (this.dbrefs[i].getSource ())) {
\r
578 var pdbe = new jalview.datamodel.PDBEntry ();
\r
579 pdbe.setId (this.dbrefs[i].getAccessionId ());
\r
580 if (this.pdbIds == null || this.pdbIds.size () == 0) {
\r
581 newpdb.addElement (pdbe);
\r
583 var en = this.pdbIds.elements ();
\r
584 var matched = false;
\r
585 while (!matched && en.hasMoreElements ()) {
\r
586 var anentry = en.nextElement ();
\r
587 if (anentry.getId ().equals (pdbe.getId ())) {
\r
591 newpdb.addElement (pdbe);
\r
593 if (newpdb.size () > 0) {
\r
594 var en = newpdb.elements ();
\r
595 while (en.hasMoreElements ()) {
\r
596 this.addPDBId (en.nextElement ());
\r
601 Clazz.defineMethod (c$, "transferAnnotation",
\r
602 function (entry, mp) {
\r
603 if (this.datasetSequence != null) {
\r
604 this.datasetSequence.transferAnnotation (entry, mp);
\r
606 }if (entry.getDatasetSequence () != null) {
\r
607 this.transferAnnotation (entry.getDatasetSequence (), mp);
\r
609 }if (entry.getSequenceFeatures () != null) {
\r
610 var sfs = entry.getSequenceFeatures ();
\r
611 for (var si = 0; si < sfs.length; si++) {
\r
612 var sf = (mp != null) ? mp.locateFeature (sfs[si]) : Clazz.newArray (-1, [ new jalview.datamodel.SequenceFeature (sfs[si])]);
\r
613 if (sf != null && sf.length > 0) {
\r
614 for (var sfi = 0; sfi < sf.length; sfi++) {
\r
615 this.addSequenceFeature (sf[sfi]);
\r
618 }if (entry.getPDBId () != null) {
\r
619 var e = entry.getPDBId ().elements ();
\r
620 while (e.hasMoreElements ()) {
\r
621 var pdb = e.nextElement ();
\r
622 this.addPDBId (pdb);
\r
624 }var entryRefs = entry.getDBRef ();
\r
625 if (entryRefs != null) {
\r
626 for (var r = 0; r < entryRefs.length; r++) {
\r
627 var newref = new jalview.datamodel.DBRefEntry (entryRefs[r]);
\r
628 if (newref.getMap () != null && mp != null) {
\r
629 }this.addDBRef (newref);
\r
631 }}, "jalview.datamodel.SequenceI,jalview.datamodel.Mapping");
\r
632 Clazz.overrideMethod (c$, "getIndex",
\r
636 Clazz.overrideMethod (c$, "setIndex",
\r
638 this.index = value;
\r
640 Clazz.overrideMethod (c$, "setRNA",
\r
643 }, "jalview.jsdev.api.VarnaRNA");
\r
644 Clazz.overrideMethod (c$, "getRNA",
\r
648 Clazz.overrideMethod (c$, "getAlignmentAnnotations",
\r
649 function (calcId, label) {
\r
650 var result = new java.util.ArrayList ();
\r
651 if (this.annotation != null) {
\r
652 for (var ann, $ann = this.annotation.iterator (); $ann.hasNext () && ((ann = $ann.next ()) || true);) {
\r
653 if (ann.calcId != null && ann.calcId.equals (calcId) && ann.label != null && ann.label.equals (label)) {
\r