Files
cppdraft_translate/cppdraft/ios/openmode.md
2025-10-25 03:02:53 +03:00

37 lines
1.5 KiB
Markdown
Raw Permalink Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

[ios.openmode]
# 31 Input/output library [[input.output]](./#input.output)
## 31.5 Iostreams base classes [[iostreams.base]](iostreams.base#ios.openmode)
### 31.5.2 Class ios_base [[ios.base]](ios.base#ios.openmode)
#### 31.5.2.2 Types [[ios.types]](ios.types#ios.openmode)
#### 31.5.2.2.4 Type ios_base::openmode [ios.openmode]
[🔗](#lib:openmode,ios_base)
`using openmode = T3;
`
[1](#1)
[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/iostreams.tex#L1075)
The typeopenmode is a bitmask type ([[bitmask.types]](bitmask.types "16.3.3.3.3Bitmask types"))[.](#1.sentence-1)
It contains the elements indicated in Table [139](#tab:ios.openmode "Table 139: openmode effects")[.](#1.sentence-2)
Table [139](#tab:ios.openmode) — openmode effects [[tab:ios.openmode]](./tab:ios.openmode)
| [🔗](#tab:ios.openmode-row-1)<br>**Element** | **Effect(s) if set** |
| --- | --- |
| [🔗](#tab:ios.openmode-row-2)<br>app | seek to end before each write |
| [🔗](#tab:ios.openmode-row-3)<br>ate | open and seek to end immediately after opening |
| [🔗](#tab:ios.openmode-row-4)<br>binary | perform input and output in binary mode (as opposed to text mode) |
| [🔗](#tab:ios.openmode-row-5)<br>in | open for input |
| [🔗](#tab:ios.openmode-row-6)<br>noreplace | open in exclusive mode |
| [🔗](#tab:ios.openmode-row-7)<br>out | open for output |
| [🔗](#tab:ios.openmode-row-8)<br>trunc | truncate an existing stream when opening |