Re: Util and Substitute Javadocs/Problems

"Daniel F. Savarese" <[email protected]> Thu, 18 Jul 2002 14:33:39 -0400
Newsgroups gmane.comp.jakarta.oro.user
Message-ID <[email protected]>
The source for Substitution.java is:

public interface Substitution {
  public void appendSubstitution(StringBuffer appendBuffer, MatchResult match,
				 int substitutionCount,
				 PatternMatcherInput originalInput, 
				 PatternMatcher matcher, Pattern pattern);
}

The signatures of all of the substitute methods in the Util source are:

  public static String substitute(PatternMatcher matcher, Pattern pattern,
				  Substitution sub, String input, int numSubs);

  public static String substitute(PatternMatcher matcher, Pattern pattern,
				  Substitution sub, String input);

  public static int substitute(StringBuffer result,
			       PatternMatcher matcher, Pattern pattern,
			       Substitution sub, String input,
			       int numSubs);

  public static int substitute(StringBuffer result,
			       PatternMatcher matcher, Pattern pattern,
			       Substitution sub, PatternMatcherInput input,
			       int numSubs);

You're probably just making a typo where you omitted one argument
or switched the order of two arguments.  It's easy to do because
there are so many darned arguments (for the sake of flexibility).

daniel