Library class which provides methods for retrieving messages from properties
resource bundles which contain locale-specific strings. When your program
needs a locale-specific String, it loads it from the resource bundle that is
appropriate for the user's current locale. In this way, the program code is
largely independent of the user's locale.
In Commerce Cloud Digital, resources are associated with the templates of a cartridge.
These bundles consist of properties files with a common name defined in the
template/resources directory of a site cartridge. For example:
- templates/resources/message.properties
- templates/resources/message_en.properties
- templates/resources/message_en_US.properties
- templates/resources/message_de_DE.properties
Resource bundle lookup generally follows the same rules as the Java
ResourceBundle class, where the locale used for lookup is based on the
current request. See method javadoc for additional details.
Properties resource files are assumed to use the UTF-8 character
encoding. Unicode escape sequences are also supported.