From: jprocter Date: Wed, 2 May 2007 14:27:25 +0000 (+0000) Subject: documentation and proxy call to util.MapList.getToWord(mpos) X-Git-Tag: Release_2_3~74 X-Git-Url: http://source.jalview.org/gitweb/?a=commitdiff_plain;h=4dd44779e0d1ffa07b52b67bd8178ad45801bb4f;p=jalview.git documentation and proxy call to util.MapList.getToWord(mpos) --- diff --git a/src/jalview/datamodel/Mapping.java b/src/jalview/datamodel/Mapping.java index b9874a4..0063faa 100644 --- a/src/jalview/datamodel/Mapping.java +++ b/src/jalview/datamodel/Mapping.java @@ -99,12 +99,14 @@ public class Mapping { } return mpos; } + /** + * gets boundary in direction of mapping + * @param position in mapped reference frame + * @return int{start, end} positions in associated sequence (in direction of mapped word) + */ public int[] getWord(int mpos) { if (map!=null) { - int[] mp=map.shiftTo(mpos); - if (mp!=null) { - return new int[] {mp[0], mp[0]+mp[2]*(map.getFromRatio()-1)}; - } + return map.getToWord(mpos); } return null; }