Resources | Resources |



Creating custom localization tools

Brew MP provides an lLocalization library that is used by the Excel Add-in to convert CAR files to XLS files or XLS to CAR. This library is a COM library that can be used by manufacturers to create their own localization tools.

BREWMPStringLocalizationLibrary contains the logic for working with CAR and Excel files.

The Tools Reference contains several localization-related topics, including help for the Excel add-in. Search for "language." The reference is available in the SDK and in on the Brew MP website.

This COM library is written in C# and can be used in programming or scripting languages. IBREWMPStringResources exposes the APIs for extending the dual interface. The class diagram of the library is flexible enough to support plug-ins of any file format, as shown in the following diagram:

Classes and functions in ILocalization library

IBREWMPStringResources is implemented by CBREWMPStringResources class. It simply delegates the function calls to the corresponding factory classes.

  1. CParser is the factory that parses the supported file types, currently CAR and Excel. Similarly, CExport exports the content to the supported file types.
  2. BREWStrItem defines the row of the string table.
  3. BREWStringTables maintains the list of loaded string tables.
  4. LoadFile loads the CAR or .xlsx file by parsing the string resources.
  5. LoadStringTable loads the list of string table (list each BREWStrItem).
  6. MergeFile or MergeFileFromObject merges the input data into the loaded string tables.
  7. DiffFile or DiffFileFromObject finds the differences in the string table content between input data and loaded string tables.
  8. ReadFileAsStringTables returns the list of loaded string tables.
  9. SaveAs saves the loaded string tables in the supported file formats.