code: public String process(final String in) {
  		String retVal = in;
  		String old;
  		do {
  			old = retVal;
  			retVal = from.matcher(retVal).replaceAll(to);
  		} while (repeatUntilUnchanged && !old.equals(retVal));
  
  		return retVal;
  	}
docs: Processes input, replaces all as expected and returns the result.
  
  @param in input string
  @return replaced string