ocean.text.Ascii

Placeholder for a selection of ASCII utilities. These generally will not work with utf8, and cannot be easily extended to utf16 or utf32

Members

Functions

compare
int compare(cstring s1, cstring s2)

Compare two char[] with case. Returns 0 if equal

icompare
int icompare(cstring s1, cstring s2)

Compare two char[] ignoring case. Returns 0 if equal

main
void main()
Undocumented in source. Be warned that the author may not have intended to support it.
toLower
mstring toLower(mstring src)

Convert to lowercase. Performs in-place conversion.

toLower
mstring toLower(cstring src, mstring dst)

Convert to lowercase. Result is written to resized buffer.

toUpper
mstring toUpper(mstring src)

Convert to uppercase. Performs in-place conversion.

toUpper
mstring toUpper(cstring src, mstring dst)

Convert to uppercase. Result is written to resized buffer.

Static functions

isearch
int isearch(cstring src, cstring pattern)

Return the index position of a text pattern within src, or src.length upon failure.

Meta

License

Tango Dual License: 3-Clause BSD License / Academic Free License v3.0. See LICENSE_TANGO.txt for details.

Version

Dec 2006: Initial release

Authors

Kris