code: public static String adaptReplacementToMatcher(String replacement) {
  		// Double the backslashes, so they are left as they are after replacement. 
  		String result = replacement.replaceAll("\\\\", "\\\\\\\\");
  		// Add backslashes after dollar signs 
  		result = result.replaceAll("\\$", "\\\\\\$");
  		return result;
  	}
docs: Fixes a bad problem with regular expression replacement strings.
  Replaces \ and $ for escaped versions for regex replacement.
  This was somehow fixed in java 5 (a similar method was added). Since Jawr supports 1.4,
  this method is used instead.
  
  @param replacement
  @return