I am in the process of migrating some configuration data out of a module and into a configuration file.
I have been using AppConfig, but it’s goal seems to be something a bit different from what I want.
I have a deep data structure and I just want to be able to deserialize this from a file. Some of the attributes needs to be converted into references to arrays etc.
So I made a swift search on http://search.cpan.org located Config::General.
I am skimming through the code and I fall over a section with a complex example:
- user = hans
- server = mc200
- db = maxis
- passwd = D3rf$
- <jonas>
- user = tom
- db = unknown
- host = mila
- <tablestructure>;
- index int(100000)
- name char(100)
- prename char(100)
- city char(100)
- status int(10)
- allowed moses
- allowed ingram
- allowed joice
- </tablestructure>
- </jonas>
If you look at the example, it contains the string jonas. This word can be uttered in a large group of people with additional background noise, it can be written in a huge text document – and my senses will always pick it up easily – for the hearing part this is referred to as the cocktail party effect. I have no knowledge of an equivalent for reading, but to get back to the example and Config::General.
The match between my name and the example string, is of course purely coincidental, but how can I NOT try out this module now? – better give it a shot.
(Cross-posted on livejournal.com)



0 Comments.