NCCTYPE(3,L) AIX Technical Reference NCCTYPE(3,L)
-------------------------------------------------------------------------------
NCctype
PURPOSE
Classify characters for international character support environments.
SYNTAX
#include <NLctype.h>
int NCisNLchar (x) int NCisalnum (x)
int x; int x;
int NCisalpha (x) int NCisspace (x)
int x; int x;
int NCisupper (x) int NCispunct (x)
int x; int x;
int NCislower (x) int NCisprint (x)
int x; int x;
int NCisdigit (x) int NCisgraph (x)
int x; int x;
int NCisxdigit (x) int NCiscntrl (x)
int x; int x;
int NCisshift (x)
int x;
DESCRIPTION
Note: In the multibyte environment, the NCctype routines are provided for
backward compatibility. All the NCctype routines listed above are only
front-ends to the ctype routines (see "ctype"). Avoid using them if you
wish to write portable programs. Note that NCisshift always returns 0.
Character classification is user-configurable per process, through the table
file indicated by the environment variable LANG or LC_COLLATE.
These macros classify character-coded integer values using information
specified by the current LANG or LC_COLLATE file configuration. The parameter
x is tested as an NLchar (an extended character); each macro is a predicate
form returning 0 for false, and a nonzero value for true. The value of x is in
Processed November 7, 1990 NCCTYPE(3,L) 1
NCCTYPE(3,L) AIX Technical Reference NCCTYPE(3,L)
the domain of any legal NLchar in a value range from 0 to NLCHARMAX-1
inclusive, or a special value of -1. If the value of x is not in the domain of
the macro, the result is undefined.
The NCisNLchar macro is defined on all valid integer values, whereas the other
macros are defined only where NCisNLchar is true, and on the special value of
-1 (EOF). See "stdio."
When a nonzero value is returned for x:
NCisNLchar x is a valid NLchar with a value between 0 and NLCHARMAX-1,
inclusive.
NCisalpha x is an alphabetical character.
NCisupper x is an uppercase alphabetical character.
NCislower x is a lowercase letter.
NCisdigit x is a decimal digit (0-9).
NCisxdigit x is a hexadecimal digit (0-9, A-F (or a-f)).
NCisalnum x is an alphanumeric character or digit.
NCisspace x is a space, tab, carriage return, new-line, vertical tab, or
form-feed character.
NCispunct x is a punctuation character (neither a control character nor an
alphanumeric character).
NCisprint x is a printing character (including the space character).
NCisgraph x is a printing character, excluding the space character.
NCiscntrl x is an ASCII delete character (0177) or an ordinary ASCII control
character other than the four single-shift characters.
NCisshift x is one of the four single-shift characters that is used as the
first byte of an extended character.
RELATED INFORMATION
In this book: "conv," "ctype," "getc, fgetc, getchar, getw, getwc, fgetwc,
getwchar," "NLchar," "stdio," and "environment."
"Introduction to International Character Support" in Managing the AIX Operating
System.
AIX Guide to Multibyte Character Set (MBCS) Support.
Processed November 7, 1990 NCCTYPE(3,L) 2