26.1 — Template classes

In a previous chapter, we covered function templates (), which allow us to generalize functions to work with many different data types. While this is a great start down the road to generalized programming, it doesn’t solve all of our problems. Let’s take a look at an example of one …

28.7 — Random file I/O

The file pointer Each file stream class contains a file pointer that is used to keep track of the current read/write position within the file. When something is read from or written to a file, the reading/writing happens at the file pointer’s current location. By default, when opening a file …

28.6 — Basic file I/O

File I/O in C++ works very similarly to normal I/O (with a few minor added complexities). There are 3 basic file I/O classes in C++: ifstream (derived from istream), ofstream (derived from ostream), and fstream (derived from iostream). These classes do file input, output, and input/output respectively. To use the …

Tiga and WordPress 2.5

Hey everyone, I just upgraded this site to WordPress 2.5 and Tiga v2.3 appears to be working just fine. Thus: If you are running Tiga v2.3 already should be able to upgrade to WordPress v2.5 with no major problems. If you are running an older version of the Tiga theme, …

28.2 — Input with istream

The iostream library is fairly complex — so we will not be able to cover it in its entirety in these tutorials. However, we will show you the most commonly used functionality. In this section, we will look at various aspects of the input class (istream). The extraction operator As …