Guardian Native C Library Calls Reference Manual (G06.28+, H06.04+)
Guardian Native C Library Calls (t - z) wcsspn(3)
NAME
wcsspn - Returns the length of the initial segment of a string
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 <wchar.h>
size_t wcsspn(
const wchar_t *wcstring1,
const wchar_t *wcstring2);
PARAMETERS
wcstring1 Points to a wide-character string that is being checked for an initial segment.
wcstring2 Points to a wide-character string that contains a set of characters that define the
initial segment.
DESCRIPTION
The wcsspn( ) and wcscspn() functions compute the number of wchar_t characters in the initial
segment of the string.
The wcsspn( ) function considers the initial segment to consist of all characters that are included
in the set of characters pointed to by the wcstring2 parameter. It counts these characters until it
finds one that is not included in the set.
RETURN VALUES
Upon successful completion, the wcsspn() function returns the number of wchar_t characters in
the segment. Otherwise, it returns a value of -1 cast to size_t.
RELATED INFORMATION
Functions: setlocale(3), strspn(3), wcscspn(3).
527192-005 Hewlett-Packard Company 7−67