[ostringstream.swap] # 31 Input/output library [[input.output]](./#input.output) ## 31.8 String-based streams [[string.streams]](string.streams#ostringstream.swap) ### 31.8.4 Class template basic_ostringstream [[ostringstream]](ostringstream#swap) #### 31.8.4.3 Swap [ostringstream.swap] [🔗](#lib:swap,basic_ostringstream) `void swap(basic_ostringstream& rhs); ` [1](#1) [#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/iostreams.tex#L9489) *Effects*: Equivalent to:basic_ostream::swap(rhs);*sb*.swap(rhs.*sb*); [🔗](#lib:swap,basic_ostringstream_) `template void swap(basic_ostringstream& x, basic_ostringstream& y); ` [2](#2) [#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/iostreams.tex#L9506) *Effects*: Equivalent to x.swap(y)[.](#2.sentence-1)