public String replace(CharSequence text){
  TextBuffer tb=wrap(new StringBuilder(text.length()));
  replace(pattern.matcher(text),substitution,tb);
  return tb.toString();
}

public String replace ( CharSequence text ) { TextBuffer tb = wrap ( new StringBuilder ( text . length ( ) ) ) ; replace ( pattern . matcher ( text ) , substitution , tb ) ; return tb . toString ( ) ; }
takes all instances in text of the pattern this was constructed with , and replaces them with substitution .
