php-internal-docs 8.4.8
Unofficial docs for php/php-src
Loading...
Searching...
No Matches
parser.h
Go to the documentation of this file.
1/*
2 * Copyright (C) 2020-2022 Alexander Borisov
3 *
4 * Author: Alexander Borisov <borisov@lexbor.com>
5 */
6
7#ifndef LEXBOR_CSS_SYNTAX_PARSER_H
8#define LEXBOR_CSS_SYNTAX_PARSER_H
9
10#ifdef __cplusplus
11extern "C" {
12#endif
13
14
15#include "lexbor/css/base.h"
16#include "lexbor/css/at_rule.h"
17
18
21
24
27
28LXB_API void
30
33 const lxb_css_syntax_token_t *token,
34 lxb_css_parser_state_f state_back,
35 const lxb_css_syntax_cb_list_rules_t *list_rules,
36 void *ctx, bool top_level,
38
41 const lxb_css_syntax_token_t *token,
42 lxb_css_parser_state_f state_back,
43 const lxb_css_syntax_cb_at_rule_t *at_rule,
44 void *ctx, lxb_css_syntax_token_type_t stop);
45
48 const lxb_css_syntax_token_t *token,
49 lxb_css_parser_state_f state_back,
51 void *ctx, lxb_css_syntax_token_type_t stop);
52
55 const lxb_css_syntax_token_t *token,
56 lxb_css_parser_state_f state_back,
57 const lxb_css_syntax_cb_declarations_t *declarations,
58 void *ctx, lxb_css_syntax_token_type_t stop);
59
62 const lxb_css_syntax_token_t *token,
63 lxb_css_parser_state_f state_back,
65 void *ctx, lxb_css_syntax_token_type_t stop);
66
69 const lxb_css_syntax_token_t *token,
70 lxb_css_parser_state_f state_back,
72 void *ctx);
73
76 const lxb_css_syntax_token_t *token,
77 lxb_css_parser_state_f state_back,
78 const lxb_css_syntax_cb_block_t *block,
79 void *ctx);
80
83 lxb_css_parser_state_f state_back,
84 const lxb_css_syntax_cb_pipe_t *pipe,
85 void *ctx, lxb_css_syntax_token_type_t stop);
86
89 const lxb_char_t **data, const lxb_char_t **end,
90 void *ctx);
91
94 const lxb_css_syntax_token_t *token,
96
99 const lxb_css_syntax_token_t *token,
101
102
103#ifdef __cplusplus
104} /* extern "C" */
105#endif
106
107#endif /* LEXBOR_CSS_SYNTAX_PARSER_H */
struct lxb_css_syntax_token lxb_css_syntax_token_t
Definition base.h:46
bool(* lxb_css_parser_state_f)(lxb_css_parser_t *parser, const lxb_css_syntax_token_t *token, void *ctx)
Definition base.h:49
struct lxb_css_syntax_tokenizer lxb_css_syntax_tokenizer_t
Definition base.h:45
struct lxb_css_parser lxb_css_parser_t
Definition base.h:41
LXB_API lxb_status_t lxb_css_syntax_parser_run(lxb_css_parser_t *parser)
Definition parser.c:116
LXB_API const lxb_css_syntax_token_t * lxb_css_syntax_parser_end(lxb_css_parser_t *parser, const lxb_css_syntax_token_t *token, lxb_css_syntax_rule_t *rule)
Definition parser.c:1749
LXB_API const lxb_css_syntax_token_t * lxb_css_syntax_parser_token_wo_ws(lxb_css_parser_t *parser)
Definition parser.c:156
LXB_API lxb_css_syntax_rule_t * lxb_css_syntax_parser_at_rule_push(lxb_css_parser_t *parser, const lxb_css_syntax_token_t *token, lxb_css_parser_state_f state_back, const lxb_css_syntax_cb_at_rule_t *at_rule, void *ctx, lxb_css_syntax_token_type_t stop)
Definition parser.c:263
LXB_API const lxb_css_syntax_token_t * lxb_css_syntax_parser_token(lxb_css_parser_t *parser)
Definition parser.c:142
LXB_API lxb_css_syntax_rule_t * lxb_css_syntax_parser_components_push(lxb_css_parser_t *parser, const lxb_css_syntax_token_t *token, lxb_css_parser_state_f state_back, const lxb_css_syntax_cb_components_t *comp, void *ctx, lxb_css_syntax_token_type_t stop)
Definition parser.c:390
LXB_API lxb_css_syntax_rule_t * lxb_css_syntax_parser_declarations_push(lxb_css_parser_t *parser, const lxb_css_syntax_token_t *token, lxb_css_parser_state_f state_back, const lxb_css_syntax_cb_declarations_t *declarations, void *ctx, lxb_css_syntax_token_type_t stop)
Definition parser.c:349
LXB_API lxb_css_syntax_rule_t * lxb_css_syntax_parser_qualified_push(lxb_css_parser_t *parser, const lxb_css_syntax_token_t *token, lxb_css_parser_state_f state_back, const lxb_css_syntax_cb_qualified_rule_t *qualified, void *ctx, lxb_css_syntax_token_type_t stop)
Definition parser.c:308
LXB_API lxb_css_syntax_rule_t * lxb_css_syntax_parser_list_rules_push(lxb_css_parser_t *parser, const lxb_css_syntax_token_t *token, lxb_css_parser_state_f state_back, const lxb_css_syntax_cb_list_rules_t *list_rules, void *ctx, bool top_level, lxb_css_syntax_token_type_t stop)
Definition parser.c:220
LXB_API const lxb_css_syntax_token_t * lxb_css_syntax_parser_start_block(lxb_css_parser_t *parser, const lxb_css_syntax_token_t *token, lxb_css_syntax_rule_t *rule)
Definition parser.c:1728
LXB_API lxb_css_syntax_rule_t * lxb_css_syntax_parser_pipe_push(lxb_css_parser_t *parser, lxb_css_parser_state_f state_back, const lxb_css_syntax_cb_pipe_t *pipe, void *ctx, lxb_css_syntax_token_type_t stop)
Definition parser.c:550
LXB_API lxb_status_t lxb_css_syntax_parser_tkz_cb(lxb_css_syntax_tokenizer_t *tkz, const lxb_char_t **data, const lxb_char_t **end, void *ctx)
Definition parser.c:179
LXB_API void lxb_css_syntax_parser_consume(lxb_css_parser_t *parser)
Definition parser.c:171
LXB_API lxb_css_syntax_rule_t * lxb_css_syntax_parser_block_push(lxb_css_parser_t *parser, const lxb_css_syntax_token_t *token, lxb_css_parser_state_f state_back, const lxb_css_syntax_cb_block_t *block, void *ctx)
Definition parser.c:479
LXB_API lxb_css_syntax_rule_t * lxb_css_syntax_parser_function_push(lxb_css_parser_t *parser, const lxb_css_syntax_token_t *token, lxb_css_parser_state_f state_back, const lxb_css_syntax_cb_function_t *func, void *ctx)
Definition parser.c:427
lxb_css_syntax_token_type_t
Definition token.h:68
#define LXB_API
Definition def.h:48
unsigned const char * end
Definition php_ffi.h:51
zend_constant * data
lxb_css_syntax_cb_base_t lxb_css_syntax_cb_components_t
Definition syntax.h:78
lxb_css_syntax_cb_base_t lxb_css_syntax_cb_block_t
Definition syntax.h:76
lxb_css_syntax_cb_base_t lxb_css_syntax_cb_at_rule_t
Definition syntax.h:79
lxb_css_syntax_cb_base_t lxb_css_syntax_cb_pipe_t
Definition syntax.h:75
struct lxb_css_syntax_rule lxb_css_syntax_rule_t
Definition syntax.h:17
lxb_css_syntax_cb_base_t lxb_css_syntax_cb_qualified_rule_t
Definition syntax.h:80
lxb_css_syntax_cb_base_t lxb_css_syntax_cb_function_t
Definition syntax.h:77
unsigned int lxb_status_t
Definition types.h:28
unsigned char lxb_char_t
Definition types.h:27
execute_data func