Pathologically Eclectic Rubbish Lister | |
PerlMonks |
Using objects where you don't know the module's name until run time.by Anonymous Monk |
on Nov 07, 2000 at 03:17 UTC ( [id://40278]=perlquestion: print w/replies, xml ) | Need Help?? |
Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question: ⭐ (object-oriented programming)
I'm trying to build a wrapper class to hold one of an arbitrary number of "plug-in" modules. My motive here is to load the module, and then pass calls from the outside world to that module, failing gracefully if it can't perform the function. I get the name of the module out of a database query. I can do require $string no problem, but the issue then becomes how do I say $string->new?
Originally posted as a Categorized Question.
Back to
Seekers of Perl Wisdom
|
|