private void replace(String tag,String value){
  String modified=content.replace(tag_(tag),val_(value));
  Preconditions.checkState(!modified.equals(content),"No effect: %s to %s",tag,value);
  this.content=modified;
}

private void replace ( String tag , String value ) { String modified = content . replace ( tag_ ( tag ) , val_ ( value ) ) ; Preconditions . checkState ( ! modified . equals ( content ) , "No effect: %s to %s" , tag , value ) ; this . content = modified ; }
replaces the given tag with the given value .
