commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Bernd Eckenfels" <e...@zusammenkunft.net>
Subject Re: [VFS] canCreateFileSystem("directory.jar/")
Date Fri, 16 Aug 2013 23:14:23 GMT
Hello,

I have filed this Bug report and also provided a fixed version (on Github):

https://issues.apache.org/jira/browse/VFS-490
https://github.com/ecki/seeburger-vfs2/blob/master/vfs2provider-jdbctable/src/main/java/com/seeburger/vfs2/util/VFSClassLoader.java#L152

Greetings
Bernd

Am 16.08.2013, 23:31 Uhr, schrieb Bernd Eckenfels <ecki@zusammenkunft.net>:

> I want to use the VFSClassLoader on JAR files and Directories (to  
> provide resources). My problem is, that some directories are exploded  
> archives and have a name with a .jar extension.
>
> The addFileObjects() of the VFSClassLoader uses canCreateFileSystem() to  
> detect, if for a given file is a overlay which can read its content.  
> However this method uses FileTypeMap#getScheme(file) which does look at  
> the mimetype and extension of the file name, but not if it is actually a  
> file.
>
> I think VFSClassLoader can check for hasContent() but I think that the  
> solution should actually somewhere in canCreateFileSystem() as I could  
> image there is a overlay filesystem which maps a directory into a  
> filesystem (think .git).
>
> Any ideas? Should I provide a patch for VFSClassLoader only to start  
> with?

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org


Mime
View raw message