net.jangaroo.jooc.input
Class ZipFileInputSource

java.lang.Object
  extended by net.jangaroo.jooc.input.DirectoryInputSource
      extended by net.jangaroo.jooc.input.ZipFileInputSource
All Implemented Interfaces:
InputSource

public class ZipFileInputSource
extends DirectoryInputSource


Constructor Summary
ZipFileInputSource(File file, String[] rootDirs)
          Create an InputSource directory from the given zip or jar file, providing a "union view" over the zip file with all entries with paths relative to the given root directories
 
Method Summary
 void close()
           
 InputSource getChild(String path)
           
 char getFileSeparatorChar()
           
 String getName()
          The file name, i.e. test.as
 String getPath()
           
 String getRelativePath()
           
 ZipFile getZipFile()
           
 List<InputSource> list()
           
 
Methods inherited from class net.jangaroo.jooc.input.DirectoryInputSource
getInputStream, getParent, isDirectory
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ZipFileInputSource

public ZipFileInputSource(File file,
                          String[] rootDirs)
                   throws IOException
Create an InputSource directory from the given zip or jar file, providing a "union view" over the zip file with all entries with paths relative to the given root directories

Parameters:
file - a zip or jar file
rootDirs - a list of directories to accept as roots (e.g. ["", "META-INF/joo-api"], in lookup order
Throws:
IOException - if an IO error occurs
Method Detail

getName

public String getName()
Description copied from interface: InputSource
The file name, i.e. test.as

Returns:
the file name

getPath

public String getPath()

getRelativePath

public String getRelativePath()

list

public List<InputSource> list()

close

public void close()
           throws IOException
Specified by:
close in interface InputSource
Overrides:
close in class DirectoryInputSource
Throws:
IOException

getFileSeparatorChar

public char getFileSeparatorChar()

getZipFile

public ZipFile getZipFile()

getChild

public InputSource getChild(String path)


Copyright © 2002-2011 CoreMedia AG. All Rights Reserved.