Java resource bundle
Encyclopedia
A resource bundle is a Java .properties
.properties
.properties is a file extension for files mainly used in Java related technologies to store the configurable parameters of an application. They can also be used for storing strings for Internationalization and localization; these are known as Property Resource Bundles.Each parameter is stored as a...

 file that contains locale
Locale
In computing, locale is a set of parameters that defines the user's language, country and any special variant preferences that the user wants to see in their user interface...

-specific data. It is a way of internationalising a Java application by making the code locale-independent.

Benefits of using resource bundles

Extracting locale-sensitive objects such as strings from the code (as opposed to hard-coding them) means that the application can handle multiple locales without having to write different code for each locale. It also means that translators can deal with just the translatable text and not the programming code. Therefore, using resource bundles improves the internationalisation and the localisation
Internationalization and localization
In computing, internationalization and localization are means of adapting computer software to different languages, regional differences and technical requirements of a target market...

 process of a software product.

Translating a resource bundle

Some CAT tools like OmegaT
OmegaT
OmegaT is a computer-assisted translation tool written in the Java programming language. It is free software originally developed by Keith Godfrey in 2000, and is currently developed by a team led by Didier Briel. The name OmegaT is a registered trademark in Germany.OmegaT is intended for...

, OmegaT+, Swordfish or Sun's Open language tools
Open language tools
Open Language Tools is a Java project released by Sun Microsystems under the terms of Sun’s CDDL .Open Language Tools are intended for people who are involved in translation of software and documentation into different natural languages...

 can specifically handle resource bundles. In addition to these, translators can use any text editor
Text editor
A text editor is a type of program used for editing plain text files.Text editors are often provided with operating systems or software development packages, and can be used to change configuration files and programming language source code....

 to create new resource bundles or to modify existing ones.

JavaPM is a free cross-platform utility that that assists software developers in the localization of Java projects. JavaPM converts Java .properties files to XLIFF 1.2 format, allowing their localization using most modern translation environments. Once the XLIFF
XLIFF
XLIFF is an XML-based format created to standardize localization. XLIFF was standardized by OASIS in 2002. Its current specification is v1.2 released on Feb-1-2008....

files have been translated, JavaPM inserts the translations into the Java project, creating new .properties files or updating existing ones as necessary.
The source of this article is wikipedia, the free encyclopedia.  The text of this article is licensed under the GFDL.
 
x
OK