To be clear:

Yes, the entire file is parsed - which means it will reside in memory during parsing - but only the requested language is kept in memory.

If file size becomes a problem, then we could convert to SAX parsing of UI label files.

Adrian Crum
Sandglass Software
www.sandglass-software.com

On 5/6/2015 12:50 PM, Adam Heath wrote:
Well, hmm.  Nothing at all wrong with this change, but I'd like to
discuss the pattern.

So, the way alternative languages are implemented, is that if I am only
concerned with *one* language, *all* languages have to be loaded in
memory.  Wouldn't it make more sense to split all these files into
per-language-specific versions, so that only languages that an
end-customer needs would have to be loaded into memory?

Then, the name of the file ends up using the very same fallback
mechanism for normal *.properties resources.

On 05/06/2015 02:35 PM, chr...@apache.org wrote:
Modified: ofbiz/trunk/applications/product/config/ProductEntityLabels.xml
URL:
http://svn.apache.org/viewvc/ofbiz/trunk/applications/product/config/ProductEntityLabels.xml?rev=1678076&r1=1678075&r2=1678076&view=diff

==============================================================================

--- ofbiz/trunk/applications/product/config/ProductEntityLabels.xml
(original)
+++ ofbiz/trunk/applications/product/config/ProductEntityLabels.xml
Wed May  6 19:35:24 2015
@@ -388,6 +388,7 @@
          <value xml:lang="zh-TW">倉庫</value>
      </property>
      <property key="GoodIdentificationType.description.GOOGLE_ID">
+        <value xml:lang="de">Google Id</value>
          <value xml:lang="en">Google Id</value>
          <value xml:lang="it">Codice Google</value>
          <value xml:lang="ja">Google ID</value>
@@ -396,6 +397,7 @@
          <value xml:lang="zh-TW">谷歌用戶名</value>
      </property>
      <property key="GoodIdentificationType.description.ISBN">
+        <value xml:lang="de">ISBN</value>
          <value xml:lang="en">ISBN</value>
          <value xml:lang="es">ISBN</value>
          <value xml:lang="fr">ISBN</value>

Reply via email to