at.spardat.xma.xdelta
Class JarPatcher
java.lang.Object
   at.spardat.xma.xdelta.JarPatcher
at.spardat.xma.xdelta.JarPatcher
- public class JarPatcher 
- extends Object
This class applys a zip file containing deltas created with JarDelta using
 GDiffPatcher on the files contained in the jar file.
 The result of this operation is not binary equal to the original target zip file.
 Timestamps of files and directories are not reconstructed. But the contents of all
 files in the reconstructed target zip file are complely equal to their originals.
- Author:
- s2877
 
 
| Methods inherited from class java.lang.Object | 
| clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait | 
 
JarPatcher
public JarPatcher()
applyDelta
public void applyDelta(ZipFile source,
                       ZipFile patch,
                       ZipOutputStream output)
                throws IOException
- Applies the differences in patch to source to create the target file. All binary difference files
 are applied to their corresponding file in source using GDiffPatcher.
 All other files listed inMETA-INF/file.listare copied from patch to output.
 
- 
- Parameters:
- source- the original zip file, where the patches have to be applied
- patch- a zip file created by- JarDelta.computeDelta(ZipFile, ZipFile, ZipOutputStream)containing the patches to apply
- output- the patched zip file to create
- Throws:
- IOException- if an error occures reading or writing any entry in a zip file
 
main
public static void main(String[] args)
                 throws IOException
- Main method to make applyDelta(ZipFile, ZipFile, ZipOutputStream)available at
 the command line.
 usage JarPatcher source patch output
 
- 
- Throws:
- IOException
 
Copyright © 2003-2008. All Rights Reserved.