On Wednesday 22 May 2002 03:24 am, Konstantin Piroumian wrote:
> Btw, I don't think that replacing XMLResourceBundle with a HashMap will
> improve perfomance much in the long run, because the values are stored in a
> HashMap on the first use, so there should be no much difference.

Agreeed. One of our main problems was the first use though. In development it 
would take a minute or two to fully translate our menu file (large 
chunk-o-javascript) with the XMLResourceBundle based approach. While some of 
the abstractions of the XMLResourceBundle are nice, it isn't really 
neccessary to parse an XPath each time a value is retrieved.

I parse the i18n dictionaries at startup and store the key/values in an 
unsynchronized hashmap and the transformer flies now.

Perhaps we can abstract out an interface for the I18nTransformer to talk to a 
catalogue/dictionary source so the XMLResourceBundle usage is optional? I'd 
love for my changes to the I18nTransformer to be able to make it back to the 
main trunk.
-pete


-- 
peter royal -> [EMAIL PROTECTED]

---------------------------------------------------------------------
Please check that your question has not already been answered in the
FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>

Reply via email to