org.pf.file
Class ArchiveTOC

java.lang.Object
  extended by org.pf.file.ArchiveTOC

public class ArchiveTOC
extends java.lang.Object

This is a wrapper class around a zip archive's table of contents. It reads in the table of contents of an archive and provides it as a NamedValueList where the names are the directories and the values are arrays of FileInfo.

Version:
1.0
Author:
Manfred Duchrow

Constructor Summary
ArchiveTOC(java.io.File archive)
          Initialize the new instance with the archive identified by the given file.
ArchiveTOC(java.lang.String filename)
          Initialize the new instance with the archive named by the given filename.
 
Method Summary
 NamedValueList toc()
          Returns a named value list, where the names are directory names and the values are FileInfo[] objects containing all files inside the directories.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ArchiveTOC

public ArchiveTOC(java.lang.String filename)
           throws java.io.IOException
Initialize the new instance with the archive named by the given filename. Reads in automatically the archive's table of contents.

Throws:
java.io.IOException

ArchiveTOC

public ArchiveTOC(java.io.File archive)
           throws java.io.IOException
Initialize the new instance with the archive identified by the given file. Reads in automatically the archive's table of contents.

Throws:
java.io.IOException
Method Detail

toc

public NamedValueList toc()
Returns a named value list, where the names are directory names and the values are FileInfo[] objects containing all files inside the directories.