|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.jboss.virtual.plugins.context.AbstractVirtualFileHandler
org.jboss.virtual.plugins.context.AbstractURLHandler
org.jboss.virtual.plugins.context.jar.SynthenticDirEntryHandler
public class SynthenticDirEntryHandler
SynthenticDirEntryHandler represents non-existent directory jar entry.
| Field Summary |
|---|
| Fields inherited from class org.jboss.virtual.plugins.context.AbstractVirtualFileHandler |
|---|
cachedLastModified, log, vfsUrl |
| Constructor Summary | |
|---|---|
SynthenticDirEntryHandler(VFSContext context,
VirtualFileHandler parent,
java.lang.String entryName,
long lastModified,
java.net.URL url)
Create a new SynthenticDirEntryHandler. |
|
| Method Summary | |
|---|---|
void |
addChild(VirtualFileHandler child)
Add a child to an entry |
VirtualFileHandler |
createChildHandler(java.lang.String name)
Create a child handler for the given name. |
boolean |
exists()
TODO: removing the entry/jar that resulted in this needs to be detected. |
VirtualFileHandler |
findChild(java.lang.String path)
Find a child |
java.util.List<VirtualFileHandler> |
getChildren(boolean ignoreErrors)
Get the children |
long |
getLastModified()
When the file was last modified |
long |
getSize()
Get the size |
boolean |
isHidden()
Whether it is hidden |
boolean |
isLeaf()
Whether it is a simple leaf of the VFS, i.e. |
java.io.InputStream |
openStream()
Access the file contents. |
| Methods inherited from class org.jboss.virtual.plugins.context.AbstractURLHandler |
|---|
getURL, initCacheLastModified, toURI, toURL |
| Methods inherited from class org.jboss.virtual.plugins.context.AbstractVirtualFileHandler |
|---|
checkClosed, close, decrement, doClose, equals, getName, getParent, getPathName, getVFSContext, getVirtualFile, hasBeenModified, hashCode, increment, setPathName, simpleFindChild, structuredFindChild, toString, toVfsUrl |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public SynthenticDirEntryHandler(VFSContext context,
VirtualFileHandler parent,
java.lang.String entryName,
long lastModified,
java.net.URL url)
throws java.io.IOException
context - the contextparent - the parententryName - - the simple name for the dirlastModified - the timestamp for the dirurl - the full url
java.io.IOException - for an error accessing the file system
java.lang.IllegalArgumentException - for a null context, url, jar or entry| Method Detail |
|---|
public void addChild(VirtualFileHandler child)
child - public long getLastModified()
VirtualFileHandler
getLastModified in interface VirtualFileHandlergetLastModified in class AbstractURLHandlerpublic long getSize()
VirtualFileHandler
getSize in interface VirtualFileHandlergetSize in class AbstractURLHandler
public boolean exists()
throws java.io.IOException
exists in interface VirtualFileHandlerexists in class AbstractURLHandlerjava.io.IOException - - thrown on failure to detect existence.URLConnection.getLastModified(),
org.jboss.test.virtual.test.URLExistsUnitTestCasepublic boolean isLeaf()
VirtualFileHandler
isLeaf in interface VirtualFileHandlerpublic boolean isHidden()
VirtualFileHandler
isHidden in interface VirtualFileHandlerisHidden in class AbstractURLHandler
public java.io.InputStream openStream()
throws java.io.IOException
VirtualFileHandler
openStream in interface VirtualFileHandleropenStream in class AbstractURLHandlerjava.io.IOException - for any problem accessing the virtual file system
public java.util.List<VirtualFileHandler> getChildren(boolean ignoreErrors)
throws java.io.IOException
VirtualFileHandler
getChildren in interface VirtualFileHandlerignoreErrors - whether to ignore errors
java.io.IOException - for an error accessing the file system
public VirtualFileHandler findChild(java.lang.String path)
throws java.io.IOException
VirtualFileHandler
findChild in interface VirtualFileHandlerpath - the path
java.io.IOException - for an error accessing the file system (or the child doesn't exist)
public VirtualFileHandler createChildHandler(java.lang.String name)
throws java.io.IOException
createChildHandler in interface StructuredVirtualFileHandlername - - the simple name of an immeadiate child.
java.io.IOException - - thrown if there are no children or the
name does not match a child
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||