|

Win32
Some things don't need the extra baggage that MFC brings with it. Sometimes it's good to be lean and mean... These pages contain some classes that we've written to make working with complex parts of the Win32 API easier. There are also several "applet frameworks" to make writing particular kinds of applications easier.
Most of the time there's nothing to stop you using these classes with MFC if you want, though they don't use MFC themselves.
Articles:
Control Panel Applet Framework
- A framework for control panel applets. Just derive from the base class and provide one virtual function and you have implemented a control panel applet.
Task Tray Applet Framework
- A framework for applets that live in the system tray. Derive from the base class, provide an implementation for three virtual functions and your work is done.
Registry API wrapper classes
- Simple wrapper classes for using the Win32 Registry API functions. All of the functions throw exceptions on failure, thus simplifying error handling.
A reusable socket server class.
- Writing a high performance server that runs on Windows NT and uses sockets to communicate with the
outside world isn't that hard once you dig through the API references. What's more most of the code is
common between all of the servers that you're likely to want to write. It should be possible to wrap
all of the common code up in some easy to reuse classes.
Business logic processing in a socket server.
- To maintain performance a socket server shouldn't make any calls that should block from its IO thread pool. In this article we develop a business logic thread pool and add this to the server developed in the previous article.
Speeding up socket server connections with AcceptEx
- When a server has to deal with lots of short lived client connections it's advisable to use the
Microsoft extension function for WinSock, AcceptEx(), to accept connections. Creating a socket is a
relatively "expensive" operation and by using AcceptEx() you can create the socket before the connection
occurs rather than as it occurs, thus speeding the establishment of the connection. What's more,
AcceptEx() can perform an initial data read at the same time as doing the connection establishment which
means you can accept a connection and retrieve data with a single call.
Handling multiple pending socket read and write operations
- "How do you handle the problem of multiple pending WSARecv() calls?" is a common question on
the Winsock news groups. It seems that everyone knows that it's often a good idea to have more than
one outstanding read waiting on a socket and everyone's equally aware that sometimes code doesn't work
right when you do that. This article explains the potential problems with multiple pending recvs.
Using OpenSSL with Asynchronous Sockets
- OpenSLL is an open source implementation of the SSL and TLS protocols. Unfortunately it doesn't play well with windows style asynchronous sockets. This article - previously published in Windows Developer Magazine - provides a simple connector that enables you to use OpenSLL asynchronously.
|