protected String trimBenefitAmountLabel(String label) {
if (label != null && !CollectionUtils.isEmpty(this.trimBenefitAmountLabelPatternList)) {
for (String patternStr : this.trimBenefitAmountLabelPatternList) {
try {
Pattern pattern = Pattern.compile(patternStr, Pattern.CASE_INSENSITIVE);
Matcher matcher = pattern.matcher(label);
if (matcher.find()) {
return matcher.group(1).trim();
}
} catch (IllegalArgumentException e) {
continue;
}
}
}
return StringUtils.trim(label);
}