Home > Contents > Index >
Expanded TOC | Accordion TOC | Annotated TOC | Index
Utilities.validateZip
Validates the integrity of a zip file.
Syntax
public static final boolean validateZip(String zip)Parameters
zip
- The pathname of the zip file to validate.
Returns
Returns
true
if zip file is good,false
if not.Example
Validate and unzip the zip file stored at
c:xx.zip
:
String MyZipFile = "c:xx.zip"; if ( Utilities.validateZip(MyZipFile) ) { // zip file is valid; unzip it into the emp directory String UnzipTarget = "c: emp"; boolean UnzipResult; UnzipResult = Utilities.unzipFile(MyZipFile, UnzipTarget); if (!UnzipResult) { // Problem unzip'ing the zip file. } }See Also
Home > Contents > Index > ![]()
FatWire JAVA Reference
Copyright 2005,2006,2007 by FatWire Software
All rights reserved.