how to use FTPClient.list(String mask) ?

Hi all,

about the package enterprisedt.net.ftp.FTPClient

(http://www.enterprisedt.com/downloads/ftp.html)

I have a problem using the FTPClient method "list",

what do they call a "mask", I would like an example with "list".

thanks

Yves

[308 byte] By [ybucher] at [2007-9-26 1:30:55]
# 1
Didn't you read the docs? It's the file mask...Example: client.list("*.java")
jsalonen at 2007-6-29 1:29:41 > top of Java-index,Archived Forums,Java Programming...
# 2

Trying myClient.list("*.ps")

when connected onto a sun server

I get this NullPointerException :

(others commands work)

java.lang.NullPointerException

at com.enterprisedt.net.ftp.FTPClient.list(FTPClient.java:546)

at com.enterprisedt.net.ftp.FTPClient.list(FTPClient.java:530)

at com.oqibo.test.ftp.Menu1.<init>(Menu1.java:50)

at com.oqibo.test.ftp.Menu1.main(Menu1.java:63)

Exception in thread "main"

ybucher at 2007-6-29 1:29:41 > top of Java-index,Archived Forums,Java Programming...
# 3
Looks like you didn't remember to set the transfertype. The line 546 goes if (transferType.equals(FTPTransferType.BINARY)) {
jsalonen at 2007-6-29 1:29:41 > top of Java-index,Archived Forums,Java Programming...