File tree Expand file tree Collapse file tree
biojava-core/src/main/java/org/biojava/nbio/core/sequence/io Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -283,6 +283,8 @@ private String _insdc_location_string_ignoring_strand_and_subfeatures(
283283 ref = ""
284284 assert not location.ref_db
285285 */
286+
287+
286288 String ref = "" ;
287289 if (!sequenceLocation .getStart ().isUncertain () && !sequenceLocation .getEnd ().isUncertain () && sequenceLocation .getStart () == sequenceLocation .getEnd ()) {
288290 //Special case, for 12:12 return 12^13
@@ -338,7 +340,20 @@ private String _insdc_location_string_ignoring_strand_and_subfeatures(
338340 }
339341 } else {
340342 //Typical case, e.g. 12..15 gets mapped to 11:15
341- return ref + _insdc_feature_position_string (sequenceLocation .getStart (), 0 ) + ".." + _insdc_feature_position_string (sequenceLocation .getEnd ());
343+ String start = _insdc_feature_position_string (sequenceLocation .getStart ());
344+ String end = _insdc_feature_position_string (sequenceLocation .getEnd ());
345+
346+ if (sequenceLocation .isPartial ()) {
347+ if (sequenceLocation .isPartialOn5prime ()) {
348+ start = "<" + start ;
349+ }
350+
351+ if (sequenceLocation .isPartialOn3prime ()) {
352+ end = ">" + end ;
353+ }
354+ }
355+
356+ return ref + start + ".." + end ;
342357 }
343358 }
344359 private String _insdc_feature_position_string (Point location ) {
You can’t perform that action at this time.
0 commit comments