[BioPerl-l] Bio::Seq->delete_SeqFeature missing?

Hilmar Lapp lapp@gnf.org
Thu, 10 May 2001 10:46:11 -0700


Malcolm Cook wrote:
> 
> Hilmar & Ewan,
> 
> I'm converted.  Thanks for the discussion.
> 
> If I wanted a new Bio::Seq identical in all respects to one at hand, say
> held in $oldseq, would I write:
> 
>         my $newseq = $oldseq->new;

Well, you actually want

          my $newsew = $oldseq->clone();

Support for cloning has been dropped at the time of migrating from a
heavy-weight root object to a light-weight one, figuring that there is
little if any need for cloning.

So, yes, cloning you have to code yourself. Is there a specific reason
you need that?

> 
> And, does flush_SeqFeature simply become the following?
> 
> =head2 flush_SeqFeature
> 
> Title   : flush_SeqFeature - THIS METHOD SEEMS MISSING FROM BIO::SEQ!
>  Usage   : $seq->flush_SeqFeature();
>            $seq->flush_SeqFeature();
> 
>  Function: Removes all features from the sequence
> 
>  Example :
>  Returns : TRUE on success
>  Args    : none
> 
> =cut
> 
> sub Bio::Seq::flush_SeqFeature {
>   my ($self) = @_;
>   $self->{'_as_feat'} = [];
>   return 1;
> }

Right.

	Hilmar

-- 
-------------------------------------------------------------
Hilmar Lapp                            email: lapp@gnf.org
GNF, San Diego, Ca. 92121              phone: +1-858-812-1757
-------------------------------------------------------------