Hi!
I'd go that way:
1. in AbstractFileObject.getParent():
replace
if (this == fs.getRoot()) { ... };
with
FileObject root = fs.getRoot();
if (root instanceof DecoratedFileObject) {
root = ((DecoratedFileObject) root).getDecoratedFileObject();
}
if (this == root) { ... }
But
hi together,
on the first glimpse i don't understand why AbstractFileObject doesn't
override equals() and hashCode(). depending on the concrete
implementation this may result in Object's identity comparison when
comparing two file objects which is in most cases definitely not desired
(see
Hi!
on the first glimpse i don't understand why AbstractFileObject doesn't
override equals() and hashCode().
The current VFS implementation (if you do not use anything else then the
only-working SoftRefFilesCache) ensures that two resolveFile will return
the same object if you ask for the same