[Bioperl-l] Cloning seqfeatures vs reblessing

Hilmar Lapp hlapp@gmx.net
Sat, 25 Aug 2001 16:30:08 +0200


David Block wrote:
> 
> On Fri, 24 Aug 2001, Chris Mungall wrote:
> 
> > I'm in favour of reblessing
> >
> That's what I ended up with doing :)
> 
It's OO-wise not the best practise, but since re-blessing does not
prune and graft on another inheritance tree (i.e. a SeqFeatureI
remains a SeqFeatureI), the impact may be acceptable.

OTOH if someone supplies instances of his own SeqFeatureI
implementing classes, he/she probably wouldn't like to have this
re-blessed (i.e. losing his implementation). Hmm.

Maybe it's better to require explicit types right away -- an exon
to be added must implement SeqFeature::Gene::ExonI and so forth,
otherwise you skip it. The more I think about it the more I tend
to restrict the input type instead of reblessing.

	-hilmar
-- 
-----------------------------------------------------------------
Hilmar Lapp                              email: hilmarl@yahoo.com
A-1120 Vienna
-----------------------------------------------------------------