text: public String replaceAll(String replacement) {reset();StringBuffer buffer = new StringBuffer(input.length());while (find()) {appendReplacement(buffer, replacement);}return appendTail(buffer).toString();}