Package com.oroinc.net.ftp
Interface FTPFileListParser
- All Known Implementing Classes:
DefaultFTPFileListParser
public interface FTPFileListParser
FTPFileListParser defines the interface for parsing FTP file listings
and converting that information into an array of
FTPFile instances.
Sometimes you will want to parse unusual listing formats, in which
case you would create your own implementation of FTPFileListParser and
if necessary, subclass FTPFile.
- Author:
- Daniel F. Savarese
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionFTPFile[]
parseFileList
(InputStream listStream) Parses an FTP server file listing and converts it into a usable format in the form of an array ofFTPFile
instances.
-
Method Details
-
parseFileList
Parses an FTP server file listing and converts it into a usable format in the form of an array ofFTPFile
instances. If the file list contains no files,null
should be returned, otherwise an array ofFTPFile
instances representing the files in the directory is returned.- Parameters:
listStream
- The InputStream from which the file list should be read.- Returns:
- The list of file information contained in the given path. null if the list could not be obtained or if there are no files in the directory.
- Throws:
IOException
- If an I/O error occurs reading the listStream.
-