maspack.fileutil
Class FileCacher
java.lang.Object
maspack.fileutil.FileCacher
public class FileCacher
- extends java.lang.Object
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
FileCacher
public FileCacher()
initialize
public void initialize()
throws org.apache.commons.vfs2.FileSystemException
- Throws:
org.apache.commons.vfs2.FileSystemException
release
public void release()
addAuthenticator
public void addAuthenticator(URIxMatcher matcher,
org.apache.commons.vfs2.UserAuthenticator auth)
addIdentityRepository
public void addIdentityRepository(URIxMatcher matcher,
com.jcraft.jsch.IdentityRepository repo)
setDefaultFsOptions
public static void setDefaultFsOptions(org.apache.commons.vfs2.FileSystemOptions opts)
throws org.apache.commons.vfs2.FileSystemException
- Throws:
org.apache.commons.vfs2.FileSystemException
setAuthenticator
public static void setAuthenticator(org.apache.commons.vfs2.FileSystemOptions opts,
org.apache.commons.vfs2.UserAuthenticator auth)
throws org.apache.commons.vfs2.FileSystemException
- Throws:
org.apache.commons.vfs2.FileSystemException
setIdentityFactory
public static void setIdentityFactory(org.apache.commons.vfs2.FileSystemOptions opts,
org.apache.commons.vfs2.provider.sftp.IdentityRepositoryFactory factory)
throws org.apache.commons.vfs2.FileSystemException
- Throws:
org.apache.commons.vfs2.FileSystemException
cache
public java.io.File cache(URIx uri,
java.lang.String cachePath)
throws org.apache.commons.vfs2.FileSystemException
- Throws:
org.apache.commons.vfs2.FileSystemException
getFileSize
public long getFileSize(URIx uri)
- Returns the size of the specified file
getFileSize
public long getFileSize(java.io.File file)
cache
public java.io.File cache(URIx uri,
java.io.File cacheFile)
throws org.apache.commons.vfs2.FileSystemException
- Throws:
org.apache.commons.vfs2.FileSystemException
cache
public java.io.File cache(URIx uri,
java.io.File cacheFile,
FileTransferMonitor monitor)
throws org.apache.commons.vfs2.FileSystemException
- Throws:
org.apache.commons.vfs2.FileSystemException
getInputStream
public java.io.InputStream getInputStream(URIx uri)
throws org.apache.commons.vfs2.FileSystemException
- Throws:
org.apache.commons.vfs2.FileSystemException