Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot

Plug-in mechanism implemented in Perl

by romanlazarev (Initiate)
on Jul 06, 2001 at 18:02 UTC ( #94470=perlquestion: print w/replies, xml ) Need Help??
romanlazarev has asked for the wisdom of the Perl Monks concerning the following question:

Dear All,

I'm in the process of writing a code for a web-site. The idea is that it has to be modular in its features. By saying that I mean, that there is a storage of data and I wish to run a report against this data, all I have to do is copy a script and hook it up to the main code like a plug-in (think of it like adding a plug-in in a Photoshop). The question that I'm trying to answer is - how to implement this "plug-in mechanism" in perl? What about performance (when some snippet of code has to be ran via "shell" of "exec" every time a variable is passed)?

Thank you in advance!

Replies are listed 'Best First'.
Re: Plug-in mechanism implemented in Perl
by tomhukins (Curate) on Jul 06, 2001 at 18:10 UTC
      Thank you, Tom. You were very helpful!
Re: Plug-in mechanism implemented in Perl
by suaveant (Parson) on Jul 06, 2001 at 18:35 UTC
    Really, this is a major part of Object Oriented programming, I don't have any links off-hand, but OO is great for this. You come up with an interface and write different modules with different back end code, but with the exact same methods, and then you can seamlessly interchange them... Damian Conway has an OO Perl book that is supposed to be good look at perltoot to start

                    - Ant

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://94470]
Approved by root
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others taking refuge in the Monastery: (3)
As of 2018-05-24 01:38 GMT
Find Nodes?
    Voting Booth?