Oops, this looks like a bug. Thanks for spotting it!! I'll try to fix it in the next day or so.
- Mark > -----Original Message----- > From: Yasumasa Shigemoto [mailto:[EMAIL PROTECTED]] > Sent: Friday, 24 January 2003 6:13 p.m. > To: [EMAIL PROTECTED] > Subject: [Biojava-l] Circular Location > > > Hi > > I use the CircularLocation and LocationTools as follows, > but it seems to return the wrong response. > > import org.biojava.bio.symbol.*; > > public class CircularTest { > public static void main(String[] args) { > try { > Location[] locs = new Location[10]; > locs[0] = > LocationTools.makeCircularLocation(18,24,20); > locs[1] = > LocationTools.makeCircularLocation(18,24,20); > locs[2] = > LocationTools.makeCircularLocation(2,8,20); > locs[3] = > LocationTools.makeCircularLocation(4,10,20); > locs[4] = > LocationTools.makeCircularLocation(18,23,20); > > System.out.println(LocationTools.areEqual(locs[0], locs[1])); > > System.out.println(LocationTools.contains(locs[0], locs[1])); > > System.out.println(LocationTools.overlaps(locs[0], locs[2])); > > System.out.println(LocationTools.overlaps(locs[2], locs[3])); > > System.out.println(LocationTools.overlaps(locs[0], locs[4])); > } catch (Exception ex) { > ex.printStackTrace(); > } > } > } > > > java CircularTest > true > true > false > true > false > > I think the whole of result is 'true'. > > Environment > biojava-1.3pre1.jar, j2sdk1.4.0 > > Any help would be most appreciated. > > Yasumasa Shigemoto > > _______________________________________________ > Biojava-l mailing list - [EMAIL PROTECTED] > http://biojava.org/mailman/listinfo/biojava-l > ======================================================================= Attention: The information contained in this message and/or attachments from AgResearch Limited is intended only for the persons or entities to which it is addressed and may contain confidential and/or privileged material. Any review, retransmission, dissemination or other use of, or taking of any action in reliance upon, this information by persons or entities other than the intended recipients is prohibited by AgResearch Limited. If you have received this message in error, please notify the sender immediately. ======================================================================= _______________________________________________ Biojava-l mailing list - [EMAIL PROTECTED] http://biojava.org/mailman/listinfo/biojava-l
