org.wymiwyg.commons.util.dirbrowser
Class ZipPathNode

java.lang.Object
  extended by org.wymiwyg.commons.util.dirbrowser.ZipPathNode
All Implemented Interfaces:
PathNode

public class ZipPathNode
extends Object
implements PathNode

Author:
reto

Constructor Summary
ZipPathNode(JarURLConnection connection)
           
ZipPathNode(ZipFile file, String entryName)
           
 
Method Summary
 boolean equals(Object other)
           
 boolean exists()
           
 InputStream getInputStream()
           
 Date getLastModified()
           
 long getLength()
           
 String getPath()
           
 PathNode getSubPath(String requestPath)
           
 int hashCode()
           
 boolean isDirectory()
           
 String[] list()
           
 String[] list(PathNameFilter filter)
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ZipPathNode

public ZipPathNode(JarURLConnection connection)
            throws IOException
Parameters:
connection -
Throws:
IOException

ZipPathNode

public ZipPathNode(ZipFile file,
                   String entryName)
Method Detail

getSubPath

public PathNode getSubPath(String requestPath)
Specified by:
getSubPath in interface PathNode
Returns:
See Also:
PathNode.getSubPath(java.lang.String)

isDirectory

public boolean isDirectory()
Specified by:
isDirectory in interface PathNode
Returns:
See Also:
PathNode.isDirectory()

list

public String[] list(PathNameFilter filter)
Specified by:
list in interface PathNode
Returns:
See Also:
PathNode.list(org.wymiwyg.commons.util.dirbrowser.PathNameFilter)

list

public String[] list()
Specified by:
list in interface PathNode
Returns:

getInputStream

public InputStream getInputStream()
                           throws IOException
Specified by:
getInputStream in interface PathNode
Returns:
Throws:
IOException
See Also:
PathNode.getInputStream()

toString

public String toString()
Overrides:
toString in class Object
See Also:
Object.toString()

getLength

public long getLength()
Specified by:
getLength in interface PathNode
Returns:
the size of the entry or -1

equals

public boolean equals(Object other)
Overrides:
equals in class Object

hashCode

public int hashCode()
Overrides:
hashCode in class Object

getPath

public String getPath()
Specified by:
getPath in interface PathNode
Returns:
a slash separated string representation of this path

getLastModified

public Date getLastModified()
Specified by:
getLastModified in interface PathNode
Returns:
the date of last modification, or if unavailable creation, or null

exists

public boolean exists()
Specified by:
exists in interface PathNode
Returns:
true if the PathNode points to an existing entity.


Copyright © 2011. All Rights Reserved.