Performs operations on a specified number of null-terminated multibyte characters.
Standard C Library (libc.a)
#include <mbstr.h>
char *mbsncat(MbString1, MbString2, Number)
char * MbString1, * MbString2;
size_t Number;
int mbsncmp(MbString1, MbString2, Number) char *MbString1, *MbString2; size_t Number;
char *mbsncpy(MbString1, MbString2, Number) char *MbString1, *MbString2; size_t Number;
The mbsncat, mbsncmp, and mbsncpy subroutines operate on null-terminated multibyte character strings.
The mbsncat subroutine appends up to the specified maximum number of multibyte characters from the MbString2 parameter to the end of the MbString1 parameter, appends a null character to the result, and then returns the MbString1 parameter.
The mbsncmp subroutine compares the collation weights of multibyte characters. The LC_COLLATE category specifies the collation weights for all characters in a locale. The mbsncmp subroutine compares up to the specified maximum number of multibyte characters from the MbString1 parameter to the MbString2 parameter. It then returns an integer greater than 0 if MbString1 is greater than MbString2. It returns 0 if the strings are equivalent. It returns an integer less than 0 if MbString1 is less than MbString2.
The mbsncpy subroutine copies up to the value of the Number parameter of multibyte characters from the MbString2 parameter to the MbString1 parameter and returns MbString1. If MbString2 is shorter than Number multi-byte characters, MbString1 is padded out to Number characters with null characters.
MbString1 | Contains a multibyte character string. |
MbString2 | Contains a multibyte character string. |
Number | Specifies a maximum number of characters. |
The mbscat, mbscmp, or mbscpy Subroutine, mbscat, mbscmp, or mbscpy Subroutine, mbscat, mbscmp, or mbscpy Subroutine, wcsncat subroutine, wcsncmp subroutine, wcsncpy subroutine.
, Subroutines, Example Programs, and Libraries in AIX 5L Version 5.2 General Programming Concepts: Writing and Debugging Programs.
National Language Support Overview in AIX 5L Version 5.2 National Language Support Guide and Reference.