HP-UX Directory Server 8.1 plug-in reference

Table Of Contents
41 Functions related to UTF-8
This chapter contains reference information on routines that are related to UTF-8.
Table 41-1 UTF-8 related routines
DescriptionFunction
Checks if a string has an 8-bit character.“slapi_has8thBit()”
Makes case-insensitive string comparison of two UTF-8 strings.“slapi_utf8casecmp()”
Compares two UTF-8 strings.“slapi_UTF8CASECMP()”
Makes case-insensitive string comparison of first n characters of two UTF-8
strings.
“slapi_utf8ncasecmp()”
Compares a specified number of UTF-8 characters.“slapi_UTF8NCASECMP()”
Verifies if a UTF-8 character is a lowercase letter.“slapi_utf8isLower()”
Verifies if a UTF-8 character is a lowercase letter.“slapi_UTF8ISLOWER()”
Verifies if a UTF-8 character is an uppercase letter.“slapi_utf8isUpper()”
Verifies if a UTF-8 character is an uppercase letter.“slapi_UTF8ISUPPER()”
Converts uppercase characters in a UTF-8 string to lowercase characters.“slapi_utf8StrToLower()”
Converts uppercase characters in a UTF-8 string to lowercase characters.“slapi_UTF8STRTOLOWER()”
Converts lowercase characters in a UTF-8 string to uppercase characters.“slapi_utf8StrToUpper()”
Converts lowercase characters in a UTF-8 string to uppercase characters.“slapi_UTF8STRTOUPPER()”
Convert an uppercase UTF-8 character to lowercase character.“slapi_utf8ToLower()”
Converts an uppercase UTF-8 character to lowercase character.“slapi_UTF8TOLOWER()”
Converts a lowercase UTF-8 character to an uppercase character.“slapi_utf8ToUpper()”
Converts a lowercase UTF-8 character to an uppercase character.“slapi_UTF8TOUPPER()”
41.1 slapi_has8thBit()
Checks if a string has an 8-bit character.
Syntax
#include "slapi-plugin.h"
int slapi_has8thBit(unsigned char *s);
Parameters This function takes the following parameter:
Pointer to the null-terminated string to test.
s
Returns This function returns one of the following values:
1 if the string contains an 8-bit character.
0 if it does not.
41.2 slapi_utf8casecmp()
Description The function takes two UTF-8 strings (s0, s1) of unsigned char to be compared.
The comparison rules are as follows:
41.1 slapi_has8thBit() 327