[Bioperl-guts-l] bioperl-live/Bio/DB/GFF/Adaptor/dbi mysql.pm, 1.63, 1.64
Scott Cain
scain at pub.open-bio.org
Mon Feb 20 12:43:59 EST 2006
Update of /home/repository/bioperl/bioperl-live/Bio/DB/GFF/Adaptor/dbi
In directory pub.open-bio.org:/tmp/cvs-serv22818
Modified Files:
mysql.pm
Log Message:
moving result filtering from gbrowse to mysql adaptor (where it belongs, so that anybody who uses this method will actually get the results they are expecting).
Index: mysql.pm
===================================================================
RCS file: /home/repository/bioperl/bioperl-live/Bio/DB/GFF/Adaptor/dbi/mysql.pm,v
retrieving revision 1.63
retrieving revision 1.64
diff -C2 -d -r1.63 -r1.64
*** mysql.pm 9 Dec 2005 12:17:58 -0000 1.63
--- mysql.pm 20 Feb 2006 17:43:57 -0000 1.64
***************
*** 413,417 ****
push @results,[$featname,$note,$relevance];
}
! @results;
}
--- 413,430 ----
push @results,[$featname,$note,$relevance];
}
!
! #added result filtering so that this method returns the expected results
! #this section of code used to be in GBrowse's do_keyword_search method
!
! my $match_sub = 'sub {';
! foreach (split /\s+/,$search_string) {
! $match_sub .= "return unless \$_[0] =~ /\Q$_\E/i; ";
! }
! $match_sub .= "};";
! my $match = eval $match_sub;
!
! my @matches = grep { $match->($_->[1]) } @results;
!
! return @matches;
}
More information about the Bioperl-guts-l
mailing list