Y-lib
Loadrunner libraries
|
Standard C functions using null terminated C strings (defined in stdio.h, cstring.h) More...
Macros | |
#define | strcat(to, from) 0_DO_NOT_USE_strcat_THERE_IS_ALWAYS_A_BETTER_SOLUTION |
Force a compile time error when strcat() is used. Because the use of strcat() is a very strong indicator for poorly written code being compiled – there is always a better solution! More... | |
#define | strcpy(dest, source) 0_DO_NOT_USE_strcpy_DUPLICATION_IS_NOT_REQUIRED |
Force a compile time error when strcpy() is used. The use of strcpy is banned because in practice strcpy is only used by novice coders doing unnecessary duplicating. (Typically when trying to avoid using pointers when actually using pointers.) Evaluate your coding solution and avoid duplication. If you must, use the safer strncpy or snprintf. More... | |
Standard C functions using null terminated C strings (defined in stdio.h, cstring.h)
#define strcat | ( | to, | |
from | |||
) | 0_DO_NOT_USE_strcat_THERE_IS_ALWAYS_A_BETTER_SOLUTION |
Force a compile time error when strcat() is used.
Because the use of strcat() is a very strong indicator for poorly written code being compiled – there is always a better solution!
Unfortunately the use of #error is not possible here.
#define strcpy | ( | dest, | |
source | |||
) | 0_DO_NOT_USE_strcpy_DUPLICATION_IS_NOT_REQUIRED |
Force a compile time error when strcpy() is used.
The use of strcpy is banned because in practice strcpy is only used by novice coders doing unnecessary duplicating. (Typically when trying to avoid using pointers when actually using pointers.)
Evaluate your coding solution and avoid duplication. If you must, use the safer strncpy or snprintf.
double atof | ( | const char * | string | ) |
Documented at http://www.cplusplus.com/reference/cstdlib/atof/.
int atoi | ( | const char * | string | ) |
Documented at http://www.cplusplus.com/reference/cstdlib/atoi/.
long atol | ( | const char * | string | ) |
Documented at http://www.cplusplus.com/reference/cstdlib/atol/.
int itoa | ( | int | value, |
char * | str, | ||
int | radix | ||
) |
Documented at http://www.cplusplus.com/reference/cstdlib/itoa/.
int snprintf | ( | char * | buffer, |
size_t | n, | ||
const char * | format_string, | ||
... | |||
) |
Documented at http://www.cplusplus.com/reference/cstdio/snprintf/.
This function was introduced by the latest revision of the C++ standard (2011). Older compilers may not support it.
int sprintf | ( | char * | buffer, |
const char * | format_string, | ||
... | |||
) |
Documented at http://www.cplusplus.com/reference/cstdio/sprintf/.
You should prefer snprintf over sprintf.
int sscanf | ( | const char * | buffer, |
const char * | format_string, | ||
... | |||
) |
Documented at http://www.cplusplus.com/reference/cstdio/sscanf/.
char* strchr | ( | const char * | string, |
int | c | ||
) |
Documented at http://www.cplusplus.com/reference/cstring/strchr/.
int strcmp | ( | const char * | string1, |
const char * | string2 | ||
) |
Documented at http://www.cplusplus.com/reference/cstring/strcmp/.
char* strdup | ( | const char * | string | ) |
int stricmp | ( | const char * | string1, |
const char * | string2 | ||
) |
size_t strlen | ( | const char * | string | ) |
Documented at http://www.cplusplus.com/reference/cstring/strlen/.
char* strlwr | ( | char * | string | ) |
char* strncat | ( | char * | to_string, |
const char * | from_string, | ||
size_t | n | ||
) |
Documented at http://www.cplusplus.com/reference/cstring/strncat/.
int strncmp | ( | const char * | string1, |
const char * | string2, | ||
size_t | n | ||
) |
Documented at http://www.cplusplus.com/reference/cstring/strncmp/.
char* strncpy | ( | char * | destination, |
const char * | source, | ||
size_t | num | ||
) |
Documented at http://www.cplusplus.com/reference/cstring/strncpy/.
int strnicmp | ( | const char * | string1, |
const char * | string2, | ||
size_t | num | ||
) |
char* strrchr | ( | const char * | string, |
int | c | ||
) |
Documented at http://www.cplusplus.com/reference/cstring/strrchr/.
char* strset | ( | char * | string1, |
int | character | ||
) |
size_t* strspn | ( | const char * | string, |
const char * | skipset | ||
) |
Documented at http://www.cplusplus.com/reference/cstring/strspn/.
char* strstr | ( | const char * | string1, |
const char * | string2 | ||
) |
Documented at http://www.cplusplus.com/reference/cstring/strstr/.
double strtod | ( | const char * | str, |
char ** | endptr | ||
) |
Documented at http://www.cplusplus.com/reference/cstdlib/strtod/.
char* strtok | ( | char * | string, |
const char * | delimiters | ||
) |
Documented at http://www.cplusplus.com/reference/cstring/strtok/.
long strtol | ( | const char * | string, |
char ** | endptr, | ||
int | radix | ||
) |
Documented at http://www.cplusplus.com/reference/cstdlib/strtol/.
unsigned long int strtoul | ( | const char * | str, |
char ** | endptr, | ||
int | base | ||
) |
Documented at http://www.cplusplus.com/reference/cstdlib/strtoul/.
char* strupr | ( | char * | string | ) |