?? ansistring.html
字號:
<html><head><!-- /vobs/wpwr/docs/vxworks/ref/ansiString.html - generated by refgen from ansiString.c --> <title> ansiString </title></head><body bgcolor="#FFFFFF"> <hr><a name="top"></a><p align=right><a href="libIndex.html"><i>VxWorks Reference Manual : Libraries</i></a></p></blockquote><h1>ansiString</h1> <blockquote></a></blockquote><h4>NAME</h4><blockquote> <p><strong>ansiString</strong> - ANSI <b>string</b> documentation </p></blockquote><h4>ROUTINES</h4><blockquote><p><p><b><i><a href="./ansiString.html#memchr">memchr</a></i>( )</b> - search a block of memory for a character (ANSI)<br><b><i><a href="./ansiString.html#memcmp">memcmp</a></i>( )</b> - compare two blocks of memory (ANSI)<br><b><i><a href="./ansiString.html#memcpy">memcpy</a></i>( )</b> - copy memory from one location to another (ANSI)<br><b><i><a href="./ansiString.html#memmove">memmove</a></i>( )</b> - copy memory from one location to another (ANSI)<br><b><i><a href="./ansiString.html#memset">memset</a></i>( )</b> - set a block of memory (ANSI)<br><b><i><a href="./ansiString.html#strcat">strcat</a></i>( )</b> - concatenate one string to another (ANSI)<br><b><i><a href="./ansiString.html#strchr">strchr</a></i>( )</b> - find the first occurrence of a character in a string (ANSI)<br><b><i><a href="./ansiString.html#strcmp">strcmp</a></i>( )</b> - compare two strings lexicographically (ANSI)<br><b><i><a href="./ansiString.html#strcoll">strcoll</a></i>( )</b> - compare two strings as appropriate to <b>LC_COLLATE</b> (ANSI)<br><b><i><a href="./ansiString.html#strcpy">strcpy</a></i>( )</b> - copy one string to another (ANSI)<br><b><i><a href="./ansiString.html#strcspn">strcspn</a></i>( )</b> - return the string length up to the first character from a given set (ANSI)<br><b><i><a href="./ansiString.html#strerror_r">strerror_r</a></i>( )</b> - map an error number to an error string (POSIX)<br><b><i><a href="./ansiString.html#strerror">strerror</a></i>( )</b> - map an error number to an error string (ANSI)<br><b><i><a href="./ansiString.html#strlen">strlen</a></i>( )</b> - determine the length of a string (ANSI)<br><b><i><a href="./ansiString.html#strncat">strncat</a></i>( )</b> - concatenate characters from one string to another (ANSI)<br><b><i><a href="./ansiString.html#strncmp">strncmp</a></i>( )</b> - compare the first <i>n</i> characters of two strings (ANSI)<br><b><i><a href="./ansiString.html#strncpy">strncpy</a></i>( )</b> - copy characters from one string to another (ANSI)<br><b><i><a href="./ansiString.html#strpbrk">strpbrk</a></i>( )</b> - find the first occurrence in a string of a character from a given set (ANSI)<br><b><i><a href="./ansiString.html#strrchr">strrchr</a></i>( )</b> - find the last occurrence of a character in a string (ANSI)<br><b><i><a href="./ansiString.html#strspn">strspn</a></i>( )</b> - return the string length up to the first character not in a given set (ANSI)<br><b><i><a href="./ansiString.html#strstr">strstr</a></i>( )</b> - find the first occurrence of a substring in a string (ANSI)<br><b><i><a href="./ansiString.html#strtok">strtok</a></i>( )</b> - break down a string into tokens (ANSI)<br><b><i><a href="./ansiString.html#strtok_r">strtok_r</a></i>( )</b> - break down a string into tokens (reentrant) (POSIX)<br><b><i><a href="./ansiString.html#strxfrm">strxfrm</a></i>( )</b> - transform up to <i>n</i> characters of <i>s2</i> into <i>s1</i> (ANSI)<br><p></blockquote><h4>DESCRIPTION</h4><blockquote><p>This library includes several standard ANSI routines. Note that wherethere is a pair of routines, such as <b><i><a href="./ansiStdlib.html#div">div</a></i>( )</b> and <b><i><a href="./ansiStdlib.html#div_r">div_r</a></i>( )</b>, only the routine<b><i>xxx_r</i>( )</b> is reentrant. The <b><i>xxx</i>( )</b> routine is not reentrant.<p>The header <b>string.h</b> declares one type and several functions, and defines onemacro useful for manipulating arrays of character type and other objectstreated as array of character type. The type is <b>size_t</b> and the macro NULL.Various methods are used for determining the lengths of the arrays, but inall cases a <b>char *</b> or <b>void *</b> argument points to the initial (lowestaddressed) character of the array. If an array is accessed beyond the endof an object, the behavior is undefined.<p></blockquote><h4>SEE ALSO</h4><blockquote><p><b><a href="./ansiString.html#top">ansiString</a></b>, American National Standard X3.159-1989<p><hr><a name="memchr"></a><p align=right><a href="rtnIndex.html"><i>Libraries : Routines</i></a></p></blockquote><h1><i>memchr</i>( )</h1> <blockquote></a></blockquote><h4>NAME</h4><blockquote> <p><strong><i>memchr</i>( )</strong> - search a block of memory for a character (ANSI)</p></blockquote><h4>SYNOPSIS</h4><blockquote><p><pre>void * memchr ( const void * m, /* block of memory */ int c, /* character to search for */ size_t n /* size of memory to search */ )</pre></blockquote><h4>DESCRIPTION</h4><blockquote><p>This routine searches for the first element of an array of <b>unsigned char</b>,beginning at the address <i>m</i> with size <i>n</i>, that equals <i>c</i> converted toan <b>unsigned char</b>.<p></blockquote><h4>INCLUDE FILES</h4><blockquote><p><b>string.h</b><p></blockquote><h4>RETURNS</h4><blockquote><p>If successful, it returns the address of the matching element;otherwise, it returns a null pointer.</blockquote><h4>SEE ALSO</h4><blockquote><p><b><a href="./ansiString.html#top">ansiString</a></b><hr><a name="memcmp"></a><p align=right><a href="rtnIndex.html"><i>Libraries : Routines</i></a></p></blockquote><h1><i>memcmp</i>( )</h1> <blockquote></a></blockquote><h4>NAME</h4><blockquote> <p><strong><i>memcmp</i>( )</strong> - compare two blocks of memory (ANSI)</p></blockquote><h4>SYNOPSIS</h4><blockquote><p><pre>int memcmp ( const void * s1, /* array 1 */ const void * s2, /* array 2 */ size_t n /* size of memory to compare */ )</pre></blockquote><h4>DESCRIPTION</h4><blockquote><p>This routine compares successive elements from two arrays of <b>unsigned char</b>,beginning at the addresses <i>s1</i> and <i>s2</i> (both of size <i>n</i>), until it findselements that are not equal.<p></blockquote><h4>INCLUDE FILES</h4><blockquote><p><b>string.h</b><p></blockquote><h4>RETURNS</h4><blockquote><p><p>If all elements are equal, zero. If elements differ and the differingelement from <i>s1</i> is greater than the element from <i>s2</i>, the routinereturns a positive number; otherwise, it returns a negative number.</blockquote><h4>SEE ALSO</h4><blockquote><p><b><a href="./ansiString.html#top">ansiString</a></b><hr><a name="memcpy"></a><p align=right><a href="rtnIndex.html"><i>Libraries : Routines</i></a></p></blockquote><h1><i>memcpy</i>( )</h1> <blockquote></a></blockquote><h4>NAME</h4><blockquote> <p><strong><i>memcpy</i>( )</strong> - copy memory from one location to another (ANSI)</p></blockquote><h4>SYNOPSIS</h4><blockquote><p><pre>void * memcpy ( void * destination, /* destination of copy */ const void * source, /* source of copy */ size_t size /* size of memory to copy */ )</pre></blockquote><h4>DESCRIPTION</h4><blockquote><p>This routine copies <i>size</i> characters from the object pointedto by <i>source</i> into the object pointed to by <i>destination</i>. If copyingtakes place between objects that overlap, the behavior is undefined.<p></blockquote><h4>INCLUDE FILES</h4><blockquote><p><b>string.h</b><p></blockquote><h4>RETURNS</h4><blockquote><p>A pointer to <i>destination</i>.</blockquote><h4>SEE ALSO</h4><blockquote><p><b><a href="./ansiString.html#top">ansiString</a></b><hr><a name="memmove"></a><p align=right><a href="rtnIndex.html"><i>Libraries : Routines</i></a></p></blockquote><h1><i>memmove</i>( )</h1> <blockquote></a></blockquote><h4>NAME</h4><blockquote> <p><strong><i>memmove</i>( )</strong> - copy memory from one location to another (ANSI)</p></blockquote><h4>SYNOPSIS</h4><blockquote><p><pre>void * memmove ( void * destination, /* destination of copy */ const void * source, /* source of copy */ size_t size /* size of memory to copy */ )</pre></blockquote><h4>DESCRIPTION</h4><blockquote><p>This routine copies <i>size</i> characters from the memory location <i>source</i> tothe location <i>destination</i>. It ensures that the memory is not corruptedeven if <i>source</i> and <i>destination</i> overlap.<p></blockquote><h4>INCLUDE FILES</h4><blockquote><p><b>string.h</b><p></blockquote><h4>RETURNS</h4><blockquote><p>A pointer to <i>destination</i>.</blockquote><h4>SEE ALSO</h4><blockquote><p><b><a href="./ansiString.html#top">ansiString</a></b><hr><a name="memset"></a><p align=right><a href="rtnIndex.html"><i>Libraries : Routines</i></a></p></blockquote><h1><i>memset</i>( )</h1> <blockquote></a></blockquote><h4>NAME</h4><blockquote> <p><strong><i>memset</i>( )</strong> - set a block of memory (ANSI)</p></blockquote><h4>SYNOPSIS</h4><blockquote><p><pre>void * memset ( void * m, /* block of memory */ int c, /* character to store */ size_t size /* size of memory */ )</pre></blockquote><h4>DESCRIPTION</h4><blockquote><p>This routine stores <i>c</i> converted to an <b>unsigned char</b> in each of theelements of the array of <b>unsigned char</b> beginning at <i>m</i>, with size <i>size</i>.<p></blockquote><h4>INCLUDE FILES</h4><blockquote><p><b>string.h</b><p></blockquote><h4>RETURNS</h4><blockquote><p>A pointer to <i>m</i>.</blockquote><h4>SEE ALSO</h4><blockquote><p><b><a href="./ansiString.html#top">ansiString</a></b><hr><a name="strcat"></a><p align=right><a href="rtnIndex.html"><i>Libraries : Routines</i></a></p></blockquote><h1><i>strcat</i>( )</h1> <blockquote></a></blockquote><h4>NAME</h4><blockquote> <p><strong><i>strcat</i>( )</strong> - concatenate one string to another (ANSI)</p></blockquote><h4>SYNOPSIS</h4><blockquote><p><pre>char * strcat ( char * destination, /* string to be appended to */ const char * append /* string to append to <i>destination</i> */ )</pre></blockquote><h4>DESCRIPTION</h4><blockquote><p>This routine appends a copy of string <i>append</i> to the end of string <i>destination</i>. The resulting string is null-terminated.<p></blockquote><h4>INCLUDE FILES</h4><blockquote><p><b>string.h</b><p></blockquote><h4>RETURNS</h4><blockquote><p>A pointer to <i>destination</i>.</blockquote><h4>SEE ALSO</h4><blockquote><p><b><a href="./ansiString.html#top">ansiString</a></b><hr><a name="strchr"></a><p align=right><a href="rtnIndex.html"><i>Libraries : Routines</i></a></p></blockquote><h1><i>strchr</i>( )</h1> <blockquote></a></blockquote><h4>NAME</h4><blockquote> <p><strong><i>strchr</i>( )</strong> - find the first occurrence of a character in a string (ANSI)</p></blockquote><h4>SYNOPSIS</h4><blockquote><p><pre>char * strchr ( const char * s, /* string in which to search */ int c /* character to find in string */ )</pre></blockquote><h4>DESCRIPTION</h4><blockquote><p>This routine finds the first occurrence of character <i>c</i>in string <i>s</i>. The terminating null is considered to be part of the string.<p></blockquote><h4>INCLUDE FILES</h4><blockquote><p><b>string.h</b><p></blockquote><h4>RETURNS</h4><blockquote><p><p>The address of the located character, or NULL if the character is not found.</blockquote><h4>SEE ALSO</h4><blockquote><p><b><a href="./ansiString.html#top">ansiString</a></b><hr><a name="strcmp"></a><p align=right><a href="rtnIndex.html"><i>Libraries : Routines</i></a></p></blockquote><h1><i>strcmp</i>( )</h1> <blockquote></a></blockquote><h4>NAME</h4><blockquote> <p><strong><i>strcmp</i>( )</strong> - compare two strings lexicographically (ANSI)</p></blockquote><h4>SYNOPSIS</h4><blockquote><p><pre>int strcmp
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -