You can use the File class wherever the "real" files are, but as soon as you have a File object for a directory that provides the list of files you can use your existing sockets to write/read the object via the socket stream. Once you have a copy of it at the far end you should be able to use its methods to peruse the file list. (But I haven't actually tried this myself!)
Last edited by JamesCherrill; Jul 3rd, 2009 at 2:51 pm.
Reputation Points: 1907
Solved Threads: 950
Posting Expert
Offline 5,768 posts
since Apr 2008