read « Zip « Java I/O Q&A





1. Help in creating Zip files from .Net and reading them from Java    stackoverflow.com

I'm trying to create a Zip file from .Net that can be read from Java code. I've used SharpZipLib to create the Zip file but also if the file generated is valid ...

2. reading zipx in java    stackoverflow.com

Any suggestions for a tool/object/utility to read a .zipx file in java? Have already looked at http://stackoverflow.com/questions/1200289/i-need-a-c-library-for-zipx and http://www.winzip.com/comp_info.htm

3. Reading ZIP file gives an 'invalid LOC header' Exception    stackoverflow.com

I have a large zip file, 4.3G. It contains about 100k entries. I am reading it using Java 1.6.0_14 on Linux, Ubuntu 32 bit, and get the following exception.

java.util.zip.ZipException: invalid LOC ...

4. How to read and write a zip file in java?    stackoverflow.com

I am doing a practice to understand read and write zip files in java. I'd read about reading a file and making it to zip file, and i have also tried. ...

5. using java api from clojure, reading zip file    stackoverflow.com

Good day. I trying to rewrite following snippet un clojure, but it all comes ugly, maybe someone will suggest more elegant solution ?

import java.io.FileInputStream;
import java.io.FileNotFoundException;
import java.io.IOException;
import java.util.zip.ZipEntry;
import java.util.zip.ZipInputStream;

public class ZipFileRdrExp {

  ...

6. How to read zipped xml files using java    stackoverflow.com

I am having a zip file with lot of xml files. I am having some data which I have to check with the xml files content and which ever xml file ...

7. How can I read files from ZIp file to memory with Java?    stackoverflow.com

I found example from SUN site (http://java.sun.com/developer/technicalArticles/Programming/compression/), but it returns BufferedOutputStream. But I would like to get ZipEntry file as InputStream and then process next file. Is that possible? My program ...

8. Reading Last *n* lines from GZIPInputStream    stackoverflow.com

I am reading a huge txt file inside zip.

GZIPInputStream fstream = new GZIPInputStream(new FileInputStream(zipfile));
BufferedReader breader = new BufferedReader(new InputStreamReader(fstream));
I need to read last n lines, of the file. Is it possible to ...

9. Reading a zip file    coderanch.com

Hi, I would like to be able to read the contents of a .zip file placed on a server from within an applet. Currently the code below... String text=""; try { JarFile jf=new JarFile("somezip.zip"); Enumeration e=jf.entries(); while(e.hasMoreElements()) { JarEntry je=(JarEntry)e.nextElement(); String name=je.getName(); text+=name+","; } } catch(Exception e){System.out.println("ERROR="+e.getMessage());} Reads the contents of somezip.zip (code and zip file on desktop) and adds it ...





10. Reading a zip file    coderanch.com

11. Is it possible to read and run files directly from a zip file?    coderanch.com

Is it possible to create a zip file and use it like a regular directory structure? I would like to be able to store all my files directly to the zip file and read my files directly from it as well. Or is there some alternative? Basically I need to have a bunch of files together in one central location. But ...

12. ZIP File reading    coderanch.com

Let's say you have a Zip File and you want to read it. You just take the ZipFile and .getInputStream(ZipEntry). Well, let's say the entry you want to read is a zip file, itself. Well, you: ZipInputStream inputStream = new ZipInputStream((zipFileHere).getInputStream(ZipEntry)). And then you read from there. Now, let's say you have a triple nested zip file. That is to say, ...

13. Read Zip File    forums.oracle.com

Hi, I have one zip file and want to read it file by file can you please tell me how can I achieve this??? OR Can anyone please tell me about how can I get absolute path of the file which is resided in the zip file For example, if I have an zip file Test.zip which contains 4 zip files ...

14. Reading files from ZIP in memory    forums.oracle.com

Hi, I need to extract some files from a ZIP archive which will be in memory, accessed with an InputStream (ByteArray). As ZIP files are likely to be large, I'd like to have some sort of "random access" in the way java.util.ZipFile does, allowing me to access any file directly without having to iterate through all the entries. Unfortunately, ZipFiles can ...

15. Problem reading zip from war file    forums.oracle.com

I've figured out that the File object isn't being created when the mywar.war! syntax is in play. It seems that the URL class understands that jar file syntax but the File class doesn't? The URL class only give me the object as a stream, from which I can't figure out to create a ZipFile. How should I go about going from ...

16. Reading raw bytes from .zip file    forums.oracle.com





17. Read serialized java Object from Zip    forums.oracle.com

18. Zip file reading?    forums.oracle.com

19. Zip read exception    forums.oracle.com

20. JVM Setting for performance as reading zip files.....??    forums.oracle.com

I am not too familiar with VM options but I noticed that reading from Zip files is pretty process intensive. I am basically searching through zip files to find a file and then taking that inputstream for processing. I am basically looping through the zip file until i match the filename....pretty crazy. Anyway, it is somewhat slower than I'd like so ...

21. Read Properties of file in ZIP    forums.oracle.com

You're creating a File object to read the zip entry's contents. I think that's wrong -- the zip entry doesn't exist as a file on disk. I believe the way you're supposed to get the contents of a zip entry is to use ZipFile.getInputStream(ZipEntry). You could then pass the returned InputStream to Properties.load().

22. Reading / Unzipping a ZIP file    forums.oracle.com

Hey people I'm trying to write something that will read through a zip file...or perhaps extract its contents first. The problem is that the zip file itself contains many other zip files and extracting them all manually will be way too tedious. I'm not that familiar with Zip files beyond that of simple zipping and unzipping via the mouse. Is there ...

23. Zip file read problem    forums.oracle.com