summaryrefslogtreecommitdiff
path: root/web/web_dom.h
blob: a86d432d4542fedc0f32674f44504c57bde0e738 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#ifndef WEB_DOM_H
#define WEB_DOM_H

struct elem {
	char *ns, *name, *content;
	int n_attrs, size_attrs;
	char **attr_names, **attr_vals;
};

struct elem *elem_init(char *ns, char *name, int size_attrs);
void elem_free(struct elem *e);
void elem_add_attr(struct elem *e, char *name, char *val);
void elem_add_attr_double(struct elem *e, char *name, double val);
void append_elemv(char *sel, int elemc, struct elem **elemv);

#endif