Commit b5692608 authored by Ewan Birney's avatar Ewan Birney
Browse files

as per Arnes request, Slices become more "standard" (so we can use them in the...

as per Arnes request, Slices become more "standard" (so we can use them in the pipeline). Moved Slice to business object space and SliceFactory to SliceAdaptor
parent 1002456b
......@@ -12,13 +12,11 @@
=head1 NAME
Bio::EnsEMBL::Assembly::SliceFactory - Factory for building slices
Bio::EnsEMBL::DBSQL::SliceAdaptor - Adaptors for slices
=head1 SYNOPSIS
$slice = Bio::EnsEMBL::Assembly::SliceFactory->new_slice($chr,$start,$end,$type);
$webslice = Bio::EnsEMBL::Assembly::SliceFactory->new_web_slice($chr,$start,$end,$type);
=head1 DESCRIPTION
......@@ -45,7 +43,7 @@ methods. Internal methods are usually preceded with a _
# Let the code begin...
package Bio::EnsEMBL::Assembly::SliceFactory;
package Bio::EnsEMBL::DBSQL::SliceAdaptor;
use vars qw(@ISA);
use strict;
......
......@@ -12,11 +12,10 @@
=head1 NAME
Bio::EnsEMBL::Assembly::Slice - Arbitary Slice of a genome
Bio::EnsEMBL::Slice - Arbitary Slice of a genome
=head1 SYNOPSIS
$slice = Bio::EnsEMBL::Assembly::SliceFactory->new_slice($chr,$start,$end,$type);
foreach $gene ( $slice->get_all_Genes ) {
# do something with a gene
......@@ -45,7 +44,7 @@ The rest of the documentation details each of the object methods. Internal metho
# Let the code begin...
package Bio::EnsEMBL::Assembly::Slice;
package Bio::EnsEMBL::Slice;
use vars qw(@ISA);
use strict;
......@@ -130,7 +129,14 @@ sub get_all_SimilarityFeatures_above_pid{
sub get_all_RepeatFeatures{
my ($self,@args) = @_;
$self->throw("Ewan has not implemented this function! Complain!!!!");
@repeats = $self->repeat_adaptor->fetch_by_Slice($self);
foreach $repeat ( @repeats ) {
$repeat->transform_location($self->start);
}
return @repeats;
}
......
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