Showing source for Memory Tables
ProWiki
|
RecentChanges
|
Preferences
Internally, ProWiki is basically UseModWiki, with some added data structures. (So the interested reader is strongly advised to read into UseModWiki first.) In particular, it has one major new structure: the %Props hash. The keys to %Props are property names: each property in memory has an entry in %Props. The values are the <i>property tables</i> for each of those properties. The property table is itself a hash. The key to each property table is the name of a page (in normalized form); the value is an array of the values that that page has for that property. Yes, %Props is a hash of hashes of arrays -- kind of horrifying, but that's Perl for you. Properties are read into memory on an as-requested basis. The %OpenProperties hash is simply an index of which properties have been read into memory from file. Note that %Props is sometimes incomplete for a given property: when rendering a page, that page's properties are populated into %Props without reading in all the values for other pages. That's why %OpenProperties is needed.