Providing locale specific content for a given locale
You can add localized content to a new or existing API element, or add a new locale.
Adding localized text for existing API elements
The base configuration provides several schema.display_LOCALE.properties files, but these files are incomplete. You can complete these files by adding localized text for existing API elements.
In this case, you must do the following:
- In each schema.display_LOCALE.properties file, add the necessary
key/value pairs.
- The keys must match the required pattern to identify the appropriate API element.
- The value must be the localized text.
Adding localized text for new API elements
You can add localized text for new API elements for a locale that is already present in the base configuration. This could be required in the following situations:
- You extend a base configuration resource to include additional fields.
- You generate new endpoints using the REST endpoint Generator.
In this case, you must do the following:
- In the relevant
schema.json
files, add the localization key prefix. - In the relevant
swagger.yaml
files, add the localization key prefix. - In each schema.display_LOCALE.properties file, add the necessary
key/value pairs.
- The keys must match the required pattern to identify the appropriate API element.
- The value must be the localized text.
Adding a new locale
You can add localized text for a new locale. This could be required when you need to support a locale that is not present in the base configuration.
In this case, you must do the following:
- Create a new schema.display_LOCALE.properties file in the
/modules/configuration/config/locale
directory. - In this file, add the necessary key/value pairs.
- The keys must match the required pattern to identify the appropriate API element.
- The value must be the localized text.
Note that each InsuranceSuite instance can have only one schema.display.properties file for a given locale.