commons-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ralph Goers (JIRA)" <>
Subject [jira] Commented: (VFS-279) ClassCastException in LocalFileSystem when using OnCall caching
Date Mon, 09 Nov 2009 08:00:32 GMT


Ralph Goers commented on VFS-279:

Thanks.  What I'm concerned about is that doReplicateFile takes a FileObject. From what I
can tell, it is possible to call this method and pass in a ZipFileObject or HttpFileObject,
neither of which extend LocalFileObject and aren't DecoratedFileObjects? If so, should it
work or is throwing a ClassCastException the correct behavior?

I assume you ran into this and I assume it must have been with a DecoratedFileObject? I'm
interested in that use case as I wonder why it is desired to replicate the underlying FileObject
and not the DecoratedFileObject.

> ClassCastException in LocalFileSystem when using OnCall caching
> ---------------------------------------------------------------
>                 Key: VFS-279
>                 URL:
>             Project: Commons VFS
>          Issue Type: Bug
>    Affects Versions: 1.0, 1.1, 2.0
>            Reporter: Didier Earith
>             Fix For: 1.0, 1.1, 2.0
>         Attachments:
> When using OnCall caching in the file system, there is a ClassCastException in the LocalFileSystem#doReplicateFile
> To fix the issue, I replaced :
>         final LocalFile localFile = (LocalFile) fileObject;
> by 
>         final LocalFile localFile = (LocalFile) FileObjectUtils.getAbstractFileObject(fileObject);

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message