日期:2014-05-18  浏览次数:20756 次

有人能告诉我这个7zip的开发套件怎么用么?
菜鸟表示一头雾水,没有中文的说明文档。也没有接口使用范例。
我把这个地址贴出来吧。
http://www.developershome.com/7-zip/sdk.asp
有空的,帮忙看看吧,点那个下载就能下载整个接口程序了,里面有C#的接口


------解决方案--------------------
7z C# demo1

http://download.csdn.net/detail/sanguorewrite/4310435


unzip :

C# code
    byte[] properties = new byte[5];
                if (inStream.Read(properties, 0, 5) != 5)
                    throw (new Exception("input .lzma is too short"));
                Compression.LZMA.Decoder decoder = new Compression.LZMA.Decoder();
                decoder.SetDecoderProperties(properties);
                if (trainStream != null)
                {
                    if (!decoder.Train(trainStream))
                        throw (new Exception("can't train"));
                }
                long outSize = 0;
                for (int i = 0; i < 8; i++)
                {
                    int v = inStream.ReadByte();
                    if (v < 0)
                        throw (new Exception("Can't Read 1"));
                    outSize |= ((long)(byte)v) << (8 * i);
                }
                long compressedSize = inStream.Length - inStream.Position;
                decoder.Code(inStream, outStream, compressedSize, outSize, null);

------解决方案--------------------
探讨
引用:

只调用过7zip.exe用来解压缩的


一样一样,我想问那个接口怎么调用,因为没有中文的文档。