Guardian Native C Library Calls Reference Manual (G06.28+, H06.05+)
Guardian Native C Library Calls (s) setlocale(3)
NAME
setlocale - Changes or queries the program’s current locale
LIBRARY
G-series native Guardian processes: $SYSTEM.SYSnn.ZCRTLSRL
G-series native OSS processes: /G/system/sysnn/zcrtlsrl
H-series native Guardian processes: $SYSTEM.ZDLLnnn.ZCRTLDLL
H-series OSS processes: /G/system/zdllnnn/zcrtldll
SYNOPSIS
#include <locale.h>
char *setlocale(
int category,
const char *locale);
PARAMETERS
category Specifies the category of the locale to set or query. The category can be
LC_ALL, LC_COLLATE, LC_CTYPE, LC_MESSAGES,
LC_MONETARY, LC_NUMERIC,orLC_TIME.
locale Points to a string that specifies the locale.
DESCRIPTION
The setlocale() function sets or queries the appropriate portion of the program’s locale as
specified by the category and locale parameters.
Guardian processes only support the C/POSIX locale. Thus, the setlocale() function always
returns "C" for Guardian processes if the arguments category and locale are valid.
The LC_ALL value for the category parameter names the entire locale; the other values name
only a portion of the program locale, as follows:
LC_COLLATE
Affects the behavior of collation functions and regular expressions.
LC_CTYPE Affects the behavior of character classification functions, character conversion
functions, and regular expressions.
LC_MESSAGES
Affects the language used to display application program and utilities messages
(when translations of the messages are available) and the strings expected as
affirmative and negative responses.
LC_MONETARY
Affects the behavior of functions that handle monetary values.
LC_NUMERIC
Affects the radix character for the formatted input/output functions and the string
conversion functions.
LC_TIME Affects the behavior of the time conversion functions.
The behavior of the language information function defined in the nl_langinfo() function is also
affected by settings of the category parameter.
The locale parameter points to a character string that identifies the locale that is to be used to set
the category parameter. The locale parameter can either specify the name of a locale, such as
fr_CA.ISO8859-1 or it can specify one of the following:
527192-007 Hewlett-Packard Company 6−19