> -----Original Message----- > From: Gary Gregory > Sent: Wednesday, July 29, 2020 8:34 AM > > On Wed, Jul 29, 2020 at 12:32 AM Xeno Amess <xenoam...@gmail.com> wrote: > > > https://github.com/apache/commons-vfs/pull/89 > > It adds a function for converting FileObject in vfs to File in java. > > > > I think this one is a no go. See comments in the PR.
While (I think) I understand the OPs intention, the implementation is way off as the PR comment reacts to. If a File object is desired, it would have to be a subclass that wraps all of the capability of the FileObject, and MUST not assume any specifics (e.g. "file".equals...). The File API is not that hard to implement, it even has well defined alternate values for most of the functions if it cannot be implemented (e.g. public long lastModified()Returns: ... 0L if the file does not exist). Cc: pull request -Jason --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@commons.apache.org For additional commands, e-mail: dev-h...@commons.apache.org