@Test public void replaceAll() { Replacement replacement = new Replacement("[0-9]", "_"); assertEquals("x___y", replacement.replaceAll("x123y")); }
public String replaceAll(String s) { String result; if (s != null) { result = pattern.matcher(s).replaceAll(replaceWith); } else { result = null; } return result; }
Replacement { public String replaceAll(String s) { String result; if (s != null) { result = pattern.matcher(s).replaceAll(replaceWith); } else { result = null; } return result; } }
Replacement { public String replaceAll(String s) { String result; if (s != null) { result = pattern.matcher(s).replaceAll(replaceWith); } else { result = null; } return result; } Replacement(Pattern pattern, String replaceWith);  Replacement(String pattern, String replaceWith); }
Replacement { public String replaceAll(String s) { String result; if (s != null) { result = pattern.matcher(s).replaceAll(replaceWith); } else { result = null; } return result; } Replacement(Pattern pattern, String replaceWith);  Replacement(String pattern, String replaceWith); static Replacement dotAllNoCase(String pattern, String replaceWith); String replaceAll(String s); }
Replacement { public String replaceAll(String s) { String result; if (s != null) { result = pattern.matcher(s).replaceAll(replaceWith); } else { result = null; } return result; } Replacement(Pattern pattern, String replaceWith);  Replacement(String pattern, String replaceWith); static Replacement dotAllNoCase(String pattern, String replaceWith); String replaceAll(String s);  }