virtual int_type overflow( int_type _Meta = traits_type::eof( ) ); Parameters_Meta The character to insert into the buffer, or traits_type::eof.Return ValueIf the function cannot succeed, it returns traits_type::eof. Otherwise, it returns traits_type::not_eof(_Meta).Remarks...
basic_stringbuf::overflow 受保護的虛擬函式,可在將新字元插入已滿的緩衝區時呼叫。 C++ virtualint_typeoverflow(int_type _Meta = traits_type::eof()); 參數 _元 要插入緩衝區的字元,或traits_type::eof。 傳回值 如果函式無法成功,則會傳traits_type::eof回 。 否則會傳回traits_type::not_eof(...
std::basic_stringbuf::overflow std::basic_stringbuf::pbackfail std::basic_stringbuf::seekoff std::basic_stringbuf::seekpos std::basic_stringbuf::setbuf std::basic_stringbuf::str std::basic_stringbuf::swap std::basic_stringbuf::underflow ...
例如,向 basic_stringbuf<Elem, Tr> 对象的输出流插入的内容,就是之后从其输入流中提取的内容。 当定位 basic_filebuf<Elem, Tr> 对象的一个流时,将同时定位其他流。类模板 basic_streambuf 的公共接口提供对所有流缓冲区通用但又专用的操作。 受保护的接口提供特定流的表示形式完成其工作所需的操作。 受...
正式而言,此函数确保放置区有至少一个字符的空间。基类版本始终会失败,只能在派生类中提供会成功的版本(见实现要求)。标准库提供了std::strstreambuf::overflow()、(C++26 前)std::basic_stringbuf::overflow()和std::basic_filebuf::overflow()。
std::basic_stringbuf 是关联字符序列为内存常驻的任意字符序列的 std::basic_streambuf 。能从 std::basic_string 的实例初始化它,或将它做成该类的实例。 std::basic_stringbuf 的典型实现保有一个 std::basic_string 类型对象,或等价的可伸缩序列容器作为数据成员,并将它同时用作受控制字符序列(为 std::...
basic_stringbuf::off_typeMakes this type within basic_filebuf's scope equivalent to the type of the same name in the Tr scope.C++ Copy typedef typename traits_type::off_type off_type; basic_stringbuf::overflowA protected virtual function that can be called when a new character is ...
std::basic_streambuf::xsputn std::basic_stringbuf std::basic_stringbuf::basic_stringbuf std::basic_stringbuf::overflow std::basic_stringbuf::pbackfail std::basic_stringbuf::seekoff std::basic_stringbuf::seekpos std::basic_stringbuf::setbuf std::basic_stringbuf::str std::basic_stringbuf...
overflow [virtual] writes characters to the associated file from the put area (virtual protected member function of std::basic_filebuf<CharT,Traits>) overflow [virtual] appends a character to the output sequence (virtual protected member function of std::basic_stringbuf<CharT,Traits,Alloca...
basic_stringbuf::overflow basic_stringbuf::setbuf basic_stringbuf::seekoff basic_stringbuf::seekpos Non-member functions swap(std::basic_stringbuf) (C++11) Exposition-only member functions basic_stringbuf::init_buf_ptrs (1) std::basic_string<CharT, Traits, Allocator>str()const; ...