The API for programmatic access to the functionality is defined in the MergeProperties class, which is in the com.progress.common.property Java package. The class definition is as follows:

Syntax

package com.progress.common.property;
public class MergeProperties implements MergePropertiesConst
{   public      MergeProperties();

   public      MergeProperties(int prop_type, String target_filename)
        throws mergeFileException,
         mergePropertyException,
         mergeGroupException,
         mergeException
   
   public void setBackup(boolean backup_type);
   public void setValidate(boolean validate_type);
   public void setRecurse(boolean recurse_type);
   public void setType(int prop_type);
   public void setAction(int action_type);
   public void setTargetFile(String target_filename);
   public void setDeltaFile(String delta_file);
   
   public void mergeprop() 
        throws mergeFileException,
         mergePropertyException,
         mergeGroupException,
         mergeException
   
   public void mergeprop(int action_type, String delta_file) 
        throws mergeFileException,
         mergePropertyException,
         mergeGroupException,
         mergeException
   public void mergeprop(int prop_type, int action_type, String target_file, 
 String delta_file, boolean backup) 
        throws mergeFileException,
         mergePropertyException,
         mergeGroupException,
         mergeException

Constructors

The default MergeProperties() constructor creates an object with no values assigned.

Alternatively, you can use the MergeProperties(prop_type, target_filename) constructor to load a target file on which multiple actions are to be performed. You can then call the mergeprop(action_type, delta_file) method repeatedly, as required, without reloading the target file.

Methods

Call the set...() methods as needed to specify the file type, action, and other input values globally.

To execute operations, call the mergeprop() method. The three variations of this method enable you to use any of the following approaches, as appropriate:
  • Use all global parameter values as declared by the set...() methods.
  • Directly specify the action and the delta file. This method is useful for executing multiple operations on the same target file.
  • Directly specify the file type, action, target file, delta file, and backup option.

File type and action parameters

Valid values for the prop_type and action_type parameters are defined in MergePropertiesConst.

The prop_type parameters are used with the setType() and mergerprop() methods. For more information, see File type. The valid values are:

  • TYPE_UBROKER
  • TYPE_DATABASE
  • TYPE_TOOLS
  • TYPE_PLUGINS
  • TYPE_NONE

The action_type parameters are used with the setAction() and mergerprop() methods. For more information on -action switche options, see mergeprop-utility.html#mergeprop-utility__action_switch. The valid values are:

  • ACTION_UPDATE
  • ACTION_CREATE
  • ACTION_DELETE
  • ACTION_LIST
  • ACTION_LISTALL