English 中文(简体)
利用目标C在MacOS X上编一个档案或一个文件是否容易? [复制]
原标题:Is there an easy way to zip a file or a folder on Mac OS X using Objective C? [duplicate]
This question already has answers here:
Closed 11 years ago.

Possible Duplicate:
Creating a ZIP archive from a Cocoa application

我是否可以使用一些开放源的C图书馆? 或者在没有使用额外图书馆的情况下这样做?

最佳回答

Try Target-Zip。 它使用ZLib和一个名为MentZip的项目,提供ObjC课程,处理ZIP档案(阅读/做成、密码支持等)。

高效和易于使用。

http://code.google.com/p/objective-zip/

It also works for iOS, by the way...

问题回答

对于档案,你可以使用内在校准图书馆。

此外,还用于篡改文件夹(和其他文件夹),但是,你需要扫描目录,储存档案/文件名称和属性,以便形成一个单一种类的斜体(主要是执行UNIXtar/code>)。

有一个名为“zlib”的C图书馆,可以压缩你的档案,Here是这方面的一个很好的指导,你不妨查看

NSData* compressed = [myData zlibDeflate];
NSData* originalData = [compressed zlibInflate];




相关问题
2 mysql instances in MAC

i recently switched to mac. first and foremost i installed xampp. then for django-python-mysql connectivity, i "somehow" ended up installing a seperate MySQL. now the seperate mysql installation is ...

Iterating over string/strlen with umlauted characters

This is a follow-up to my previous question . I succeeded in implementing the algorithm for checking umlauted characters. The next problem comes from iterating over all characters in a string. I do ...

Controlling OSX windows

I m trying to control windows of a foreign OSX applications from my application. I d like to 1. move the windows on the screen 2. resize the windows on the screen 3. change the currently active window ...

Switching J2SE versions on Mac OS (SnowLeopard)

My current JDK on Mac OS (10.6) is set to 1.6 and I d like to switch to 1.5. A listing of /System/Library/Frameworks/JavaVM.framework/Versions/ shows: lrwxr-xr-x 1 root wheel 10 Nov 3 18:34 ...

Scrolling inside Vim in Mac s Terminal

I ve been googling around trying to figure out if it s possible to use my mouse wheel to scroll while inside Vim in Mac s Terminal, with no luck. It seems as if only X11 or iTerm support this. Before ...

export to MP3 from quicktime API

A question for Apple,QT programmers. Would like to know if it s possible to export a Movie object to MP3 using the QuickTime API. Preferably the ConvertMovieToFile function. I ve looked at ...