Many applications use connection/object pool. A program may require a IMAP connection pool and LDAP connection pool. One could easily implement a IMAP connection pool, then take the existing code and implement a LDAP connection pool. The program grows, and now there is a need for a pool of threads. So just take the IMAP connection pool and convert that to a pool of threads (Copy, paste, find, replace????). Need to make some changes to the pool implementation? Not a very easy task, since the code has been duplicated in many places. Re-inventing source code is not an intelligent approach in an object oriented environment which encourages re-usability. It seems to make more sense to implement a pool that can contain any arbitrary type rather than duplicating code. How does one do that? The answer is to use type parameterization, more commonly referred to as templates.
The Spectral Toolkit is a C++ spectral transform library written by Rodney James and Chuck Panaccione while at the National Center for Atmospheric Research between 2002 and 2005. The library contains a functional subset of FFTPACK and SPHEREPACK, including real and complex FFTs in 1-3 dimensions, and a spherical harmonic transform. Multithreading is supported through POSIX threads for the multidimensional transforms. This reference guide provides details of the public interface as well as the internal implementation of the library.
Windows API Tutorials, Windows API編程最好的手冊.文檔格式專門制作成為各個章節相互關聯的html格式,大家可以像查閱msdn一樣方便使用.各個章節的內容如下:
Winnie
Generic
Controls
Dialog-based App
Generic Dialog
Canvas
Pens and Brushes
threads
Folder Watcher
Shell API
OLE
Smart OLE
OLE Automation
Splitter Bar
These two classes show an extremely simple example of java.net socket programming. They implement the Unix daytime protocol, an extremely simple protocol that consists entirely of the server sending its current local time and date to the client as an ASCII string. The server, to keep it very simple, does not use multiple threads. This code requires JDK 1.1 or later, but can easily be adapted to JDK 1.0.
PTypes (C++ Portable Types Library) is a simple alternative to the STL that includes multithreading and networking. It defines dynamic strings, variants, character sets, lists and other basic data types along with threads, synchronization objects, IP sockets and named pipes. PTypes also offers message queues as an alternative method of thread synchronization. Its main `target audience is developers of complex network daemons, robots or non-visual client/server applications of any kind
GNU Common C++ is a very portable and highly optimized class framework for writing C++ applications that need to use threads and support concurrent sychronization, and that use sockets, XML parsing, object serialization, thread-optimized String and data structure classes, etc. This framework offers a class foundation that hides platform differences from your C++ application so that you need not write platform specific code. GNU Common C++ has been ported to compile nativily on most platforms which support either posix threads, or on maybe be used with Debian hosted mingw32 to build native threading applications for Microsoft Windows.