summaryrefslogtreecommitdiff
path: root/src/core/nodelist.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/nodelist.h')
-rw-r--r--src/core/nodelist.h26
1 files changed, 20 insertions, 6 deletions
diff --git a/src/core/nodelist.h b/src/core/nodelist.h
index 9629d03..e467aa6 100644
--- a/src/core/nodelist.h
+++ b/src/core/nodelist.h
@@ -16,16 +16,30 @@ struct dom_document;
struct dom_node;
struct dom_nodelist;
struct dom_string;
+struct lwc_string_s;
+
+/**
+ * The NodeList type
+ */
+typedef enum {
+ DOM_NODELIST_CHILDREN,
+ DOM_NODELIST_BY_NAME,
+ DOM_NODELIST_BY_NAMESPACE
+} nodelist_type;
/* Create a nodelist */
-dom_exception dom_nodelist_create(struct dom_document *doc,
- struct dom_node_internal *root, struct dom_string *tagname,
- struct dom_string *namespace, struct dom_string *localname,
+dom_exception _dom_nodelist_create(struct dom_document *doc, nodelist_type type,
+ struct dom_node_internal *root, struct lwc_string_s *tagname,
+ struct lwc_string_s *namespace, struct lwc_string_s *localname,
struct dom_nodelist **list);
/* Match a nodelist instance against a set of nodelist creation parameters */
-bool dom_nodelist_match(struct dom_nodelist *list,
- struct dom_node_internal *root, struct dom_string *tagname,
- struct dom_string *namespace, struct dom_string *localname);
+bool _dom_nodelist_match(struct dom_nodelist *list, nodelist_type type,
+ struct dom_node_internal *root, struct lwc_string_s *tagname,
+ struct lwc_string_s *namespace, struct lwc_string_s *localname);
+
+bool _dom_nodelist_equal(struct dom_nodelist *l1, struct dom_nodelist *l2);
+#define dom_nodelist_equal(l1, l2) _dom_nodelist_equal( \
+ (struct dom_nodelist *) (l1), (struct dom_nodelist *) (l2))
#endif