GSoC 2010 – week summary: May 17th – May 23th
This week I continued my work on automatic locale detection and locale fundamentals in FLOW3. Firstly I committed my tree of locales. It was an internal structure to store all available locales (installed in FLOW3), with some hierarchical relations between them. The locale hierarchy is very important aspect in my proposal. For example, when there is no resource file (eg image) defined for en_GB locale, but exists for en locale, this one will be used. This simplifies internationalization process.
But then Karsten, my mentor, reviewed the code, and said it is rubbish ;-(. Ok, I’m joking, but he proposed that I rethink the tree structure, in order to create something with lower complexity. He was right (of course ;-) ) and I reimplemented the locales structure. Now it uses only two arrays, and there is still a hierarchical functionality.
I also made some code cleaning in that commit. It looks way simpler now, I hope Karsten will be satisfied (he didn’t review the code yet as he was on T3CON10). I also added first part of the code responsible for resource localization.
Then I did one more commit. This one was small – the result of code which automatically detects all locale available in the system is cached from now.
For next week I plan to implement CLDR data reader. CLDR is the Unicode’s project, which provides very extensive data specifying rules for number formatting, currencies, plural forms, and many many more, in XML format. FLOW3 needs to be able to read this data in order to provide sophisticated and always up-to-date localization functionality.