std::basic_string<CharT,Traits,Allocator>::clear

来自cppreference.com
< cpp‎ | string‎ | basic string
2014年10月26日 (日) 19:08P12bot讨论 | 贡献的版本

 
 
 
std::basic_string
 
void clear();

Removes all characters from the string. The allocated memory will not be released, effectively leaving the capacity of the string unchanged. The past-the-end iterators are not invalidated.

目录

参数

(无)
原文:
(none)
文本通过谷歌翻译机器翻译。
你可以帮忙校正和验证翻译。点击此处查看指示。

返回值

(无)
原文:
(none)
文本通过谷歌翻译机器翻译。
你可以帮忙校正和验证翻译。点击此处查看指示。

复杂度

linear in the size of the string.

另请参阅

移除字符
(公开成员函数) [编辑]