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 http://developer.brewmp.com/resources 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.
- CParser is the factory that parses the supported file types, currently CAR and Excel. Similarly, CExport exports the content to the supported file types.
- BREWStrItem defines the row of the string table.
- BREWStringTables maintains the list of loaded string tables.
- LoadFile loads the CAR or .xlsx file by parsing the string resources.
- LoadStringTable loads the list of string table (list each BREWStrItem).
- MergeFile or MergeFileFromObject merges the input data into the loaded string tables.
- DiffFile or DiffFileFromObject finds the differences in the string table content between input data and loaded string tables.
- ReadFileAsStringTables returns the list of loaded string tables.
- SaveAs saves the loaded string tables in the supported file formats.