Package ddf.security.expansion.impl
Class RegexExpansion
java.lang.Object
ddf.security.expansion.impl.AbstractExpansion
ddf.security.expansion.impl.RegexExpansion
- All Implemented Interfaces:
ddf.security.expansion.Expansion
-
Field Summary
Fields inherited from class ddf.security.expansion.impl.AbstractExpansion
CFG_COMMENT_STR, DEFAULT_CONFIG_FILE_NAME, DEFAULT_VALUE_SEPARATOR, expansionTable, LOGGER, RULE_SPLIT_REGEX, rulePattern, SEPARATOR_PREFIX -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected StringdoExpansion(String original, String[] rule) Performs an expansion using regular expressions for both parts of the rule.Methods inherited from class ddf.security.expansion.impl.AbstractExpansion
addExpansionList, addExpansionRule, expand, expand, getExpansionMap, loadConfiguration, removeExpansionRule, setAttributeSeparator, setExpansionFileName, setExpansionMap, setExpansionRules, split, update
-
Constructor Details
-
RegexExpansion
public RegexExpansion()
-
-
Method Details
-
doExpansion
Performs an expansion using regular expressions for both parts of the rule. The first element is a regular expression identifying what to find in the original string, the second element is a regular expression indicating what is to be replaced (may contain substitution groups, etc.)- Specified by:
doExpansionin classAbstractExpansion- Parameters:
original- The original string to be expandedrule- Two values specifying the expression to search for and the expression to replace it with- Returns:
- the (potentially) expanded string as a result of applying the expansion rule
-