aboutsummaryrefslogtreecommitdiffstats
path: root/serd/serd.h
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2011-01-25 20:14:51 +0000
committerDavid Robillard <d@drobilla.net>2011-01-25 20:14:51 +0000
commit839dd67ed1716c2548e270160033b01d54dab03a (patch)
tree8e1d2296611b785623259f63466aa1dcc6f59a86 /serd/serd.h
parentee5b1d33acf8cf499bc0f3e3a02ad6262b4a3d05 (diff)
downloadserd-839dd67ed1716c2548e270160033b01d54dab03a.tar.gz
serd-839dd67ed1716c2548e270160033b01d54dab03a.tar.bz2
serd-839dd67ed1716c2548e270160033b01d54dab03a.zip
Move node functions into API.
git-svn-id: http://svn.drobilla.net/serd/trunk@75 490d8e77-9747-427b-9fa3-0b8f29cee8a0
Diffstat (limited to 'serd/serd.h')
-rw-r--r--serd/serd.h24
1 files changed, 24 insertions, 0 deletions
diff --git a/serd/serd.h b/serd/serd.h
index b63f442f..182f263a 100644
--- a/serd/serd.h
+++ b/serd/serd.h
@@ -178,6 +178,30 @@ typedef struct {
static const SerdNode SERD_NODE_NULL = { 0, 0, 0, 0 };
+/** Make a deep copy of @a node.
+ * @return a node that the caller must free with @ref serd_node_free.
+ */
+SERD_API
+SerdNode
+serd_node_copy(const SerdNode* node);
+
+/** Create a new node by serialising @a uri into a new string.
+ * @param uri The URI to parse and serialise.
+ * @param out (Output) set to the parsing of the new URI (i.e. points only to
+ * memory owned by the new returned node).
+ */
+SERD_API
+SerdNode
+serd_node_new_uri(const SerdURI* uri, SerdURI* out);
+
+/** Free any data owned by @a node.
+ * Note that if @a node is itself dynamically allocated (which is not the case
+ * for nodes created internally by serd), it will not be freed.
+ */
+SERD_API
+void
+serd_node_free(SerdNode* node);
+
/** @} */
/** @name SerdEnv