@Test public void setMatchResult() { MatchResultSubstitution subs = new MatchResultSubstitution(); subs.setMatchResult(r1); assertEquals("xxaayy$2zz", subs.substitute("xx$1yy$2zz")); try { subs.setMatchResults(r1, r2); fail(); } catch (IllegalArgumentException e) { assertThat(e, TestUtil.exception("expected 1 MatchResults")); } }
public final String substitute(String input) { if (input == null) { return null; } StringBuilder buf = new StringBuilder(); substitute(buf, input); return buf.toString(); }
Substitution { public final String substitute(String input) { if (input == null) { return null; } StringBuilder buf = new StringBuilder(); substitute(buf, input); return buf.toString(); } }
Substitution { public final String substitute(String input) { if (input == null) { return null; } StringBuilder buf = new StringBuilder(); substitute(buf, input); return buf.toString(); } Substitution();  Substitution(String replacementPrefixes); }
Substitution { public final String substitute(String input) { if (input == null) { return null; } StringBuilder buf = new StringBuilder(); substitute(buf, input); return buf.toString(); } Substitution();  Substitution(String replacementPrefixes); final String substitute(String input); final void substitute(StringBuilder buf, String input); }
Substitution { public final String substitute(String input) { if (input == null) { return null; } StringBuilder buf = new StringBuilder(); substitute(buf, input); return buf.toString(); } Substitution();  Substitution(String replacementPrefixes); final String substitute(String input); final void substitute(StringBuilder buf, String input);  }