|
|
NewsCounter
At some point I got interested in how to communicate with a USENET (news/nntp) server. I couldn't find any classes on the internet that would help me, so I wrote my own. To connect to a news-server you need to communicate through the NNTP protocol. It's a really simple text-string based protocol, consisting of several new-line separated commands that always result in a reply in the form of another formatted text-string. This code was actually going to be a real application, when I discovered that I could pretty much do the same with MS Outlook Express, and as the NNTP protocol didn't turn out to be such a challenge, I lost interest in completing the class with all the NNTP commands (e.g. reading and posting news articles). The Source CodeThe CNntpSession ClassTheCNntpSession class extends the CSocket MFC class.
It implements basic communication with a news server.
It is just as easy to use as the usual MFC CHttpSession and CInternetSession
classes.
What else is in thereBesides from getting News group information, the application uses Pattern Matching to filter the list. It also uses multi-threading to be able to seamlessly update the article count as results come in from the NNTP queries.The source files also contain a RFC document describing the NNTP protocol commands, so you can easily extend the class for your own needs. Interface
Code Features
TODO List
Source Code DependenciesMicrosoft Visual C++ 6.0Microsoft MFC Library Installation Guide
Download Files
Written by Bjarke Viksoe. Article submitted 11/12/99. To the top
|
|||||||||||||||||||||