/** * Provides the packager with formatted destructive changes. * * @param metaType * <p>The metadata type (2nd property in each line in package.properties) * @param component * <p>The metadata component type (3rd property in each line in package.properties) * @param objectName * <p>The name of the metadata object that the component is a child of. Not all components are * children. */ private void addDestructiveComponents(String metaType, String component, String objectName) { if (component != null) { // don't change the file separator. This is the expected forward // slash for the destructiveChanges.xml file. component = component.replace('\\', '/'); component = ((objectName.length() > 0) ? objectName + "." : "") + component; } System.out.println("metaType: " + metaType + " component: " + component); packager.addNameContent(metaType, component); }
/** * This debugging method prints out the contents of the destructive changes buffered at the time. */ public void printDestructiveChanges() { packager.printFile(); }
/** * @param dir * <p>Calls the packager, passing the dir path to where the packager should create the * destructiveChanges.xml file. */ public void createDestructiveChangesXmlFile(String dir) { packager.createFile(dir, PropertyReader.getSystemProperty("sf.destruct.file.name"), true); }