cpp/io

C++ includes the following input/output libraries: an OOP-style stream-based I/O library, and the standard set of C-style I/O functions.

Stream-based I/O
The stream-based input/output library is organized around abstract input/output devices. These abstract devices allow the same code to handle input/output to files, memory streams, or custom adaptor devices that perform arbitrary operations (e.g. compression) on the fly.

Most of the classes are templated, so they can be adapted to any basic character type. Separate typedefs are provided for the most common basic character types ( and ). The classes are organized into the following hierarchy:

Typedefs
The following typedefs for common character types are provided in namespace :

The stream-based I/O library uses (e.g. std, std, etc.) to control how streams behave.

Types
The following auxiliary types are defined:

The following typedef names for are provided:

Print functions
The Unicode-aware print-family functions that perform formatted I/O on text that is already formatted. They bring all the performance benefits of std, are locale-independent by default, reduce global state, avoid allocating a temporary std object and calling, and in general make formatting more efficient compared to iostreams and stdio.

The following print-like functions are provided:

C++ also includes the, such as std, std, etc.