Class VfsResource
java.lang.Object
org.apache.ivy.plugins.repository.vfs.VfsResource
- All Implemented Interfaces:
Resource
-
Constructor Summary
ConstructorsConstructorDescriptionVfsResource(String vfsURI, org.apache.commons.vfs2.FileSystemManager fsManager) -
Method Summary
Modifier and TypeMethodDescriptionClones this resource with a new resource with a different namebooleanexists()Flag indicating whether a resource is available for queryingGet a list of direct descendants of the given resource.org.apache.commons.vfs2.FileContentlongGet the size of the resourcelongGet the last modification time of the resource.getName()Get the name of the resource.booleanisLocal()Is this resource local to this host, i.e.static StringThe VFS FileName getURI method seems to have a bug in it where file: URIs will have 4 forward slashes instead of 3.Opens a stream on this resourcebooleanReturn a flag indicating whether a provided VFS resource physically existstoString()
-
Constructor Details
-
VfsResource
-
-
Method Details
-
getChildren
-
getContent
public org.apache.commons.vfs2.FileContent getContent() -
getName
-
clone
-
normalize
-
getLastModified
public long getLastModified()Get the last modification time of the resource.- Specified by:
getLastModifiedin interfaceResource- Returns:
- a
longindicating last modified time.
-
getContentLength
public long getContentLength()Get the size of the resource- Specified by:
getContentLengthin interfaceResource- Returns:
- a
longrepresenting the size of the resource (in bytes).
-
exists
-
physicallyExists
public boolean physicallyExists()Return a flag indicating whether a provided VFS resource physically exists- Returns:
trueif the resource physically exists,falseotherwise.
-
toString
-
isLocal
-
openStream
Description copied from interface:ResourceOpens a stream on this resource- Specified by:
openStreamin interfaceResource- Returns:
- the opened input stream
- Throws:
IOException- if something goes wrong
-