Community
Participate
Working Groups
Created attachment 141475 [details] patch for supporting non-zip archive in DLTK i have asked this question in the newsgroup.but none answers me. and i think DLTK could not support non-zip archive after i look into the source code. sometimes the archive are not zip,maybe it is tar archive or other. i want to know if there is a plan for this,and i have written a patch for this.there is a Archive interface and it can be gained by IDLTKLanguageToolkit/IDLTKLanguageToolkitExtension interface according to the file path.the Archive implementation is just subclass of ZipFile/TarFile/...,and there are entries in Archive ,they are the wrapper classes of ZipEntry/TarEntry/... i am very glad to contribute my code or there are other implementation for this function
Created attachment 141478 [details] patch for supporting non-zip archive in DLTK
Created attachment 141515 [details] patch for supporting non-zip archive in DLTK
ok, I reviewed the fix and it seems really good except for two important comments: 1. The Archive and ArchiveEntry should be refactored to be under org.eclipse.dltk.core as it is part of the API, (it should not be part of the internal package and thus the .api file can be removed) 2. from org.eclipse.dltk.core we should not refer to org.eclipse.ui.ide so we need to move the TarFile classes from the core plugin. if some extension will need it they will probably use extend it in their plugin. contributed by zhaozhongwei.
(In reply to comment #3) > ok, I reviewed the fix and it seems really good except for two important > comments: > 1. The Archive and ArchiveEntry should be refactored to be under > org.eclipse.dltk.core as it is part of the API, (it should not be part of the > internal package and thus the .api file can be removed) > > 2. from org.eclipse.dltk.core we should not refer to org.eclipse.ui.ide so we > need to move the TarFile classes from the core plugin. if some extension will > need it they will probably use extend it in their plugin. > > contributed by zhaozhongwei. > it works for me.and i have run all tests.there are 15 failures,i do not why.it seems with less relation what i have done.for example hightling todo,ruby launching and so on. i have copyed the references to DLTK and i will refactor the internal classses out:)
Created attachment 141840 [details] patch for supporting non-zip archive in DLTK
I strongly believe we should not copy Tar and other archive implementations into DLTK. It would be better to ask platform team to move the appropriate code from org.eclipse.ui.internal.wizards.datatransfer into non-UI plugins and make it public API. Btw, tar support is also available in the org.eclipse.rse.services.clientserver.archiveutils - why copy it into each project?