org.apache.tools.ant.taskdefs.optional.netClass FTPTaskMirrorImpl.FTPFileProxy
- java.lang.Object
- java.io.File
- org.apache.tools.ant.taskdefs.optional.net.FTPTaskMirrorImpl.FTPFileProxy
- All Implemented Interfaces:
- java.io.Serializable, java.lang.Comparable<java.io.File>
- Enclosing class:
- FTPTaskMirrorImpl
protected static class FTPTaskMirrorImpl.FTPFileProxy extends java.io.Fileinternal class providing a File-like interface to some of the information available from the FTP server
- See Also:
- Serialized Form
Constructor Summary
Constructors Constructor and Description FTPFileProxy(org.apache.commons.net.ftp.FTPFile file)creates a proxy to a FTP fileFTPFileProxy(java.lang.String completePath)creates a proxy to a FTP directory
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description booleanexists()java.lang.StringgetAbsolutePath()java.lang.StringgetName()java.lang.StringgetParent()java.lang.StringgetPath()booleanisAbsolute()FTP files are stored as absolute pathsbooleanisDirectory()booleanisFile()booleanisHidden()FTP files cannot be hiddenlonglastModified()longlength()
Methods inherited from class java.io.File
canExecute, canRead, canWrite, compareTo, createNewFile, createTempFile, createTempFile, delete, deleteOnExit, equals, getAbsoluteFile, getCanonicalFile, getCanonicalPath, getFreeSpace, getParentFile, getTotalSpace, getUsableSpace, hashCode, list, list, listFiles, listFiles, listFiles, listRoots, mkdir, mkdirs, renameTo, setExecutable, setExecutable, setLastModified, setReadable, setReadable, setReadOnly, setWritable, setWritable, toPath, toString, toURI, toURL
Constructor Detail
FTPFileProxy
public FTPFileProxy(org.apache.commons.net.ftp.FTPFile file)creates a proxy to a FTP file
- Parameters:
file- FTPFile
FTPFileProxy
public FTPFileProxy(java.lang.String completePath)creates a proxy to a FTP directory
- Parameters:
completePath- the remote directory.
Method Detail
exists
public boolean exists()
- Overrides:
existsin classjava.io.File
getAbsolutePath
public java.lang.String getAbsolutePath()
- Overrides:
getAbsolutePathin classjava.io.File
getName
public java.lang.String getName()
- Overrides:
getNamein classjava.io.File
getParent
public java.lang.String getParent()
- Overrides:
getParentin classjava.io.File
getPath
public java.lang.String getPath()
- Overrides:
getPathin classjava.io.File
isAbsolute
public boolean isAbsolute()FTP files are stored as absolute paths
- Overrides:
isAbsolutein classjava.io.File- Returns:
- true
isDirectory
public boolean isDirectory()
- Overrides:
isDirectoryin classjava.io.File
isFile
public boolean isFile()
- Overrides:
isFilein classjava.io.File
isHidden
public boolean isHidden()FTP files cannot be hidden
- Overrides:
isHiddenin classjava.io.File- Returns:
- false
lastModified
public long lastModified()
- Overrides:
lastModifiedin classjava.io.File
length
public long length()
- Overrides:
lengthin classjava.io.File