summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorJohn Mark Bell <jmb@netsurf-browser.org>2007-07-14 14:30:41 +0000
committerJohn Mark Bell <jmb@netsurf-browser.org>2007-07-14 14:30:41 +0000
commit328df08330d95047d6235d8322507866f1c3cb11 (patch)
tree3495117daa6e1c770fd64be073987d44ca96e9d6 /include
parent15c17e42f48d21a9f821c02fb1f8c4e4959e2432 (diff)
downloadlibdom-328df08330d95047d6235d8322507866f1c3cb11.tar.gz
libdom-328df08330d95047d6235d8322507866f1c3cb11.tar.bz2
Add extra dom_string constructor that permits strings to be manufactured in the situation where there exists no document.
This should only be used in order to create dom_strings for use by DocumentType and Document constructors -- in any other situation, a suitable document already exists. svn path=/trunk/dom/; revision=3411
Diffstat (limited to 'include')
-rw-r--r--include/dom/core/string.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/include/dom/core/string.h b/include/dom/core/string.h
index 759f042..c9ffd97 100644
--- a/include/dom/core/string.h
+++ b/include/dom/core/string.h
@@ -11,6 +11,7 @@
#include <inttypes.h>
#include <stddef.h>
+#include <dom/functypes.h>
#include <dom/core/exceptions.h>
struct dom_document;
@@ -30,6 +31,10 @@ dom_exception dom_string_create_from_ptr(struct dom_document *doc,
/* Create a DOM string from a constant string of characters */
dom_exception dom_string_create_from_const_ptr(struct dom_document *doc,
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,
+ const uint8_t *ptr, size_t len, struct dom_string **str);
/* Get a pointer to the string of characters within a DOM string */
dom_exception dom_string_get_data(struct dom_string *str,