Skip to main content

Module rule

Module rule 

Source
Expand description

规则 AST:抽取语义(Via/Extract)、叶子规则与组合子(Rule)。

Rule 既是配置、也是供求值器(crate::eval)遍历的语法树(见 design D1/D6)。

Structs§

LeafRule
叶子规则:在当前上下文做一次抽取。

Enums§

Extract
取值方式(枚举字符串 或 { "attr": "..." })。
ExtractOp
文本/HTML 取值算子。
Rule
一条规则:叶子,或组合子。组合子按其唯一键判别(见 design D1)。
UrlOrRule
URL 字段:可为字符串模板,或一条规则。
Via
抽取后端(决定 select 的语义)。