-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathhtml_parser_document_node.h
More file actions
46 lines (35 loc) · 1.06 KB
/
Copy pathhtml_parser_document_node.h
File metadata and controls
46 lines (35 loc) · 1.06 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
#ifndef __DOCUMENT_NODE_INCLUDED__
#define __DOCUMENT_NODE_INCLUDED__
#include "html_parser_attribute_list.h"
#ifdef __cplusplus
extern "C" {
#endif
#include "html_parser_types.h"
#define T Node_T
typedef struct T *T;
extern T Node_new_tag(Tag_E tf, const char *name, Attr_list_T *attrs);
extern T Node_new_content(const char *text);
extern T Node_clone(T n);
extern const char *Node_name(T n);
extern Chunk_E Node_type(T n);
extern Tag_E Node_tag_type(T n);
extern Attr_list_T *Node_attr_list(T n);
extern int Node_has_child(T *n);
extern int Node_has_sibling(T *n);
extern int Node_has_back(T *n);
extern int Node_has_parent(T *n);
extern int Node_is_first_child(T *n);
extern T *Node_parent(T *n);
extern T *Node_back(T *n);
extern T *Node_child(T *n);
extern T *Node_sibling(T *n);
extern T *Node_add_child(T *parent, T *child);
extern T *Node_add_sibling(T *first, T *second);
extern T *Node_add_parent(T *parent, T *child);
extern const char *Node_print(T *n);
extern void Node_free(T *n);
#undef T
#ifdef __cplusplus
}
#endif
#endif /* __DOCUMENT_NODE_INCLUDED__ */