commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mark Fortner <phidia...@yahoo.com>
Subject Re: VFS Questions
Date Mon, 02 Jan 2006 22:12:06 GMT
Anton,
Thanks for the examples. 

As for point #5.  IMO VFS shouldn't be relegated to the server.  In 
reality there are a limited number of use cases where I would want to 
use VFS on a server.  But I can think of plenty of reasons to want a 
better file management API on the desktop.  Being able to indicate that 
a file is selected is an essential part of that.

If there's another way of indicating a file is selected, please let me know.

Thanks again,

Mark

anton huber wrote:

> Hi Mark!
>
>   ad 2.:
>      length() -> fileObject.getContent().getSize()
>      isFile() -> fileObject.getType()==FileType.FILE
>      isDirectory() -> fileObject.getType()==FileType.FOLDER
>      getLastModified() -> fileObject.getContent().getLastModifiedTime()
>
>   ad 4.: rename:
>            long lastModTime = 
> sourceFileObject.getContent().getLastModifiedTime();
>            if (!sourceFileObject.canRenameTo(targetFileObject)){ // 
> other device
>                targetFileObject.copyFrom(sourceFileObject, 
> Selectors.SELECT_SELF);
>                sourceFileObject.delete(Selectors.SELECT_SELF);
>             } else { // same device
>                sourceFileObject.moveTo(targetFileObject);
>            }
>            
> targetFileObject.getContent().setLastModifiedTime(lastModTime);
>
>   ad 5.: Is this realy a matter of VFS ?
>
>
> Hope it helps.
>
> _________________________________________________________________
> FREE pop-up blocking with the new MSN Toolbar - get it now! 
> http://toolbar.msn.click-url.com/go/onm00200415ave/direct/01/
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: commons-user-help@jakarta.apache.org
>
>


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


Mime
View raw message