Hi,
I made this VFS bridge for FtpServer and lately I have been playing with a
virtual fileystem for XML files.
Apache VFS has the notion of a file_or_folder type in case the specific node
can both have content and children (which is the case for some content
management systems and also for XML).
(Mounting the FtpServer on a single xml file is maybe not very useful, but I'm
looking into supporting layered files, so with ftp you could descend into zip
files and xml files.)
The connection to the FtpServer doesn't work unfortunately because the
DirectoryLister doesn't want to list the children if the node is of type file;
this 'ambiguous' type I'm using will return true for both isFile and isDocument.
My problem is easily fixed by changing the code in DirectoryLister from
checking for a file to checking for a directory; since the goal is to list
children I think it is more correct.
DirectoryLister line 98:
if (virtualFile.isFile()) {
should be
if (!virtualFile.isDirectory()) {
It passes all JUnit tests and should not have any impact on your normal
behaviour. Do you think you could implement this little change for a next
release?
Thanks,
Frank