Example 2

Extract only the text files from the Zip file zf into the directory target.

JavaScript

enableTaskPackage("org.at4j"); new At4JUnzipTF(). // The Zip file. This may for instance be a File or an EFile. setSource(zf). // The target directory. This may for instance be a File directory or a // Directory. setTarget(target). setFilter( // Use an At4J Filter<ArchiveEntry> that only matches // text file entries. FileAEF.FILTER.and( new NameGlobAEF( new Glob("*.txt")))). run();


* An EntityFS-aware task is implemented using EntityFS. This means that it uses the filter settings of DirectoryView:s and also that it often can work with other file system implementations than File-based, such as the RAM file system.