|
|
| "be consistent" | |
| PerlMonks |
Using objects where you don't know the module's name until run time.by Anonymous Monk |
| on Nov 06, 2000 at 22:17 UTC ( [id://40278]=perlquestion: print w/replies, xml ) | Need Help?? |
This is an archived low-energy page for bots and other anonmyous visitors. Please sign up if you are a human and want to interact.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
|
|
||||||||||||||||||||||||||||||