Retrieving filesize information |
You can retrieve the byte size of a file using the Ftp#getFilesize method. All filenames are relative to your current remote directory.
Example
// get size of file image.gif in bytes long filesize = ftp.getFilesize("image.gif");
Note
The Ftp#getFilesize method utilizes a command that is supported by a majority of FTP servers however is not officially recognized by RFC 959 so may not be supported on some FTP servers.
See also
|