testmethod
This commit is contained in:
parent
c16f583ce1
commit
db5baee889
@ -139,7 +139,8 @@ public class Section {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
public void dismissByRegEx(String type, String pattern, boolean patternCaseInsensitive, int group, int ruleNumber, String reason) {
|
|
||||||
|
public void dismissByRegEx(String type, String pattern, boolean patternCaseInsensitive, int group) {
|
||||||
|
|
||||||
Pattern compiledPattern = Patterns.getCompiledPattern(pattern, patternCaseInsensitive);
|
Pattern compiledPattern = Patterns.getCompiledPattern(pattern, patternCaseInsensitive);
|
||||||
|
|
||||||
@ -155,9 +156,7 @@ public class Section {
|
|||||||
while (matcher.find()) {
|
while (matcher.find()) {
|
||||||
String match = matcher.group(group);
|
String match = matcher.group(group);
|
||||||
if (StringUtils.isNotBlank(match)) {
|
if (StringUtils.isNotBlank(match)) {
|
||||||
entity.setRedaction(false);
|
expanded.addAll(findEntities(entity.getWord() + match, type, false, entity.isRedaction(), 0, null, null));
|
||||||
entity.setMatchedRule(ruleNumber);
|
|
||||||
entity.setRedactionReason(reason);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user