名稱空間
變體
操作

std::swap(std::basic_ostringstream)

來自 cppreference.com
定義於標頭檔案 <sstream>
template< class CharT, class Traits, class Alloc >

void swap( std::basic_ostringstream<CharT,Traits,Alloc>& lhs,

           std::basic_ostringstream<CharT,Traits,Alloc>& rhs );
(C++11 起)

過載 std::swap 演算法以用於 std::basic_ostringstream。交換 lhs 的狀態與 rhs 的狀態。實際上呼叫 lhs.swap(rhs)

目錄

[編輯] 引數

lhs, rhs - 要交換其狀態的流

[編輯] 返回值

(無)

[編輯] 異常

可能丟擲實現定義的異常。

[編輯] 示例

[編輯] 參閱

(C++11)
交換兩個字串流
(public member function) [編輯]