public Replace copyToReplaceObject(){
      Replace rep = new Replace();
      rep.find = find;
      rep.key = key;
      rep.replaceWith = replaceWith;
      rep.ifKey = ifKey;
      rep.ifType = ifType;
      rep.ifValue = ifValue;
      rep.ifKeyState = ifKeyState;

      return rep;
    }
Copies a RegexReplace type object to Replace object.
@return Replace object
ambari-server/src/main/java/org/apache/ambari/server/stack/upgrade/ConfigUpgradeChangeDefinition.java