TrueVFS is a virtual file system (VFS) for Java 7 which enables client applications to perform CRUD (Create, Read, Update, Delete) operations on archive files as if they were virtual directories, even with nested archive files in multithreaded environments - see Key Features. For example, creating a TAR.GZ file from a ZIP file is as easy as calling:

new TFile("archive.zip").cp_rp(new TFile("archive.tar.gz"));

The semantics of this example are roughly equivalent to the GNU command...

cp -rp archive.zip archive.tar.gz

... if only the cp command would let you access ZIP files and TAR.GZ files as if they were directories. The high abstraction level of the API in the client module TrueVFS Access enables optimization of I/O access, so that this example operation doesn't even require any buffering to temporary files!


TrueVFS is open source software and is covered by the Apache License, Version 2.0. Please refer to the license agreement for details.

State Of Affairs

TrueVFS is the official successor of TrueZIP. As of version 7.7.7, the TrueZIP project has changed to maintenance mode. In comparison, TrueVFS 0.12.0 provides superior error handling, improved performance plus advanced features for archive drivers and virtual file system monitoring and management.

TrueVFS has been developed by refactoring the TrueZIP code base. TrueVFS 0.12.0 reflects the latest changes up to TrueZIP 7.7.10. While refactoring, the original suite of test code has been maintained and extended so that you can put the same faith into TrueVFS than you can put into TrueZIP.

Future Direction

TrueVFS version is not yet at 1.0 because chances are that there will be backwards incompatible changes to the API of internal modules. This is unlikely to happen to the API of the client module TrueVFS Access, however.

Supported File System Types

TrueVFS 0.12.0 ships with pluggable driver modules for FILE, HTTP(S), JAR, ODF, SFX, TAR, TAR.BZIP2, TAR.GZIP, TAR.XZ, ZIP and ZIP.RAES (TZP) file system schemes.

Simply add the JAR artifact of these driver modules to the run time class path to make their file system drivers available for service location in the client API module - see below.

Using TrueVFS

As a library, TrueVFS provides simple, uniform, transparent, thread-safe, read/write access to archive files as if they were virtual directories in a file system path. TrueVFS provides the client module TrueVFS Access with the API for convenient access to its (federated virtual) file system space.

Writing an application for this API is really simple: Please have a look at the page Getting Started to learn how to generate a TrueVFS client application from a Maven archetype in about ten minutes or have a look at the tutorial.

Extending TrueVFS

As a framework, TrueVFS provides the API to write pluggable file system drivers which seemlessly integrate into the federated file system space. The module TrueVFS Kernel modules features federating, multithreading, multiplexing, caching and accounting so that (archive) file system drivers do not need to take care of these aspects of a (virtual) file system.

While there is no tutorial for how to write a file system driver, there's comprehensive Javadoc and sample code:

  • If you are going to write an archive file system driver, please consult the Javadoc for the abstract class FsArchiveDriver.
  • If you are going to write a plain file system driver, please consult the Javadoc for the abstract class FsDriver.