Beefy Boxes and Bandwidth Generously Provided by pair Networks
Do you know where your variables are?

Re: Draft - Writng pluggable programs with perl.

by revdiablo (Prior)
on Jun 13, 2004 at 20:15 UTC ( #366343=note: print w/replies, xml ) Need Help??

in reply to Draft - Writng plugable programs with perl.

This is very similar to a plugin system that I built for (wait for it...) an IRC bot. I needed to be able to unload plugins, though. So instead of using require, I just used do. This got rid of the %INC check, which is nice, but for my purposes just a hassle. I then used delete_package from Symbol (this is a core module) to remove the plugin. Also, instead of running the subroutines immediately, I store the coderef returned by can() in a dispatch table.

Obviously my plugins work a little differently due to their different purpose, but perhaps some others will find this information useful.

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://366343]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others drinking their drinks and smoking their pipes about the Monastery: (3)
As of 2020-08-09 14:41 GMT
Find Nodes?
    Voting Booth?
    Which rocket would you take to Mars?

    Results (54 votes). Check out past polls.