Data and functions for converting from Unicode normative names to codepoints.
More...
Functions |
| int | binarySearch (const char **, int, int, const char *) |
| | Performs a binary search on an array of strings.
|
| unsigned int | convertCodePointToUTF8 (long, char *) |
| | Converts the bits in a long integer representing a Unicode code point to a series of one or more bytes representing a UTF-8 character.
|
| long | convertNormativeNameToCodePoint (const char *) |
| | Converts a Unicode normative name to a Unicode code point.
|
Detailed Description
Data and functions for converting from Unicode normative names to codepoints.
- Author:
- Justin J. Meza
- Date:
- 2010
Function Documentation
| int binarySearch |
( |
const char ** |
strings, |
|
|
int |
start, |
|
|
int |
end, |
|
|
const char * |
find | |
|
) |
| | |
Performs a binary search on an array of strings.
- Returns:
- The index of the matching entry, if found.
- Return values:
-
| -1 | The entry does not exist in the array. |
- Parameters:
-
| [in] | strings | A pointer to an array of character strings to search through. |
| [in] | start | The start of the range to search through. |
| [in] | end | The end of the range to search through. |
| [in] | find | The entry to search for. |
| unsigned int convertCodePointToUTF8 |
( |
long |
codepoint, |
|
|
char * |
out | |
|
) |
| | |
Converts the bits in a long integer representing a Unicode code point to a series of one or more bytes representing a UTF-8 character.
- Returns:
- The number of characters in the converted multi-byte character.
- Return values:
-
| 0 | An invalid Unicode code point was supplied. |
- Parameters:
-
| [in] | codepoint | The Unicode code point to convert to UTF-8. |
| [out] | out | A pointer to the location to store the resulting UTF-8 bytes. |
| long convertNormativeNameToCodePoint |
( |
const char * |
name |
) |
|
Converts a Unicode normative name to a Unicode code point.
- Returns:
- The Unicode code point corresponding to the given Unicode name.
- Return values:
-
| -1 | An invalid Unicode normative name was supplied. |
- Parameters:
-
| [in] | name | A pointer to a string of characters representing the Unicode normative name desired. |