C-style file input/output
From Cppreference
C++ Standard Library | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Input/output library | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
C-style I/O | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
The <cstdio> header provides generic file operation support and supplies functions with narrow character input/output capabilities.
The <cwchar> header supplies functions with wide character input/output capabilities.
Contents |
[edit] Functions
File access | |||
|
opens a file (function) |
||
|
open an existing stream with a different name (function) |
||
|
synchronizes an output stream with the actual file (function) |
||
|
closes a file (function) |
||
|
sets the buffer for a file stream (function) |
||
|
sets the buffer and its size for a file stream (function) |
||
|
switches a file stream between wide character I/O and narrow character I/O (function) |
||
Direct input/output | |||
|
reads from a file (function) |
||
|
writes to a file (function) |
||
Unformatted input/output | |||
Narrow character | |||
|
gets a character from a file stream (function) |
||
|
gets a character string from a file stream (function) |
||
|
writes a character to a file stream (function) |
||
|
writes a character string to a file stream (function) |
||
|
reads a character from stdin (function) |
||
|
reads a character string from stdin (function) |
||
|
writes a character to stdout (function) |
||
|
writes a character string to stdout (function) |
||
|
puts a character back into a file stream (function) |
||
Wide character | |||
|
gets a wide character from a file stream (function) |
||
|
gets a wide character string from a file stream (function) |
||
|
writes a wide character to a file stream (function) |
||
|
writes a wide character string to a file stream (function) |
||
|
reads a wide character from stdin (function) |
||
|
writes a wide character to stdout (function) |
||
|
puts a wide character back into a file stream (function) |
||
Formatted input/output | |||
Narrow character | |||
|
reads formatted input from stdin, a file stream or a buffer (function) |
||
|
reads formatted input from stdin, a file stream or a buffer using variable argument list (function) |
||
|
prints formatted output to stdout, a file stream or a buffer (function) |
||
|
prints formatted output to stdout, a file stream or a buffer using variable argument list (function) |
||
Wide character | |||
|
reads formatted wide character input from stdin, a file stream or a buffer (function) |
||
|
reads formatted wide character input from stdin, a file stream or a buffer using variable argument list (function) |
||
|
prints formatted wide character output to stdout, a file stream or a buffer (function) |
||
|
prints formatted wide character output to stdout, a file stream or a buffer using variable argument list (function) |
||
File positioning | |||
|
returns the current file position indicator (function) |
||
|
gets the file position indicator (function) |
||
|
moves the file position indicator to a specific location in a file (function) |
||
|
moves the file position indicator to a specific location in a file (function) |
||
|
moves the file position indicator to the beginning in a file (function) |
||
Error handling | |||
|
clears errors (function) |
||
|
checks for the end-of-file (function) |
||
|
checks for a file error (function) |
||
|
displays a character string corresponding of the current error to stderr (function) |
||
Operations on files | |||
|
erases a file (function) |
||
|
renames a file (function) |
||
|
returns a pointer to a temporary file (function) |
||
|
returns an unique filename (function) |
[edit] Macros
This section is incomplete |