1.15 support COBOL ext '', 'cbl', 'cob', 'cobol' | COBOL 拓展名支持 无拓展名、cbl、cob、cobol
This commit is contained in:
@@ -30,7 +30,7 @@ public class LineExt {
|
||||
return null;
|
||||
}
|
||||
Map<String, Map<String, List<String>>> treeMap = ConfCache.treeMap(path);
|
||||
if ("cbl".equals(ext)) {
|
||||
if (ext == null || "cbl".equals(ext) || "cob".equals(ext) || "cobol".equals(ext)) {
|
||||
text = cblNotAndOr(text);
|
||||
}
|
||||
String[] words = pattern.split(text);
|
||||
@@ -53,7 +53,7 @@ public class LineExt {
|
||||
}
|
||||
String key = matcher.group(1);
|
||||
// put NOT first
|
||||
text = matcher.replaceAll("$2 ( $1 = '");
|
||||
text = matcher.replaceAll(" $2 ( $1 = '");
|
||||
// add key after AND/OR
|
||||
return AND_OR_PATTERN.matcher(text).replaceAll("$1 " + key + " = '");
|
||||
}
|
||||
|
||||
@@ -48,7 +48,10 @@ class ConfCacheGetUtils {
|
||||
map.put(levelStr + "\b" + confPath, entry.getValue());
|
||||
} else if (confName.endsWith((name + confMidExt))) {
|
||||
map.put(levelStr + "\t" + confPath, entry.getValue());
|
||||
} else if (ext != null) {
|
||||
} else{
|
||||
if (ext == null) {
|
||||
ext = "";
|
||||
}
|
||||
if ((ext + confMidExt).equals(confName)) {
|
||||
map.put(levelStr + "\n" + confPath, entry.getValue());
|
||||
} else if (confName.endsWith((ext + confMidExt))) {
|
||||
|
||||
Reference in New Issue
Block a user