Previous fileTop of DocumentContentsIndex pageNext file
Apache C++ Standard Library Reference Guide


Library:  Localization

Local Index

No Entries


A family of classes used to encapsulate categories of locale functionality


The Standard C++ Localization library includes a locale interface that contains a collection of diverse facets. Each facet has localization facilities for some specific area, such as character classification or numeric formatting. Each facet also falls into one or more broad categories. These categories are defined in the locale class, and the standard facets fit into these categories as follows.

Table 18: Categories and facets of the locale class

Category Facets


collate, collate_byname


ctype, codecvt, ctype_byname, codecvt_byname


moneypunct, moneypunct_byname, money_put, money_get


numpunct, numpunct_byname, num_put, num_get


time_put, time_put_byname, time_get, time_get_byname


messages, messages_byname

A facet must satisfy two properties. First, it must be derived from the base class locale::facet, either directly or indirectly (for example, facet -> ctype<char> -> my_ctype). Second, it must contain a member of type locale::id. This ensures that the locale class can manage its collection of facets properly.

See Also

locale, collate, collate_byname, ctype, codecvt, ctype_byname, codecvt_byname, moneypunct, moneypunct_byname, money_put, money_get, numpunct, numpunct_byname, num_put, num_get, time_put, time_put_byname, time_get, time_get_byname, messages, messages_byname

Standards Conformance

ISO/IEC 14882:1998 -- International Standard for Information Systems -- Programming Language C++, Section 22.2.8

Previous fileTop of DocumentContentsIndex pageNext file