Merged HEAD-BUG-FIX (5.1/Cloud) to HEAD (5.1/Cloud)

106705: Made findManifest and backup public so they can be reused. UTF-77


git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@106796 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Alan Davis
2015-06-23 07:07:20 +00:00
parent 6e3fb93759
commit 70f7e4cf7c
5 changed files with 105 additions and 37 deletions

View File

@@ -4,7 +4,9 @@ import org.alfresco.service.cmr.module.ModuleDetails;
import de.schlichtherle.truezip.file.TFile;
import java.io.IOException;
import java.util.List;
import java.util.jar.Manifest;
/**
* Performs various actions on a war file or exploded war directory
@@ -37,7 +39,7 @@ public interface WarHelper
* @param war a valid war file or exploded directory from a war
*/
public void checkCompatibleVersion(TFile war, ModuleDetails installingModuleDetails);
/**
* This checks to see if the module that is being installed is compatible with the war.
* If not module edition is specfied then it will just return. However, if an edition is specified and it doesn't match
@@ -65,4 +67,23 @@ public interface WarHelper
* @throws ModuleManagementToolException
*/
List<ModuleDetails> listModules(TFile war);
/**
* Backs up a given file or directory.
*
* @since 5.1
* @param file the file to backup
* @return the absolute path to the backup file.
*/
public String backup(TFile file) throws IOException;
/**
* Finds a war manifest file.
* @since 5.1
* @param war the war
* @return Manifest
* @throws ModuleManagementToolException
*/
public Manifest findManifest(TFile war) throws ModuleManagementToolException;
}