good chemistry is complicated, and a little bit messy -LW |
|
PerlMonks |
Re^4: OO, Library Configuration and Class Variablesby moot (Chaplain) |
on Jun 23, 2005 at 22:37 UTC ( [id://469552]=note: print w/replies, xml ) | Need Help?? |
Hmm.. I grok this apart from this bit:
In case I wasn't clear, my original query was how to do this config - it seems you're saying that Loopup::Remote (or LookupFactory, here) can run its own AppConfig->file(), but this raises the issue of passing in the filename from which Lookup::Remote can configure (as you can probably tell I'm against hard-coding values!). Also, unless I have a separate configuration file for 'library values' from the one for 'application values', I'd need to define both sets of variables that AppConfig will use, in all instances of AppConfig, or deal with the warnings it spits out about undefined variables. And something about separating out those config files strikes me as wrong. I guess I could just modify User to accept an AppConfig instance and pretend that there is a broader use for this than just a single remote_uri parameter, or deal with app-code knowing something about User's internals. Thanks for the assistance. --
In Section
Seekers of Perl Wisdom
|
|