HP-UX Reference (11i v1 00/12) - 3 Library Functions N-Z (vol 7)
__________________________________________________________________________________________________________________________________________________________________________________________________
__________________________________________________________________________________________________________________________________________________________________________________________________
STANDARD Printed by: Nora Chuang [nchuang] STANDARD
/build/1111/BRICK/man3/nan.3m
________________________________________________________________
___ ___
w
wcstring(3C) wcstring(3C)
NAME
wcscat(), wcsncat(), wcscmp(), wcsncmp(), wcscpy(), wcsncpy(), wcslen(), wcschr(), wcsrchr(), wcsstr(),
wcspbrk(), wcsspn(), wcscspn(), wcswcs(), wcstok(), wcscoll(), wcwidth(), wcswidth(), wcsxfrm() - wide
character string operations
SYNOPSIS
#include <wchar.h>
wchar_t *wcscat(wchar_t *ws1, const wchar_t *ws2);
wchar_t *wcsncat(wchar_t *ws1, const wchar_t *ws2, size_t n);
int wcscmp(const wchar_t *ws1, const wchar_t *ws2);
int wcsncmp(const wchar_t *ws1, const wchar_t *ws2, size_t n);
wchar_t *wcscpy(wchar_t *ws1, const wchar_t *ws2);
wchar_t *wcsncpy(wchar_t *ws1, const wchar_t *ws2, size_t n);
size_t wcslen(const wchar_t *ws);
wchar_t *wcschr(const wchar_t *ws, wchar_t wc);
wchar_t *wcsrchr(const wchar_t *ws, wchar_t wc);
wchar_t *wcspbrk(const wchar_t *ws1, const wchar_t *ws2);
size_t wcsspn(const wchar_t *ws1, const wchar_t *ws2);
size_t wcscspn(const wchar_t *ws1, const wchar_t *ws2);
wchar_t *wcswcs(const wchar_t *ws1, const wchar_t *ws2);
wchar_t *wcstok(wchar_t *ws1, const wchar_t *ws2);
int wcscoll(const wchar_t *ws1, const wchar_t *ws2);
int wcwidth(wint_t wc);
int wcswidth(const wchar_t *ws, size_t n);
size_t wcsxfrm(wchar_t *ws1, const wchar_t *ws2, size_t n);
_INCLUDE__STDC_A1_SOURCE only
wchar_t *wcstok(wchar_t *ws1, const wchar_t *ws2, wchar_t **ptr);
wchar_t *wcsstr(const wchar_t *ws1, const wchar_t *ws2);
Obsolescent Interface
wchar_t *wcstok_r(wchar_t *ws1, const wchar_t *ws2, wchar_t **wlast);
Remarks:
These functions are compliant with the XPG4 Worldwide Portability Interface wide-character string
handling functions. They parallel the 8 bit string functions defined in string(3C).
DESCRIPTION
The arguments ws1, ws2, and ws point to wide character strings (arrays of type wchar_t
terminated by
a null value).
wcscat() appends a copy of wide string ws2 to the end of wide string ws1. wcsncat()
appends a
maximum of n characters; fewer if ws2 is shorter than n characters. Each returns a pointer to the null-
terminated result (the value of ws1).
wcscmp() compares its arguments and returns an integer less than, equal to, or greater than zero,
depending on whether ws1 is lexicographically less than, equal to, or greater than ws2. The comparison of
corresponding wide characters is done by comparing numeric values of the wide character codes. Null
pointer values for ws1 and ws2 are treated the same as pointers to empty wide strings.
wcsncmp()
makes the same comparison but examines a maximum of n characters (n less than or equal to zero yields
equality).
wcscpy() copies wide string ws2 to ws1, stopping after the null value has been copied. wcsncpy()
copies up to n characters from ws2, adding null values to ws1 if necessary, until a total of n have been
Section 3−−1018 − 1 − HP-UX Release 11i: December 2000
___
___