Namespaces
Variants

std::basic_ospanstream<CharT,Traits>:: operator=

From cppreference.net

basic_ospanstream & operator = ( basic_ospanstream && other ) ;
(1) (C++23以降)
basic_ospanstream & operator = ( const basic_ospanstream & ) = delete ;
(2) (C++23以降)
1) other * this にムーブ代入し、 std::basic_ostream 基底クラスのサブオブジェクトとラップされた std::basic_spanbuf の両方を効果的にムーブ代入します。
2) コピー代入演算子は削除されています。 basic_ospanstream はコピー代入可能ではありません。

基底クラスのムーブ代入演算子は、 rdbuf() を除くすべてのストリーム状態変数を * this other の間で交換することに注意してください。

std::basic_spanbuf をラップした other がムーブ代入後も基盤となるバッファを保持するかどうかは実装定義です。

目次

パラメータ

other - 移動元の別ストリーム

戻り値

* this

例外

実装定義の例外をスローする可能性があります。

関連項目

basic_spanbuf オブジェクトを代入
( std::basic_spanbuf<CharT,Traits> の公開メンバ関数)
(C++11)
別の basic_ostream からムーブ代入
(保護メンバ関数)