This week's book giveaway is in the Mac OS forum. We're giving away four copies of a choice of "Take Control of Upgrading to Yosemite" or "Take Control of Automating Your Mac" and have Joe Kissell on-line! See this thread for details.
Hi When we use resource bundles, does all the contents of a given resource bundle gets loaded into memory or do they get loaded only as and when used. I was wondering, if defining multiple Resource Bundles for different parts of an application would reduce the memory consumption. Please let me know. Thanks Sumit
yes, the entire file is read in at once. For performance reasons you might therefore want to declare them as static and/or use a Singleton pattern to access them. Something like the stuff Eclipse generates for you when you externalise Strings from an application would do nicely:
Joined: Aug 04, 2003
Hi Thanks for your valuable input. So when is the file read - when the first Key is Read ?? Sumit
subject: Usage of Resource Bundles and Memory consumption