Commit cf9ddc4f authored by Graham McVicker's avatar Graham McVicker
Browse files

make feature caching case insensitive (i.e. slice on chr 'X' or 'x' is same slice)

parent 5b352f75
......@@ -16,7 +16,7 @@ Bio::EnsEMBL::DBSQL::BaseFeatureAdaptor - Abstract Base class for
=head1 SYNOPSIS
Abstract class should not be instantiated. Implementation of
Abstract class - should not be instantiated. Implementation of
abstract methods must be performed by subclasses.
=head1 DESCRIPTION
......@@ -25,20 +25,16 @@ This is a base adaptor for feature adaptors. This base class is simply a way
of eliminating code duplication through the implementation of methods
common to all feature adaptors.
=head1 CONTACT
Contact EnsEMBL development list for info: <ensembl-dev@ebi.ac.uk>
=cut
# Let the code begin...
package Bio::EnsEMBL::DBSQL::BaseFeatureAdaptor;
use vars qw(@ISA $SLICE_FEATURE_CACHE_SIZE);
use strict;
# Object preamble - inherits from Bio::EnsEMBL::Root
use Bio::EnsEMBL::DBSQL::BaseAdaptor;
use Bio::EnsEMBL::Utils::Cache;
......@@ -397,7 +393,7 @@ sub fetch_all_by_Slice_constraint {
$constraint = '' unless $constraint;
#check the cache and return if we have already done this query
my $key = join($slice->name, $constraint, $logic_name);
my $key = uc(join($slice->name, $constraint, $logic_name));
return $self->{'_slice_feature_cache'}{$key}
if $self->{'_slice_feature_cache'}{$key};
......
......@@ -34,24 +34,15 @@ its BaseAlignFeatureAdaptor superclass.
Email birney@ebi.ac.uk
Describe contact details here
=head1 APPENDIX
The rest of the documentation details each of the object methods. Internal methods are usually preceded with a _
Post questions to the EnsEMBL development list <ensembl-dev@ebi.ac.uk>
=cut
# Let the code begin...
package Bio::EnsEMBL::DBSQL::DnaAlignFeatureAdaptor;
use vars qw(@ISA);
use strict;
# Object preamble - inherits from Bio::EnsEMBL::Root
use Bio::EnsEMBL::DnaDnaAlignFeature;
use Bio::EnsEMBL::DBSQL::BaseAlignFeatureAdaptor;
......
......@@ -413,7 +413,7 @@ sub fetch_all_by_Slice {
$logic_name ||= '';
my $key = $slice->name .":" . $logic_name;
my $key = uc($slice->name .":" . $logic_name);
#check the cache which uses the slice name as it key
if($self->{'_slice_gene_cache'}{$key}) {
......
......@@ -20,11 +20,7 @@ if it is available).
=head1 CONTACT
Graham McVicker : mcvicker@ebi.ac.uk
Arne Stabenau: stabenau@ebi.ac.uk
Ewan Birney : birney@ebi.ac.uk
=head1 APPENDIX
Post questions to the EnsEMBL developer list <ensembl-dev@ebi.ac.uk>
=cut
......
......@@ -25,25 +25,15 @@ Allows for the retrieval and storage of RawContig objects from the database.
=head1 CONTACT
=head1 APPENDIX
The rest of the documentation details each of the object methods. Internal methods are
usually preceded with a _
Post questions to the EnsEMBL developer list <ensembl-dev@ebi.ac.uk>
=cut
# Let the code begin...
package Bio::EnsEMBL::DBSQL::RawContigAdaptor;
use vars qw(@ISA);
use strict;
# Object preamble - inheriets from Bio::Root::Object
use Bio::EnsEMBL::DBSQL::BaseAdaptor;
use DBI;
......@@ -56,9 +46,6 @@ my $RAW_CONTIG_CACHE_SIZE = 20;
@ISA = qw(Bio::EnsEMBL::DBSQL::BaseAdaptor);
#Override the inherited constructor
=head2 new
Arg [1] : list of arguments @args
......@@ -86,8 +73,6 @@ sub new {
=head2 fetch_by_dbID
Arg [1] : int $dbID
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment