Files
2025-10-25 03:02:53 +03:00

74 lines
2.6 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.

[basic.ios.cons]
# 31 Input/output library [[input.output]](./#input.output)
## 31.5 Iostreams base classes [[iostreams.base]](iostreams.base#basic.ios.cons)
### 31.5.4 Class template basic_ios [[ios]](ios#basic.ios.cons)
#### 31.5.4.2 Constructors [basic.ios.cons]
[🔗](#lib:basic_ios,constructor)
`explicit basic_ios(basic_streambuf<charT, traits>* sb);
`
[1](#1)
[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/iostreams.tex#L1879)
*Effects*: Assigns initial values to its member objects by callinginit(sb)[.](#1.sentence-1)
[🔗](#lib:basic_ios,constructor_)
`basic_ios();
`
[2](#2)
[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/iostreams.tex#L1891)
*Effects*: Leaves its member objects uninitialized[.](#2.sentence-1)
The object
shall be initialized by callingbasic_ios::init before its first use or before it is destroyed, whichever comes first; otherwise the
behavior is undefined[.](#2.sentence-2)
[🔗](#lib:basic_ios,destructor)
`~basic_ios();
`
[3](#3)
[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/iostreams.tex#L1906)
*Remarks*: The destructor does not destroyrdbuf()[.](#3.sentence-1)
[🔗](#lib:init,basic_ios)
`void init(basic_streambuf<charT, traits>* sb);
`
[4](#4)
[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/iostreams.tex#L1918)
*Postconditions*: The postconditions of this function are indicated in Table [142](#tab:basic.ios.cons "Table 142: basic_­ios::init() effects")[.](#4.sentence-1)
Table [142](#tab:basic.ios.cons) — basic_ios::init() effects [[tab:basic.ios.cons]](./tab:basic.ios.cons)
| [🔗](#tab:basic.ios.cons-row-1)<br>**Element** | **Value** |
| --- | --- |
| [🔗](#tab:basic.ios.cons-row-2)<br>rdbuf() | sb |
| [🔗](#tab:basic.ios.cons-row-3)<br>tie() | 0 |
| [🔗](#tab:basic.ios.cons-row-4)<br>rdstate() | goodbit if sb is not a null pointer, otherwise badbit[.](#tab:basic.ios.cons-row-4-column-2-sentence-1) |
| [🔗](#tab:basic.ios.cons-row-5)<br>exceptions() | goodbit |
| [🔗](#tab:basic.ios.cons-row-6)<br>flags() | skipws | dec |
| [🔗](#tab:basic.ios.cons-row-7)<br>width() | 0 |
| [🔗](#tab:basic.ios.cons-row-8)<br>precision() | 6 |
| [🔗](#tab:basic.ios.cons-row-9)<br>fill() | widen(' ') |
| [🔗](#tab:basic.ios.cons-row-10)<br>getloc() | a copy of the value returned by locale() |
| [🔗](#tab:basic.ios.cons-row-11)<br>*iarray* | a null pointer |
| [🔗](#tab:basic.ios.cons-row-12)<br>*parray* | a null pointer |