[Bioperl-l] New package: Bio::Constants/Bio::Root::Constants?
Stefan Kirov
skirov at utk.edu
Mon May 10 14:59:20 EDT 2004
Hi guys!
I thought it might be useful if we had a module with common constants
that are used across all other packages. Something a bit like
Bio::Root::Version, but expanded.
For example:
$Bio::Root::Constants::Gap_character='-';
This means that any parser should convert the format specific gap
character to $Bio::Root::Constants::Gap_character, therefore any other
module/script will know to expect only Bio::Root::Constants::Gap_character.
This can go further with versions and subformats. For example:
@Bio::Root::Constants::ParsableMemeVer=qw(3.0.3 3.0.4);
@Bio::Root::Constants::ParsableMemeSF=qw(text);
So we'll know that only MEME reports in text format, generated by MEME
3.0.3/3.0.4 can be pasred. This could help especially with packages that
are not maintained any more I guess... One can even do something like:
throw unless ($constant->can_parse('meme','3.0.5'));
At some moment we could even pass params to parsers, so they could
possibly adapt ot a new format version...
This is just an idea. There are a lot of people who will know to what
extent this is going to be useful and I would love to hear from them.
Stefan
More information about the Bioperl-l
mailing list