std::basic_iostream<CharT,Traits>:: swap
From cppreference.net
<
cpp
|
io
|
basic iostream
C++
Input/output library
| I/O manipulators | ||||
| Print functions (C++23) | ||||
| C-style I/O | ||||
| Buffers | ||||
|
(C++23)
|
||||
|
(
C++98/26*
)
|
||||
|
(C++20)
|
||||
| Streams | ||||
| Abstractions | ||||
| File I/O | ||||
| String I/O | ||||
| Array I/O | ||||
|
(C++23)
|
||||
|
(C++23)
|
||||
|
(C++23)
|
||||
|
(
C++98/26*
)
|
||||
|
(
C++98/26*
)
|
||||
|
(
C++98/26*
)
|
||||
| Synchronized Output | ||||
|
(C++20)
|
||||
| Types | ||||
| Error category interface | ||||
|
(C++11)
|
||||
|
(C++11)
|
std::basic_iostream
| Member functions | ||||
| Protected member functions | ||||
|
basic_iostream::swap
|
|
protected
:
void swap ( basic_iostream & other ) ; |
(C++11以降) | |
別の入出力ストリームオブジェクトと状態を交換します。実質的に basic_istream < CharT,Traits > :: swap ( other ) を呼び出します。
このメンバ関数はprotectedです:派生ストリームクラス std::basic_stringstream および std::basic_fstream のswapメンバ関数から呼び出されます。これらのクラスは、関連するストリームバッファを正しく交換する方法を知っています。
パラメータ
| other | - | 状態を交換する別のストリーム |
戻り値
* this