code: public String replaceAllInWith(String regEx, String value, String replace) {
          String result = null;
          if (value != null) {
              if (replace == null) {
                  // empty cell in table is sent as null
                  replace = "";
              }
              result = getMatcher(regEx, value).replaceAll(replace);
          }
          return result;
      }
docs: Replaces all occurrences of the regular expression in the value with the replacement value.
  @param regEx regular expression to match.
  @param value value to replace in.
  @param replace replacement pattern.
  @return result.