The Extended Universal Resource Locator library
The NetBeans Filesystems implementation has been
designed to make it separable from the rest of the IDE. The result is
that it can be used as a library in other client- or server- side Java applications. We would like to
encourage this, as it offers some distinct advantages over direct file access.
NetBeans 3.x uses a concept of a virtual filesystem, in which the user "mounts"
directories that contain files the IDE is interested in. The mounting concept is very similar to Unix's concept
of mounts. In its usage inside NetBeans, the set of mounted filesystems makes up the classpath for
compilation, execution and debugging.
NetBeans 4.x does not have user-visible mounts. It continues to use the Filesystems infrastructure internally.
Why use it?
Filesystems are an abstraction on top of
java.io.File (in the case of local files), that provide a number of
- File storage is completely abstracted - third parties can create support for access to file-like objects
stored in an arbitrary manner, such as in a database, or in a version control system.
- Built-in support for ZIP/JAR archives and XML-based filesystems and the ability to transparently use other
filesystems supported by NetBeans (such as the FTP filesystem) by adding the necessary classes
- Supports listening for change events if a file is externally modified
- Ability to add arbitrary "status" data to a file object and be notified of changes on it
- Support for actions on file objects, allowing you to define what actions are possible on a given file (and
dynamically update these), and then expose those actions through your user interface.
This only scratches the surface of how this library can be useful. For more details, see the
download and examples page.