[Bioperl-l] _rearrange

Chris Fields cjfields at uiuc.edu
Wed Feb 28 18:30:45 UTC 2007


 From what I gather it's a convenient utility method that is used for  
consistent and enforced parameter checking/setting for any method,  
including the constructor.

There are a few modules that don't use _rearrange (Bio::WebAgent::new 
() comes to mind).  It's not required that you use it but the naming  
conventions for parameters outlined in _rearrange (in  
Bio::Root::RootI POD) are generally enforced for consistency across  
classes.

As a note, Sendu has committed a related method (_set_from_args) to  
CVS which works rather well, but I don't think it is in the last  
release.

chris

On Feb 28, 2007, at 11:05 AM, Caroline Johnston wrote:

> hi,
>
> Is there a discussion of the rationale behind the _rearrange method
> somewhere? I'm probably just being gormless, but I think I'm  
> missing the
> point a bit.
>
> Is it okay for a method just to expect named params like
> ->foo(arg1=>'stuff', arg2=>'things'); ?
>
> Cxx
>
> _______________________________________________
> Bioperl-l mailing list
> Bioperl-l at lists.open-bio.org
> http://lists.open-bio.org/mailman/listinfo/bioperl-l





More information about the Bioperl-l mailing list