Chapter 21. Intermezzo: When the Efficiency/Usability Balance Is Tipped: Enumerating FTP Server Directories

 

Giving money and power to government is like giving whiskey and car keys to teenage boys.

 
 --P. J. O’Rourke

The Windows WinInet API presents an abstraction over Internet protocols, providing a suite of functions that simplify Internet programming of the HTTP, FTP, and Gopher protocols. Of particular interest to us, at this point in the book, are the FtpFindFirstFile(), InternetFindNextFile(), and InternetClose() functions, which provide a means of enumerating the contents of a directory on a remote FTP server. Conveniently, for Windows programmers at least, FtpFindFirstFile() and InternetFindNextFile() return information to the caller using ...

Get Extended STL, Volume 1: Collections and Iterators now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.