public abstract class FTPFileEntryParserImpl extends java.lang.Object implements FTPFileEntryParser, FTPFileListParser
Constructor and Description |
---|
FTPFileEntryParserImpl()
The constructor for a FTPFileEntryParserImpl object.
|
Modifier and Type | Method and Description |
---|---|
FTPFile[] |
parseFileList(java.io.InputStream listStream)
Deprecated.
The version of this method which takes an encoding should be used.
|
FTPFile[] |
parseFileList(java.io.InputStream listStream,
java.lang.String encoding)
Parses an FTP server file listing and converts it into a usable format
in the form of an array of
FTPFile instances. |
java.util.List |
preParse(java.util.List original)
This method is a hook for those implementors (such as
VMSVersioningFTPEntryParser, and possibly others) which need to
perform some action upon the FTPFileList after it has been created
from the server stream, but before any clients see the list.
|
java.lang.String |
readNextEntry(java.io.BufferedReader reader)
Reads the next entry using the supplied BufferedReader object up to
whatever delemits one entry from the next.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
parseFTPEntry
public FTPFileEntryParserImpl()
public FTPFile[] parseFileList(java.io.InputStream listStream, java.lang.String encoding) throws java.io.IOException
FTPFile
instances. If the
file list contains no files, null
should be
returned, otherwise an array of FTPFile
instances
representing the files in the directory is returned.
parseFileList
in interface FTPFileListParser
listStream
- The InputStream from which the file list should be
read.encoding
- The encoding to use.java.io.IOException
- If an I/O error occurs reading the listStream.public FTPFile[] parseFileList(java.io.InputStream listStream) throws java.io.IOException
FTPFile
instances. If the
file list contains no files, null
should be
returned, otherwise an array of FTPFile
instances
representing the files in the directory is returned.
parseFileList
in interface FTPFileListParser
listStream
- The InputStream from which the file list should be
read.java.io.IOException
- If an I/O error occurs reading the listStream.public java.lang.String readNextEntry(java.io.BufferedReader reader) throws java.io.IOException
readNextEntry
in interface FTPFileEntryParser
reader
- The BufferedReader object from which entries are to be
read.java.io.IOException
- thrown on any IO Error reading from the reader.public java.util.List preParse(java.util.List original)
preParse
in interface FTPFileEntryParser
original
- Original list after it has been created from the server streamoriginal
unmodified.