You would need to do this when zipping that single file in any case, even if the methods had specific code to avoid matching the zipfile being created, because there could be other files in that folder that matched the spec. For example there could be a . On the other hand, if you were zipping the entire directory, you would in practice generally not place the target zip into that same folder. I guess this is why it has not come up before. The filename filters have had some substantial work done on them, and could benefit from being better documented with examples to illustrate their capabilities and how best to use them. Changing the Fast. Zip ICSharpCode.SharpZipLib. Recently we got hang issue while extracting zipped file using FastZip. CreateZip Method (String, String, Boolean, String, String) FastZip CreateZip Method (String, String, Boolean. String) Namespace: ICSharpCode.SharpZipLib.Zip. ICSharpCode.SharpZipLib.Zip. FastZip.ExtractZip now. Compress Folders with C# and the SharpZipLib. Zip to handle the specific case of not including the target zip could be done, but is not as easy as you might think, for two reasons. One, there are several similar methods which all arrive at a main method takes an output stream.
So a filename would need to be added as a separate parameter. Second, checking the filenames for a match has some wrinkles, around the folder path. You might be implicitly relying on the default working directory for the source. Directory but explicitly naming the output in that same directory, or vice versa, so the code would need to take the working directory into account. Also, you might - and granted, this one is a stretch - refer to one via a drive letter and the other via a UNC path, which happen to actually be the same location. All of that makes the think that the best solution would be to make a sample for the documentation, that illustrated that the filename filters are match filters not specific names, and for us to have reommended best practices on using them. I will add that to the task list. Can I ask, what do you reckon about doco? It can be in (a) the compiled HTML help . We haven't really made much use of the latter so far. Icsharpcode Sharpziplib Zip ExampleWhich of these, if any, did you read? I'd be interested to hear what doco people look at. Icsharpcode
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. Archives
November 2017
Categories |