public class VFSFile extends AbstractFileImpl<VFSFile>
fileFactory| Constructor and Description |
|---|
VFSFile(org.apache.commons.vfs2.FileObject file,
VFSFileFactory fileFactory,
Connection con) |
VFSFile(String path,
String defaultPath,
VFSFileFactory fileFactory,
Connection con,
org.apache.commons.vfs2.FileSystemOptions opts) |
VFSFile(String path,
VFSFileFactory fileFactory,
Connection con) |
| Modifier and Type | Method and Description |
|---|---|
void |
copyFrom(AbstractFile src) |
boolean |
createFolder() |
boolean |
createNewFile() |
boolean |
delete(boolean recurse) |
boolean |
exists() |
String |
getAbsolutePath() |
SftpFileAttributes |
getAttributes() |
String |
getCanonicalPath() |
List<AbstractFile> |
getChildren() |
org.apache.commons.vfs2.FileObject |
getFileObject() |
InputStream |
getInputStream() |
String |
getName() |
OutputStream |
getOutputStream() |
boolean |
isDirectory() |
boolean |
isFile() |
boolean |
isHidden() |
boolean |
isReadable() |
boolean |
isWritable() |
long |
lastModified() |
long |
length() |
void |
moveTo(AbstractFile target) |
AbstractFileRandomAccess |
openFile(boolean writeAccess) |
void |
refresh() |
AbstractFile |
resolveFile(String child) |
void |
setAttributes(SftpFileAttributes attrs) |
boolean |
supportsRandomAccess() |
void |
truncate() |
getFileFactory, getOutputStreampublic VFSFile(org.apache.commons.vfs2.FileObject file,
VFSFileFactory fileFactory,
Connection con)
public VFSFile(String path, VFSFileFactory fileFactory, Connection con) throws IOException
IOExceptionpublic VFSFile(String path, String defaultPath, VFSFileFactory fileFactory, Connection con, org.apache.commons.vfs2.FileSystemOptions opts) throws IOException
IOExceptionpublic org.apache.commons.vfs2.FileObject getFileObject()
public boolean exists()
throws IOException
IOExceptionpublic boolean createFolder()
throws PermissionDeniedException,
IOException
PermissionDeniedExceptionIOExceptionpublic long lastModified()
throws IOException
IOExceptionpublic String getName()
public long length()
throws IOException
IOExceptionpublic SftpFileAttributes getAttributes() throws IOException
IOExceptionpublic boolean isHidden()
throws IOException
IOExceptionpublic boolean isDirectory()
throws IOException
IOExceptionpublic List<AbstractFile> getChildren() throws IOException, PermissionDeniedException
IOExceptionPermissionDeniedExceptionpublic boolean isFile()
throws IOException
IOExceptionpublic String getAbsolutePath() throws IOException, PermissionDeniedException
IOExceptionPermissionDeniedExceptionpublic void copyFrom(AbstractFile src) throws IOException, PermissionDeniedException
copyFrom in interface AbstractFilecopyFrom in class AbstractFileImpl<VFSFile>IOExceptionPermissionDeniedExceptionpublic boolean isReadable()
throws IOException
IOExceptionpublic boolean isWritable()
throws IOException
IOExceptionpublic boolean createNewFile()
throws PermissionDeniedException,
IOException
PermissionDeniedExceptionIOExceptionpublic void truncate()
throws PermissionDeniedException,
IOException
PermissionDeniedExceptionIOExceptionpublic InputStream getInputStream() throws IOException
IOExceptionpublic OutputStream getOutputStream() throws IOException
IOExceptionpublic boolean delete(boolean recurse)
throws IOException
IOExceptionpublic void moveTo(AbstractFile target) throws IOException, PermissionDeniedException
moveTo in interface AbstractFilemoveTo in class AbstractFileImpl<VFSFile>IOExceptionPermissionDeniedExceptionpublic void setAttributes(SftpFileAttributes attrs) throws IOException
IOExceptionpublic String getCanonicalPath() throws IOException, PermissionDeniedException
IOExceptionPermissionDeniedExceptionpublic boolean supportsRandomAccess()
public AbstractFileRandomAccess openFile(boolean writeAccess) throws IOException
IOExceptionpublic void refresh()
public AbstractFile resolveFile(String child) throws IOException, PermissionDeniedException
IOExceptionPermissionDeniedExceptionCopyright © 2025. All rights reserved.