Beefy Boxes and Bandwidth Generously Provided by pair Networks
Just another Perl shrine
 
PerlMonks  

Re^4: Sharing Namespaces

by ysth (Canon)
on Jan 27, 2006 at 11:00 UTC ( [id://525949]=note: print w/replies, xml ) Need Help??


in reply to Re^3: Sharing Namespaces
in thread Sharing Namespaces

if your Config module loads a configuration file it will still reload that file every time the module is called
I don't think that's the clearest way to put that. When a module is "use"d, it's import() routine (if any) is normally called, but modules themselves aren't "called". In this case, whether the configuration file is loaded more than once depends on where exactly the loading takes place. If it is done in a subroutine called by each using module (including import()), then the config file will be loaded each time. If, on the other hand, the loading is done by the main code of the Config module, it won't, since that code is only run the first time the module is used. My guess is that the latter is the case.

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others chanting in the Monastery: (3)
As of 2024-04-25 23:34 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found