CUnit Programmers Reference
3.0
|
Utility functions (implementation). More...
#include <stdio.h>
#include <ctype.h>
#include <assert.h>
#include <string.h>
#include "CUnit/Util.h"
Data Structures | |
struct | bindings |
Structure containing mappings of special characters to xml entity codes. More... | |
Functions | |
static int | get_index (const char ch) |
Checks whether a character is a special xml character. More... | |
CU_EXPORT size_t | CU_translate_special_characters (const char *szSrc, char *szDest, size_t maxlen) |
Converts special characters in szSrc to xml entity codes and stores result in szDest. More... | |
CU_EXPORT size_t | CU_translated_strlen (const char *szSrc) |
Calculates the length of a translated string. More... | |
CU_EXPORT int | CU_compare_strings (const char *szSrc, const char *szDest) |
Case-insensitive string comparison. More... | |
CU_EXPORT void | CU_trim (char *szString) |
Trims leading and trailing whitespace from the specified string. More... | |
CU_EXPORT void | CU_trim_left (char *szString) |
Trims leading whitespace from the specified string. More... | |
CU_EXPORT void | CU_trim_right (char *szString) |
Trims trailing whitespace from the specified string. More... | |
CU_EXPORT size_t | CU_number_width (int number) |
Calulates the number of places required to display number in decimal. | |
CU_EXPORT const char * | CU_get_basename (const char *path) |
Given a file path, return a pointer to the last component (the basename). More... | |
Utility functions (implementation).