A sample demonstration of using the Boost libraries as a means of finding matching words in a large array table, that match the given lookup criteria.
Suppose you are wrestling with a cryptic crossword and want to find all seven-letter words whose third letter is ‘Y’ and fifth letter is ‘N’, or better still, run a program that will find these words for you. Continue reading →
Listing1: Serialization of STL containers: a std::vector example using text archives
Your intuition may tell you to iterate through the STL container in order to serialize it, but it’s actually a lot simpler. First of all, be sure to include the necessary vector.hpp include file: Continue reading →
A number of Windows-based Boost libraries are not “header-only” and require that you must get them compiled. One way is to compile them yourself. A possibly easier way is to do this via the prebuilt installer packages from BoostPro.
Say for example you wish to use the Boost serialize facilities in your program: Continue reading →
Some code samples I have collated in the sample below, that demonstrate how boost::function can be assigned with functors, ordinary functions, class member functions and overloaded class member functions respectively. Continue reading →
This post assumes that the boost libraries have been downloaded and extracted to the directory of your choice. See this previous posting for more details on how to download and extract the Boost libraries. Continue reading →
This post takes a look at using boost::bind as a means of calling class
member functions in an efficient and generic way. It basically summarizes what has
already been said at Björn Karlsson’s excellent Informit article. Since I found the post useful, I thought it worth reproducing here, using the same status class but containing all the examples and approaches he describes in one program. Continue reading →
Boost::bind is “able to bind any argument to a specific value or route input arguments into arbitrary positions.” It’s a means of converting a function into an object that can be copied around and called at a later point, deferred callbacks for example. Continue reading →
When we want to dynamically allocate an array of objects for some purpose, the C++ programming language offers us the new and delete operators that are intended to replace the traditional malloc() and free() subroutines that are part of the standard library : Continue reading →
This post aims to be an accessible introduction to getting set up with the Boost threads in Visual Studio environments for the first time. Like with many technical subjects, there is a great deal of information out on the internet, that tells you a lot without actually showing you anything! Continue reading →