| java.lang.Object org.apache.oro.text.regex.StringSubstitution
All known Subclasses: org.apache.oro.text.regex.Perl5Substitution,
Constructor Summary | |
public | StringSubstitution() Default constructor initializing substitution to a zero length
String. | public | StringSubstitution(String substitution) Creates a StringSubstitution representing the given string. |
_subLength | int _subLength(Code) | | |
StringSubstitution | public StringSubstitution()(Code) | | Default constructor initializing substitution to a zero length
String.
|
StringSubstitution | public StringSubstitution(String substitution)(Code) | | Creates a StringSubstitution representing the given string.
Parameters: substitution - The string to use as a substitution. |
appendSubstitution | public void appendSubstitution(StringBuffer appendBuffer, MatchResult match, int substitutionCount, PatternMatcherInput originalInput, PatternMatcher matcher, Pattern pattern)(Code) | | Appends the substitution to a buffer containing the original input
with substitutions applied for the pattern matches found so far.
See
Substitution.appendSubstitution Substitution.appendSubstition() for more details regarding the expected behavior of this method.
Parameters: appendBuffer - The buffer containing the new string resultingfrom performing substitutions on the original input. Parameters: match - The current match causing a substitution to be made. Parameters: substitutionCount - The number of substitutions that have beenperformed so far by Util.substitute. Parameters: originalInput - The original input upon which the substitutions arebeing performed. This is a read-only parameter and is not modified. Parameters: matcher - The PatternMatcher used to find the current match. Parameters: pattern - The Pattern used to find the current match. |
getSubstitution | public String getSubstitution()(Code) | | Returns the string substitution represented by this object.
The string substitution represented by this object. |
setSubstitution | public void setSubstitution(String substitution)(Code) | | Sets the substitution represented by this StringSubstitution. You
should use this method in order to avoid repeatedly allocating new
StringSubstitutions. It is recommended that you allocate a single
StringSubstitution and reuse it by using this method when appropriate.
Parameters: substitution - The string to use as a substitution. |
|
|