Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

get contents of an ftp folder in java

0 views
Skip to first unread message

Eqbal

unread,
Sep 23, 2004, 3:58:11 PM9/23/04
to
I need to get contents of an ftp folder (it needs a username and
password too) and then treat the files in that folder like a regular
File object. Is it possible? Any pointers on how to do this?

Thanks.

Tor Iver Wilhelmsen

unread,
Sep 24, 2004, 3:55:06 AM9/24/04
to
zaffa...@yahoo.com (Eqbal) writes:

No, it's not possible as such, because the FTP protocol is vastly
different from the File object's functionality.

Look for an FTP library instead.

andreas

unread,
Sep 24, 2004, 8:36:37 AM9/24/04
to

have a look at

http://www.nsftools.com/tips/FTPConnection.java

it is a complete ftp client. in the comments it says:

* this class can be freely distributed and
* modified as long as Bret Taylor is given credit in the source code
comments.

i hereby do give credit to Bret Taylor, since the client has been a great
help
for myself :-)

- and yes, using this class you can connect to an ftp folder and treat the
files
like File objects.

andreas


0 new messages