com.jalios.jcms.tools.patch
Class WarInfo

java.lang.Object
  extended by com.jalios.jcms.tools.patch.WarInfo

public class WarInfo
extends Object

Helper class to read informations about a JCMS war file or JCMS webapp.


Field Summary
static String REVISION
           
 
Constructor Summary
WarInfo(File warFile)
          Create a new WarInfo from the specified warFile.
 
Method Summary
 void cleanup()
          Cleanup any temporary file from the file system
protected  void finalize()
           
 String getOriginalSignature(String relativeFilePath)
          Retrieve the original signature of the specified file as available in the signature.xml file of this webapp.
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

REVISION

public static final String REVISION
See Also:
Constant Field Values
Constructor Detail

WarInfo

public WarInfo(File warFile)
        throws Exception
Create a new WarInfo from the specified warFile.

If the specified warFile is a file (vs a directory) it will immediately be unzipped in a temporary directory. You can later cleanup all temporary data using cleanup()

Parameters:
warFile - a jcms war File or a path to a JCMS webapp directory
Throws:
Exception - if the specified file could not be unzipped or if it is not a JCMS webapp.
Method Detail

getOriginalSignature

public String getOriginalSignature(String relativeFilePath)
Retrieve the original signature of the specified file as available in the signature.xml file of this webapp.

Parameters:
relativeFilePath - a relative path eg types/Article/doArticleFullDisplay.jsp
Returns:
a signature, or null if could not be found

cleanup

public void cleanup()
Cleanup any temporary file from the file system


finalize

protected void finalize()
                 throws Throwable
Overrides:
finalize in class Object
Throws:
Throwable

toString

public String toString()
Overrides:
toString in class Object


Copyright © 2001-2010 Jalios SA. All Rights Reserved.