-
Reading from a ZipInputStream
I can write the content of a ZipInputStream to file called 'out'.
However I want to actually get the content of the zip file and assign the text to variables.
The code below reads and writes it to a file, but I want to assign it to a variable instead.
Can you help.
//The code below writes to a file called '_OUT'
String outFilename = "_OUT";
OutputStream out = new FileOutputStream(outFilename);
byte[] xbyte = new byte[1024];
int len;
while ((len = myZipInputStream.read(xbyte)) > 0) {
out.write(xbyte, 0, len);
}
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
Forum Rules
|
Top DevX Stories
Easy Web Services with SQL Server 2005 HTTP Endpoints
JavaOne 2005: Java Platform Roadmap Focuses on Ease of Development, Sun Focuses on the "Free" in F.O.S.S.
Wed Yourself to UML with the Power of Associations
Microsoft to Add AJAX Capabilities to ASP.NET
IBM's Cloudscape Versus MySQL
|
Bookmarks