XNLSopenmsgdom
XNLSopenmsgdom |
Purpose
Synopsis
XNLSdomain XNLSopenmsgdom(const char *name, const char *localedir);
Arguments
name
|
Domain name
|
localedir
|
Locale directory for this domain (can be
NULL)
|
Return value
A context for the domain or
NULL in case of error.
Further information
1. The default locale directory is used if the
localedir parameter is
NULL. The current working directory will be used if the resulting locale directory is
NULL.
2. The domain name
name is used to build file names of message catalogs. For instance the message catalog for domain
"mosel", language
"es" in the locale directory
"/usr/share/locale" is
"/usr/share/locale/es/LC_MESSAGES/mosel.mo"
3. Message catalogs are opened when the first
XNLSgettext call is issued, not at the time of opening the domain.
4. The same domain context will be returned if a given domain name is open several times (the
localedir parameter is ignored when the domain is already open). The system keeps track of the number of times each domain context has been returned and requires an equal number of calls to
XNLSclosemsgdom to release properly the resources associated with the domain.
Related topics