public class RegexStringTransformerRule extends RegexStringTransformer implements StringTransformerRule
RegexStringTransformer
that implements the StringTransformerRule
interface by adding
the stop-on-match
flag.Modifier and Type | Field and Description |
---|---|
private boolean |
stopOnMatch |
Constructor and Description |
---|
RegexStringTransformerRule()
The non-arg constructor.
|
RegexStringTransformerRule(Pattern pattern,
String replacement,
boolean replaceAll,
boolean stopOnMatch)
The constructor.
|
Modifier and Type | Method and Description |
---|---|
boolean |
isStopOnMatch()
This method determines if this rule will stop further proceeding if it matched.
|
getPattern, getReplacement, isReplaceAll, transform
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
transform
public RegexStringTransformerRule()
public RegexStringTransformerRule(Pattern pattern, String replacement, boolean replaceAll, boolean stopOnMatch)
pattern
- is the pattern used for conversion.replacement
- is the replacement to fill in the string to convert.replaceAll
- - if true
Matcher.replaceAll(String)
will be used, else if
false
Matcher.replaceFirst(String)
.stopOnMatch
- if true
and the pattern
of this rule matches no further rules will
be executed.public boolean isStopOnMatch()
StringTransformerRule
transform
if it did
NOT match. isStopOnMatch
in interface StringTransformerRule
Copyright © 2001–2016 mmm-Team. All rights reserved.