diff options
author | John Mark Bell <jmb@netsurf-browser.org> | 2009-03-03 18:08:01 +0000 |
---|---|---|
committer | John Mark Bell <jmb@netsurf-browser.org> | 2009-03-03 18:08:01 +0000 |
commit | 3479055b4a609032a1775871cc685fd7dd33ab32 (patch) | |
tree | 9dc767860ebea940f1d936d14d69073b4e289c92 /include/dom/core/string.h | |
parent | 3680a278da394bace852e3eff4701789d6f29bf6 (diff) | |
download | libdom-3479055b4a609032a1775871cc685fd7dd33ab32.tar.gz libdom-3479055b4a609032a1775871cc685fd7dd33ab32.tar.bz2 |
Rationalise dom_string (some consideration is required as to what happens wrt interning -- lwc_strings should probably be used)
Purge charset handling -- a) documents are always converted to utf-8 b) use parserutils for utf-8 handling
Fix Hubbub binding to compile.
svn path=/trunk/dom/; revision=6682
Diffstat (limited to 'include/dom/core/string.h')
-rw-r--r-- | include/dom/core/string.h | 19 |
1 files changed, 1 insertions, 18 deletions
diff --git a/include/dom/core/string.h b/include/dom/core/string.h index e3dfa30..8da9dd7 100644 --- a/include/dom/core/string.h +++ b/include/dom/core/string.h @@ -14,33 +14,16 @@ #include <dom/functypes.h> #include <dom/core/exceptions.h> -struct dom_document; struct dom_string; -typedef enum { - DOM_STRING_UTF8, - DOM_STRING_UTF16 -} dom_string_charset; - /* Claim a reference on a DOM string */ void dom_string_ref(struct dom_string *str); /* Release a reference on a DOM string */ void dom_string_unref(struct dom_string *str); -/* Create a DOM string from an offset into the document buffer */ -dom_exception dom_string_create_from_off(struct dom_document *doc, - uint32_t off, size_t len, struct dom_string **str); /* Create a DOM string from a string of characters */ -dom_exception dom_string_create_from_ptr(struct dom_document *doc, - const uint8_t *ptr, size_t len, struct dom_string **str); -/* Create a DOM string from a constant string of characters */ -dom_exception dom_string_create_from_const_ptr(struct dom_document *doc, +dom_exception dom_string_create(dom_alloc alloc, void *pw, const uint8_t *ptr, size_t len, struct dom_string **str); -/* Create a DOM string from a string of characters that does not belong - * to a document */ -dom_exception dom_string_create_from_ptr_no_doc(dom_alloc alloc, void *pw, - dom_string_charset charset, const uint8_t *ptr, size_t len, - struct dom_string **str); /* Case sensitively compare two DOM strings */ int dom_string_cmp(struct dom_string *s1, struct dom_string *s2); |