如何从C#中未压缩的zip文件中读取文件? [英] how to read files from uncompressed zip in c#?
问题描述
我正在创建PDA应用,我需要上传/下载很多小文件,我的想法是将它们收集在未压缩的zip文件中.
I´m creating a PDA app and I need to upload/download a lot of small files and my idea is to gather them in an uncompressed zip file.
问题是:从zip读取这些文件是个好主意,而不分开它们吗?我该怎么办?还是更好地解压缩文件??由于文件没有经过压缩,因此我可能只是从zip文件中读取文件,所以它的效率与直接从文件系统中读取文件的效率差不多.
The question is: It´s a good idea to read those files from the zip without separating them? How can I do so? Or is it better to unzip them? Since the files are not compressed my simple mind points that maybe reading them from the zip it´s more or less as efficient as reading them directly from the file system...
感谢您的时间!
推荐答案
由于存在两个不同的开放源代码库( SharpZipLib 和 DotNetZip库)来处理编写和处理;从zip文件中提取文件,为什么要自己担心呢?
Since there are two different Open-source libraries (SharpZipLib and DotNetZip Library) to handle writing & extracting files from a zip file, why worry about doing it yourself?
这篇关于如何从C#中未压缩的zip文件中读取文件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!