public class ZipSalvager extends Object
Constructor and Description |
---|
ZipSalvager() |
Modifier and Type | Method and Description |
---|---|
static void |
salvageCopy(File brokenZip,
File salvagedZip) |
static void |
salvageCopy(InputStream brokenZip,
File salvagedZip,
boolean allowStoredEntries)
This streams the broken zip and rebuilds a new zip that
is at least a valid zip file.
|
public static void salvageCopy(InputStream brokenZip, File salvagedZip, boolean allowStoredEntries) throws IOException
This does nothing fancy to fix the underlying broken zip.
This will close the inputstream
brokenZip
- salvagedZip
- IOException
public static void salvageCopy(File brokenZip, File salvagedZip) throws IOException
IOException
Copyright © 2007–2023 The Apache Software Foundation. All rights reserved.