/** * @param key * @param options */ private void addSuffixPluralPattern(String key, HashMap<String, String> options) { String option = options.get(key); if (option != null) { patternMap.put( key, Pattern.compile("\\b(\\w{" + minPrefixLength + ",})(" + option + ")s?\\b")); } }
/** * @param key * @param options */ private void addWordPattern(String key, HashMap<String, String> options) { String option = options.get(key); if (option != null) { patternMap.put(key, Pattern.compile("\\b(" + option + ")\\b")); } }