Localize the Resource Bundle

About this task

The complete resource bundles in the ycrnbundle.properties file are always released with the localized versions of the IBM® Sterling Warehouse Management System Business Intelligence. Incremental updates are not provided. If you localize the IBM Sterling Warehouse Management System reports, it is your responsibility or that of your third-party localization company to compare and validate the differences between the resource bundles shipped with the product to those that you have localized.

The resource bundles of IBM Sterling Warehouse Management System Business Intelligence are located in the <YNW_ANALYTICS_HOME>/resources/ycrnbundle.properties file.

To localize the resource bundles:

Procedure

  1. Copy the <YNW_ANALYTICS_HOME>/resources/ycrnbundle.properties file and save it as <YNW_ANALYTICS_HOME>/resources/ycrnbundle_<language>_<country>.properties.
  2. Each resource bundle contains a <key>=<value> pair where key is the resource key and value is the literal displayed for the corresponding locale. Replace <value> with the translated value.
    • Some of the literals that need to be translated in the resource bundles contain data placeholders. These data placeholders indicate that the literal is displayed with one or more data values within the literal, for example, the application displays the error message "Priority should be greater than X" where X could be any number. Because the location of the X within the literal can be different for different languages, the resource bundle uses a placeholder that can be placed anywhere in the literal during translation. The resource bundle entry looks as follows:
         PRIORITY_ERROR_MESSAGE=Priority should be greater than {0}

      Notice how the {0} place holder indicates where the dynamic data value appears in the literal. This {0} can be placed anywhere in the literal, for example,

         PRIORITY_ERROR_MESSAGE=A number greater than {0} should be entered

      or

         PRIORITY_ERROR_MESSAGE={0}: Priority entered should be greater than this

      are valid possibilities. This gives you the flexibility to translate the literal in any way the language dictates. Note that multiple placeholders may appear in the literal as well, for example, {0}, {1}, {2}, and so forth. Each placeholder must exist somewhere in the corresponding translated literal.

    • When using literals that contain data placeholders, you cannot use single quotation marks. If a single quotation mark is used in conjunction with a placeholder, the single quotation mark is not displayed and the placeholder is not replaced with its replacement value. In order to avoid this situation, enter two single quotes wherever a single quote is required.

      The following is an invalid entry:

         PRIORITY_ERROR_MESSAGE=The primary organization’s name is {0}

      The following is valid entry:

         PRIORITY_ERROR_MESSAGE=The primary organization’’s name is {0}
    • Files should be returned in native format with UTF-8 encoding.
    • Properties should be returned in escaped Unicode format with UTF-8 encoding.
  3. Tahoma is used as default font. Therefore if you want to display or type Unicode characters, you should localize the theme. This is done by changing the font to Unicode in the theme-specific XML files.
  4. Save the modified file. If the file is in UTF-8 format, convert it to ASCII by running the native2ascii command as follows:
       native2ascii -encoding UTF-8 <source file> <target file>
       
    Note: Files localized in Latin1 languages do not require this conversion.

    The file should be returned in the following format:

       <filename>_<2 letter code for language as given by ISO 639>_<2 letter code 
    for territory as given by ISO 3166>.<file extension>

    For example, ycrnbundle.properties should be returned as ycrnbundle_fr_FR.properties.