commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Andrew Barnes <a...@geni.com.au>
Subject [vfs] usage questions
Date Wed, 08 Mar 2006 02:34:56 GMT
Hi

Just wanted to ask some basic usage questions for using Commons VFS in a
J2EE app.

1) I call VFS.getManager() from a constructor of my file system wrapper
class, and use that one FileSystemManager instance every time a CommonsVFS
operation is executed. Is this the correct usage? Or should I get a
different FileSystemManager for each request. I notice that the close()
method is not on the FileSystemManager interface.

2) If you can use the same FileSystemManager instance across multiple calls,
do you need to periodically free unused resources?

3) Do you only need to close a FileObject when you have retrieved the
content, or should close it after any operation.

Sorry if these seem like silly questions, but the documentation seems a
little unclear. It says in the documentation that "You should make sure that
you call close() on the manager when you are finished with it." Is this for
all methods of retrieval and configuration, or only when you create and
configure it programmatically.

Regards
Andy



---------------------------------------------------------------------
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