public abstract class Parser extends Object
| 构造器和说明 |
|---|
Parser() |
| 限定符和类型 | 方法和说明 |
|---|---|
protected void |
extractLiterals(StringBuilder cache,
Deque<Execution> executions) |
protected int |
findEndRightBracket(String sentence,
int offset)
offset当前位置为'(',寻找与之配对的)结束符.返回寻找到)位置。
|
protected int |
findExectionEnd(int startIndex,
String sentence)
搜索执行语句的结尾,也就是%>所在位置。
|
protected int |
findMethodBodyBegin(String sentence,
int offset)
查询{的位置,如果查询不到抛出异常。
|
protected char |
getChar(int offset,
String sentence) |
protected boolean |
isExecutionBegin(int offset,
String sentence) |
abstract int |
parse(String sentence,
int offset,
Deque<Execution> executions,
Template template,
StringBuilder cache,
Invoker next) |
protected int |
skipWhiteSpace(int offset,
String el) |
protected static final Execution[] emptyBody
public abstract int parse(String sentence, int offset, Deque<Execution> executions, Template template, StringBuilder cache, Invoker next)
protected int findMethodBodyBegin(String sentence, int offset)
sentence - offset - protected void extractLiterals(StringBuilder cache, Deque<Execution> executions)
protected char getChar(int offset,
String sentence)
protected int skipWhiteSpace(int offset,
String el)
protected boolean isExecutionBegin(int offset,
String sentence)
protected int findEndRightBracket(String sentence, int offset)
sentence - offset - protected int findExectionEnd(int startIndex,
String sentence)
startIndex - sentence - Copyright © 2020. All rights reserved.