php-internal-docs 8.4.8
Unofficial docs for php/php-src
Loading...
Searching...
No Matches
node.h
Go to the documentation of this file.
1/*
2 * Copyright (C) 2020 Alexander Borisov
3 *
4 * Author: Alexander Borisov <borisov@lexbor.com>
5 */
6
7#ifndef LEXBOR_HTML_NODE_H
8#define LEXBOR_HTML_NODE_H
9
10#ifdef __cplusplus
11extern "C" {
12#endif
13
14#include "lexbor/tag/tag.h"
16
17
18/*
19 * Inline functions
20 */
21lxb_inline bool
23{
24 if (node->ns != LXB_NS_HTML) {
25 return false;
26 }
27
28 switch (node->local_name) {
29 case LXB_TAG_AREA:
30 case LXB_TAG_BASE:
32 case LXB_TAG_BGSOUND:
33 case LXB_TAG_BR:
34 case LXB_TAG_COL:
35 case LXB_TAG_EMBED:
36 case LXB_TAG_FRAME:
37 case LXB_TAG_HR:
38 case LXB_TAG_IMG:
39 case LXB_TAG_INPUT:
40 case LXB_TAG_KEYGEN:
41 case LXB_TAG_LINK:
42 case LXB_TAG_META:
43 case LXB_TAG_PARAM:
44 case LXB_TAG_SOURCE:
45 case LXB_TAG_TRACK:
46 case LXB_TAG_WBR:
47 return true;
48
49 default:
50 return false;
51 }
52
53 return false;
54}
55
56/*
57 * No inline functions for ABI.
58 */
59LXB_API bool
61
62
63#ifdef __cplusplus
64} /* extern "C" */
65#endif
66
67#endif /* LEXBOR_HTML_NODE_H */
#define LXB_API
Definition def.h:48
struct lxb_dom_node lxb_dom_node_t
Definition interface.h:38
lxb_inline bool lxb_html_node_is_void(lxb_dom_node_t *node)
Definition node.h:22
LXB_API bool lxb_html_node_is_void_noi(lxb_dom_node_t *node)
Definition node.c:11
@ LXB_NS_HTML
Definition const.h:26
uintptr_t ns
Definition node.h:48
uintptr_t local_name
Definition node.h:46
@ LXB_TAG_COL
Definition const.h:64
@ LXB_TAG_HR
Definition const.h:124
@ LXB_TAG_PARAM
Definition const.h:170
@ LXB_TAG_WBR
Definition const.h:218
@ LXB_TAG_AREA
Definition const.h:42
@ LXB_TAG_TRACK
Definition const.h:212
@ LXB_TAG_BGSOUND
Definition const.h:51
@ LXB_TAG_INPUT
Definition const.h:130
@ LXB_TAG_BASEFONT
Definition const.h:48
@ LXB_TAG_META
Definition const.h:148
@ LXB_TAG_KEYGEN
Definition const.h:134
@ LXB_TAG_IMG
Definition const.h:129
@ LXB_TAG_BASE
Definition const.h:47
@ LXB_TAG_SOURCE
Definition const.h:190
@ LXB_TAG_LINK
Definition const.h:139
@ LXB_TAG_BR
Definition const.h:56
@ LXB_TAG_EMBED
Definition const.h:79
@ LXB_TAG_FRAME
Definition const.h:112
#define lxb_inline
Definition types.h:21