|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface ProFTPClientInterface
Interface defining additional operations for FTP clients. These include the API equivalents of command line FTP clients' mput and mget.
Some operations permit a wildcard string to be supplied for matching filenames (directories are not matched against the wildcard). The syntax used is '?' for single chars and '*' for multiple chars, e.g. 'asdf??df*abc' would match 'asdfxydfdsfsjfkj33abc'. On Windows clients, case is ignored.
Note that if there are a large number of files to be transferred, the client or server may run out of sockets, as a new socket is created for each data transfer and each directory listing. TCP's TIME_WAIT means that sockets are not reclaimed immediately. If sleeping is enabled via setSleepEnabled(true), then Thread.sleep() is called after n transfers, where n is set by setCountBeforeSleep(n). The time spent asleep is set via setSleepTime().
| Field Summary | |
|---|---|
static java.lang.String |
cvsId
Revision control id |
| Method Summary | |
|---|---|
int |
getCountBeforeSleep()
Get the number of transfers set before sleeping |
int |
getSleepTime()
Get the number of seconds spent asleep |
boolean |
isSleepEnabled()
Is sleeping enabled? |
void |
mdelete(java.io.FileFilter filter)
Deletes all files matching the filter in the current remote directory only |
void |
mdelete(java.lang.String wildcard)
Deletes all files matching the wildcard in the current remote directory only |
void |
mdelete(java.lang.String remoteDir,
java.io.FileFilter filter,
boolean recurse)
Delete all the files in this directory (and its subdirectories if recurse is true) that match the supplied filter. |
void |
mdelete(java.lang.String remoteDir,
java.lang.String wildcard,
boolean recurse)
Delete all the files in this directory (and its subdirectories if recurse is true) that match the supplied wildcard. |
void |
mget(java.lang.String localDir,
java.io.FileFilter filter)
Get all files matching the filter in the current remote directory only into the supplied local directory |
void |
mget(java.lang.String localDir,
java.lang.String wildcard)
Get all files matching the filter in the current remote directory only into the supplied local directory |
void |
mget(java.lang.String localDir,
java.lang.String remoteDir,
java.io.FileFilter filter,
boolean recurse)
Gets this entire remote directory and its contents, recursively going through the remote directory name supplied. |
void |
mget(java.lang.String localDir,
java.lang.String remoteDir,
java.lang.String wildcard,
boolean recurse)
Gets this entire remote directory and its contents, recursively going through the remote directory name supplied. |
void |
mput(java.lang.String localDir,
java.io.FileFilter filter)
Put all files matching the wildcard in the supplied local directory only into the current remote directory |
void |
mput(java.lang.String localDir,
java.lang.String wildcard)
Put all files matching the wildcard in the supplied local directory only into the current remote directory |
void |
mput(java.lang.String localDir,
java.lang.String remoteDir,
java.io.FileFilter filter,
boolean recurse)
Puts this entire directory and its contents. |
void |
mput(java.lang.String localDir,
java.lang.String remoteDir,
java.lang.String wildcard,
boolean recurse)
Puts this entire directory and its contents. |
void |
rmdir(java.lang.String remoteDir,
boolean recurse)
Delete this remote directory. |
void |
setCountBeforeSleep(int countBeforeSleep)
Set the number of transfers required before sleeping |
void |
setSleepEnabled(boolean sleepEnabled)
Set sleeping enabled to be on or off |
void |
setSleepTime(int sleepTime)
Set the time spent asleep |
| Methods inherited from interface com.enterprisedt.net.ftp.FTPClientInterface |
|---|
cancelResume, cancelTransfer, cdup, chdir, connect, connected, delete, dir, dir, dir, dirDetails, executeCommand, exists, get, get, get, getDeleteCount, getDetectTransferMode, getDownloadCount, getId, getMonitorInterval, getRemoteHost, getRemotePort, getTimeout, getType, getUploadCount, keepAlive, mkdir, modtime, put, put, put, put, put, put, pwd, quit, quitImmediately, rename, resetDeleteCount, resetDownloadCount, resetUploadCount, resume, rmdir, setControlEncoding, setDetectTransferMode, setId, setModTime, setProgressMonitor, setProgressMonitor, setRemoteHost, setRemotePort, setTimeout, setType, size, system |
| Field Detail |
|---|
static final java.lang.String cvsId
| Method Detail |
|---|
void mdelete(java.lang.String wildcard)
throws java.io.IOException,
FTPException,
java.text.ParseException
wildcard -
java.io.IOException
FTPException
java.text.ParseException
void mdelete(java.io.FileFilter filter)
throws java.io.IOException,
FTPException,
java.text.ParseException
filter - file filter
java.io.IOException
FTPException
java.text.ParseException
void mdelete(java.lang.String remoteDir,
java.lang.String wildcard,
boolean recurse)
throws java.io.IOException,
FTPException,
java.text.ParseException
remoteDir - name of remote directorywildcard - filename wildcardrecurse - if true, recurse through subdirectories
java.io.IOException
FTPException
java.text.ParseException
void mdelete(java.lang.String remoteDir,
java.io.FileFilter filter,
boolean recurse)
throws java.io.IOException,
FTPException,
java.text.ParseException
remoteDir - name of remote directoryfilter - filename filterrecurse - if true, recurse through subdirectories
java.io.IOException
FTPException
java.text.ParseException
void rmdir(java.lang.String remoteDir,
boolean recurse)
throws java.io.IOException,
FTPException,
java.text.ParseException
remoteDir - name of remote directoryrecurse - if true, recurse through subdirectories
java.io.IOException
FTPException
java.text.ParseException
void mput(java.lang.String localDir,
java.lang.String wildcard)
throws java.io.IOException,
FTPException
localDir - local directory to get files fromwildcard - filename wildcard
java.io.IOException
FTPException
void mput(java.lang.String localDir,
java.io.FileFilter filter)
throws java.io.IOException,
FTPException
localDir - local directory to get files fromfilter - filename filter
java.io.IOException
FTPException
void mput(java.lang.String localDir,
java.lang.String remoteDir,
java.lang.String wildcard,
boolean recurse)
throws FTPException,
java.io.IOException
localDir - name of local directoryremoteDir - name of remote directorywildcard - filename wildcardrecurse - if true recurse into subdirectories
java.io.IOException
FTPException
void mput(java.lang.String localDir,
java.lang.String remoteDir,
java.io.FileFilter filter,
boolean recurse)
throws FTPException,
java.io.IOException
localDir - name of local directoryremoteDir - name of remote directoryfilter - filename filterrecurse - if true recurse into subdirectories
java.io.IOException
FTPException
void mget(java.lang.String localDir,
java.lang.String wildcard)
throws FTPException,
java.io.IOException,
java.text.ParseException
localDir - local directory to get files fromwildcard - filename wildcard
java.io.IOException
FTPException
java.text.ParseException
void mget(java.lang.String localDir,
java.io.FileFilter filter)
throws FTPException,
java.io.IOException,
java.text.ParseException
localDir - local directory to get files fromfilter - filename filter
java.io.IOException
FTPException
java.text.ParseException
void mget(java.lang.String localDir,
java.lang.String remoteDir,
java.lang.String wildcard,
boolean recurse)
throws FTPException,
java.io.IOException,
java.text.ParseException
localDir - name of local directory we are transferring intoremoteDir - name of remote directorywildcard - filename wildcardrecurse - if true recurse into subdirectories
java.io.IOException
FTPException
java.text.ParseException
void mget(java.lang.String localDir,
java.lang.String remoteDir,
java.io.FileFilter filter,
boolean recurse)
throws FTPException,
java.io.IOException,
java.text.ParseException
localDir - name of local directory we are transferring intoremoteDir - name of remote directoryfilter - filename filterrecurse - if true recurse into subdirectories
java.io.IOException
FTPException
java.text.ParseExceptionint getCountBeforeSleep()
void setCountBeforeSleep(int countBeforeSleep)
countBeforeSleep - maximum transfer countboolean isSleepEnabled()
void setSleepEnabled(boolean sleepEnabled)
sleepEnabled - if true, sleeping is enabled, otherwise it is switched offint getSleepTime()
void setSleepTime(int sleepTime)
sleepTime - sleep time in seconds
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||