A properties bundle consists of multiple properties files that vary in the file name by an injection of a locale code before the file extension. Our convention is that each bundle must contain a properties file without injection. This file acts as a root for the bundle and as a fall-back for locales that are not found:Examples:
code.properties: The root and fall-back.
code_de.properties: The German member of the bundle.
The predicates get_properties/[2,3] allow retrieving a locale
properties file of a resource bundle. These predicates make use of
the predicate absolute_resource_name/2 to resolve the root so that
the same base name without an extension can be used for both
Prolog text and resource bundles. The predicates
get_property/[3,4] allow retrieving a property value.
test(Y) :- get_properties('code',X), get_property(X,'foo',Y).
X = bar
The resource bundle of a properties file has to be loaded in
advanced via the predicate sys_load_resource/1 and will then be
cached for faster subsequent access. The predicates
get_error_properties/[1,2] allow retrieving a union of those
properties files, which were registered via sys_register_file/1 in
The predicate atom_format/[3,4] allows formatting a list of arguments based on a template and a locale. The predicates message_make/[3,4] allows formatting a term based on properties file and a locale. The predicates get_descr_model/[2,3] and get_descr_platform/[2,3] respective capability defined properties files.The following locale predicates are provided:
The following locale Prolog flags are provided: