parrotcode: src/charset/unicode.c | |
Contents | C |
src/charset/unicode.c
This file implements the charset functions for unicode data
static void set_graphemes
replace_count
graphemes in STRING source_string
starting at offset offset
.
Gets the graphemes to be replaced from STRING insert_string
.static STRING *get_graphemes
source_string
starting at offset
.
Gets count
graphemes total.static STRING *get_graphemes_inplace
count
graphemes in place from STRING source_string
starting at offset offset
.
Puts them into STRING dest_string
.static STRING *to_charset
src
to unicode STRING dest
.static STRING *compose
src
.
Attempts to denormalize the STRING into the ICU default,
NFC.static STRING *decompose
static void upcase
src
to all upper-case graphemes,
for those characters which support upper-case versions.static void downcase
static void titlecase
static void upcase_first
source_string
to uppercase,
if the grapheme supports it.
Not implemented.static void downcase_first
source_string
to lower-case,
if the grapheme supports it.
Not implementedstatic void titlecase_first
source_string
to title case,
if the string supports it.
Not implemented.static INTVAL compare
lhs
and rhs
.
Returns -1 if lhs
< rhs
.
Returns 0 if lhs
= rhs
.
Returns 1 if lhs
> rhs
.static INTVAL cs_rindex
search_string
in STRING source_string
,
starting from offset
.
Not implemented.static UINTVAL validate
src
is a valid unicode string,
returns 0 otherwise.static int u_iscclass
static INTVAL is_cclass
static INTVAL find_cclass
static INTVAL find_not_cclass
static STRING *string_from_codepoint
static size_t compute_hash
src
with starting seed value seed
.const CHARSET *Parrot_charset_unicode_init
|