|
|
@ -470,7 +470,7 @@ class AnalyzeRule(private var book: BaseBook? = null) { |
|
|
|
var tmp: String |
|
|
|
var tmp: String |
|
|
|
val evalMatcher = evalPattern.matcher(rule) |
|
|
|
val evalMatcher = evalPattern.matcher(rule) |
|
|
|
while (evalMatcher.find()) { |
|
|
|
while (evalMatcher.find()) { |
|
|
|
if (mode == Mode.Default) { |
|
|
|
if (mode != Mode.Js) { |
|
|
|
mode = Mode.Regex |
|
|
|
mode = Mode.Regex |
|
|
|
} |
|
|
|
} |
|
|
|
if (evalMatcher.start() > start) { |
|
|
|
if (evalMatcher.start() > start) { |
|
|
@ -560,9 +560,9 @@ class AnalyzeRule(private var book: BaseBook? = null) { |
|
|
|
private fun isRule(ruleStr: String): Boolean { |
|
|
|
private fun isRule(ruleStr: String): Boolean { |
|
|
|
return when { |
|
|
|
return when { |
|
|
|
ruleStr.startsWith("$.") -> true |
|
|
|
ruleStr.startsWith("$.") -> true |
|
|
|
ruleStr.startsWith("@XPath:", true) -> true |
|
|
|
|
|
|
|
ruleStr.startsWith("//") -> true |
|
|
|
|
|
|
|
ruleStr.startsWith("@Json:", true) -> true |
|
|
|
ruleStr.startsWith("@Json:", true) -> true |
|
|
|
|
|
|
|
ruleStr.startsWith("//") -> true |
|
|
|
|
|
|
|
ruleStr.startsWith("@XPath:", true) -> true |
|
|
|
ruleStr.startsWith("@CSS:", true) -> true |
|
|
|
ruleStr.startsWith("@CSS:", true) -> true |
|
|
|
ruleStr.startsWith("@@") -> true |
|
|
|
ruleStr.startsWith("@@") -> true |
|
|
|
else -> false |
|
|
|
else -> false |
|
|
|