Xafari Localizer


The Xafari framework includes the XafariResourceLocalizer class, starting from the x11 version. This class was implemented to provide a unified approach to localizing the applications built on the Xafari platform. Before the introduction of this class, the developers might use a number of different ways to support the localization of the application, such as utilizing various layers of the Application Model, storing data in .resx resource files, etc.

The XafariResouceLocalizer<EnumType> base class offers a convenient opportunity to implement the localization support and also allows switching to different localizations or creating a new one in the Model Editor.


The new and unified approach to localizing Xafari applications is based on the following principles:

  • The path to the resource file is defined in the descendant of the XafariResourceLocalizer base class in the ResourceName property.
  • The list of data for localizing strings is stored as enum.
  • All data for the localizations is stored in .resx files.
  • The localizer is registered in the module via the GetXafResourceLocalizerTypes() method.

When using this method of localization, the file structure looks approximately as follows:


Advantages of using Xafari Localizer

The new approach to implementing localizations can handle the tasks more flexibly, compared to the earlier solutions:

  • It is now possible to change the localized properties right in the Model Editor.
  • The localizations can be created or modified in a few simple steps.
  • The developer can add or customize localizations in both runtime and design-time.

New options become available as soon as the Localizer is properly set up.

For more info, refer to the following page:

Getting Started