Unzip to InputStream - Android File Input Output

Android examples for File Input Output:Zip File

Description

Unzip to InputStream

Demo Code


//package com.java2s;

public class Main {

    public static java.io.InputStream UpZip(String zipFileString,
            String fileString) throws Exception {
        android.util.Log.v("XZip", "UpZip(String, String)");
        java.util.zip.ZipFile zipFile = new java.util.zip.ZipFile(
                zipFileString);/* w  w w  .j a v a2s .  c  o  m*/
        java.util.zip.ZipEntry zipEntry = zipFile.getEntry(fileString);

        return zipFile.getInputStream(zipEntry);

    }
}

Related Tutorials