规划词法分析/语法分析/关键字

This commit is contained in:
白茶清欢 2022-07-04 18:00:22 +08:00
parent d6de071902
commit ec11100783
3 changed files with 44 additions and 0 deletions

8
lexical.go Normal file
View File

@ -0,0 +1,8 @@
// Package filter ...
//
// Description : JSON 词法分析
//
// Author : go_developer@163.com<白茶清欢>
//
// Date : 2022-07-04 17:52
package filter

8
syntax.go Normal file
View File

@ -0,0 +1,8 @@
// Package filter ...
//
// Description : 语法分析
//
// Author : go_developer@163.com<白茶清欢>
//
// Date : 2022-07-04 17:53
package filter

28
token.go Normal file
View File

@ -0,0 +1,28 @@
// Package filter ...
//
// Description : 关键词定义
//
// Author : go_developer@163.com<白茶清欢>
//
// Date : 2022-07-04 17:53
package filter
const (
// list 类型起始
listLeftToken = "["
// listRight list 类型结束
listRightToken = "]"
// 对象起始
objectLeftToken = "{"
// 对象结束
objectRightToken = "}"
// key 值的起始
keyLeftToken = "\""
// key 值的结束
keyRightToken = "\""
// kvPairSplit kv 的分隔符
kvPairSplitToken = ":"
// 转义符
escapeCharacterToken = "\\"
)