Our Products:   CompleteFTP  edtFTPnet/Free  edtFTPnet/PRO  edtFTPj/Free  edtFTPj/PRO
0 votes
2.7k views
in Java FTP by (120 points)
Hi,
I am using the edtFtpj component in my code to do a directory listing and also get some files if necessary. It works perfectly fine for others but for VMS. I have used the dirDetails() method of FTPClient to obtain a FTPFile object for each of the directory listing. Here is the problem. The VMSFileParser apparently looks for the exact sytax of VMS File listing and throws an exception when the directory is not accesible. For example, heres the directory listing that i got using the command prompt FTP:

CLINPATH.DIR;1 4/18 12-FEB-2001 13:40:55 [COLD_CHECKIN] (RWE,RWE,RWE,RWE)
...
...
TEST.DIR;1 No privilege for attempted operation

As you can see, the TEST dir is not visible to the logged in user. Instead of just logging this and moving on, dirDetails() throws a NumberFormatException. This presents a problem for me. For example, if I do this:

try {
FTPFile files[] = ftpclient.dirDetails(null);
}


Since an exception is thrown immediately after encountering a directory with no priveleges, the rest of the directories will not be returned whereas all that needs to be achieved is to just ignore directories which are returned as No priveleges and continue on with the next directory. How would i achieve this with the present API?

Thanks

1 Answer

0 votes
by (162k points)
Hi, can you post a log file and your stack trace please?

Categories

...