Chapter 12. Streams and Files

This chapter focuses on the C++ stream classes. We’ll start off with a look at the hierarchy in which these classes are arranged, and we’ll summarize their important features. The largest part of this chapter is devoted to showing how to perform file-related activities using C++ streams. We’ll show how to read and write data to files in a variety of ways, how to handle errors, and how files and OOP ...

Get Object-Oriented Programming in C++, Fourth Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.