Localization refers to enabling an application to display different resources at different locations. The most obvious and common example of localization is displaying text in different languages based on location or user selection. Localization is different from building entirely unique applications for each locale. Instead, the same code base is used for all locales, but different resource bundles are used for different locales. There are two basic variations on how this is implemented: compile time and runtime.

Compile-time localization means that you create a unique .swf for each locale. For example, if you want to support both French and Spanish, with compile-time localization you must create two .swf files: one for French and one for Spanish. Although with compile-time localization you create unique .swf files for each locale, each file uses the same code base. That means you don’t have to build and maintain separate application code bases. What is different between the .swf files is the resource bundle(s) that gets compiled into the .swf. We’ll talk more about resource bundles in just a minute.

Runtime localization allows you to create and deploy just one .swf containing your main application architecture. Runtime localization still uses resource bundles just like compile-time localization. However, rather than compiling the resource bundles for just one locale into the application runtime localization, necessitating different .swf files for each locale, runtime ...

Get Programming Flex 3 now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.