[Bio] / FigKernelPackages / Overlap.pm Repository:
ViewVC logotype

Diff of /FigKernelPackages/Overlap.pm

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.1, Tue Jul 26 20:10:59 2005 UTC revision 1.3, Mon Dec 5 19:06:30 2005 UTC
# Line 1  Line 1 
1  #!/usr/bin/perl -w  #!/usr/bin/perl -w
2    #
3    # Copyright (c) 2003-2006 University of Chicago and Fellowship
4    # for Interpretations of Genomes. All Rights Reserved.
5    #
6    # This file is part of the SEED Toolkit.
7    #
8    # The SEED Toolkit is free software. You can redistribute
9    # it and/or modify it under the terms of the SEED Toolkit
10    # Public License.
11    #
12    # You should have received a copy of the SEED Toolkit Public License
13    # along with this program; if not write to the University of Chicago
14    # at info@ci.uchicago.edu or the Fellowship for Interpretation of
15    # Genomes at veronika@thefig.info or download a copy from
16    # http://www.theseed.org/LICENSE.TXT.
17    #
18    
19    
20  package Overlap;  package Overlap;
21    
# Line 140  Line 157 
157  =item loc0, loc1  =item loc0, loc1
158    
159  Location objects representing the locations for which overlap information is desired.  Location objects representing the locations for which overlap information is desired.
160    These may be B<BasicLocation>s or B<FullLocation>s.
161    
162  =item RETURN  =item RETURN
163    
# Line 157  Line 175 
175      my ($loc0, $loc1) = @_;      my ($loc0, $loc1) = @_;
176      # Declare the return variables.      # Declare the return variables.
177      my ($type, $len) = (undef, 0);      my ($type, $len) = (undef, 0);
178        # If these are full locations, get the bounds.
179        if ($loc0->isa('FullLocation')) {
180            ($loc0, undef, undef) = $loc0->GetBounds();
181        }
182        if ($loc1->isa('FullLocation')) {
183            ($loc1, undef, undef) = $loc1->GetBounds();
184        }
185      # Both locations must belong to the same contig.      # Both locations must belong to the same contig.
186      if ($loc0->Contig eq $loc1->Contig) {      if ($loc0->Contig eq $loc1->Contig) {
187          # Sort the locations.          # Sort the locations.

Legend:
Removed from v.1.1  
changed lines
  Added in v.1.3

MCS Webmaster
ViewVC Help
Powered by ViewVC 1.0.3