I've written a perl module (say foo
), with one primary subroutine (say f()
), which I want to use in two ways:
- Import module
foo
, then call the subf(...)
from the script importing modulefoo
. - Just import module
foo
and get modulefoo
to call the subf(@ARGV)
or some appropriate variation.
Can I make one module which has these two options,
or
Should I make a wrapper module, say foo_default.pm
, which will use foo
and then calls foo::f(@ARGV)
?