Skip to content
Snippets Groups Projects
Commit 33523202 authored by James Gilbert's avatar James Gilbert
Browse files

fixed CORE::length warnings in Transcript

added TYPE parameter to DBAdaptor constructor
parent 2f0a52de
No related branches found
No related tags found
No related merge requests found
...@@ -57,6 +57,7 @@ use Bio::EnsEMBL::DBSQL::BaseFeatureAdaptor; ...@@ -57,6 +57,7 @@ use Bio::EnsEMBL::DBSQL::BaseFeatureAdaptor;
Arg [-DNADB]: (optional) Bio::EnsEMBL::DBSQL::DBAdaptor DNADB Arg [-DNADB]: (optional) Bio::EnsEMBL::DBSQL::DBAdaptor DNADB
All sequence, assembly, contig information etc, will be All sequence, assembly, contig information etc, will be
retrieved from this database instead. retrieved from this database instead.
Arg [-TYPE]: (optional) An assembly_type
Arg [..] : Other args are passed to superclass Arg [..] : Other args are passed to superclass
Bio::EnsEMBL::DBSQL::DBConnection Bio::EnsEMBL::DBSQL::DBConnection
Example : $db = new Bio::EnsEMBL::DBSQL::DBAdaptor( Example : $db = new Bio::EnsEMBL::DBSQL::DBAdaptor(
...@@ -77,11 +78,14 @@ sub new { ...@@ -77,11 +78,14 @@ sub new {
#call superclass constructor #call superclass constructor
my $self = $class->SUPER::new(@args); my $self = $class->SUPER::new(@args);
my ( $dnadb ) = $self->_rearrange([qw(DNADB)],@args); my ( $dnadb, $assembly_type ) = $self->_rearrange([qw(DNADB TYPE)],@args);
if(defined $dnadb) { if(defined $dnadb) {
$self->dnadb($dnadb); $self->dnadb($dnadb);
} }
if ($assembly_type) {
$self->assembly_type($assembly_type);
}
# $self here is actually a Container object # $self here is actually a Container object
# so need to call _obj to get the DBAdaptor # so need to call _obj to get the DBAdaptor
......
...@@ -1156,7 +1156,7 @@ sub five_prime_utr { ...@@ -1156,7 +1156,7 @@ sub five_prime_utr {
my $self = shift; my $self = shift;
my $seq = substr($self->spliced_seq, 0, $self->cdna_coding_start - 1); my $seq = substr($self->spliced_seq, 0, $self->cdna_coding_start - 1);
length $seq or return; CORE::length($seq) or return;
return Bio::Seq->new( return Bio::Seq->new(
-DISPLAY_ID => $self->stable_id, -DISPLAY_ID => $self->stable_id,
...@@ -1169,7 +1169,7 @@ sub three_prime_utr { ...@@ -1169,7 +1169,7 @@ sub three_prime_utr {
my $self = shift; my $self = shift;
my $seq = substr($self->spliced_seq, $self->cdna_coding_end); my $seq = substr($self->spliced_seq, $self->cdna_coding_end);
length $seq or return; CORE::length($seq) or return;
return Bio::Seq->new( return Bio::Seq->new(
-DISPLAY_ID => $self->stable_id, -DISPLAY_ID => $self->stable_id,
......
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