解压函数:
/**
* 解压assert中的文件到指定目录
* @param is文件输入流
* @param dir目标路径(路径已存在)
* @throws IOException
*/
private void unzip (InputStream is, String dir) throws IOException
{
File dest = new File(dir);
if ( !dest.isDirectory())
throw new IOException("Invalid Unzip destination " + dest);
if(null == is){
throw new IOException("InputStream is null");
}
ZipInputStream zip = new ZipInputStream(is);
ZipEntry ze;
while ( (ze = zip.getNextEntry()) != null ) {
final String path = dest.getAbsolutePath()
+ File.separator + ze.getName();
// Create any entry folders
String zeName = ze.getName();
char cTail = zeName.charAt(zeName.length() - 1);
if ( cTail ==