List of all members.
Public Member Functions |
| StringBufContainer (const ALLOCATOR &allocator) |
| StringBufContainer (ios_base::openmode modeBitMask, const ALLOCATOR &allocator) |
| StringBufContainer (const StringType &initialString, const ALLOCATOR &allocator) |
| StringBufContainer (const StringType &initialString, ios_base::openmode modeBitMask, const ALLOCATOR &allocator) |
| StringBufContainer (BloombergLP::bslmf::MovableRef< StringType > initialString, ios_base::openmode modeBitMask, const ALLOCATOR &allocator) |
| StringBufContainer (BloombergLP::bslmf::MovableRef< StringType > initialString, ios_base::openmode modeBitMask) |
template<class STRING_ITER > |
| StringBufContainer (STRING_ITER first, STRING_ITER last, ios_base::openmode modeBitMask, const ALLOCATOR &allocator) |
| ~StringBufContainer () |
void | swap (StringBufContainer &other) |
StreamBufType * | rdbuf () const |
Detailed Description
template<class CHAR_TYPE, class CHAR_TRAITS, class ALLOCATOR>
class bsl::StringBufContainer< CHAR_TYPE, CHAR_TRAITS, ALLOCATOR >
This class enables the implementation of string-stream types by providing a trivial type containing a basic_stringbuf
that is suitable as a (private
) base class for a string-stream. Inheriting from StringBufContainer
allows the string-stream to ensure that the contained basic_stringbuf
is initialized before initializing other base classes or data members without potentially overriding virtual
methods in the basic_stringbuf
type. Note that implementations of string-stream types must pass the address of a string-buffer to their public
base class (e.g., basic_stream
), so the string-stream must ensure (using private
inheritance) that the string-buffer is initialized before constructing the public
base class. If a string-stream implementation were to directly inherit from basic_streambuf
, then virtual
methods defined in that string-stream (e.g., underflow
) might incorrectly override those in the basic_stringbuf
implementation.
See Component bslstl_stringbuf
Constructor & Destructor Documentation
template<class CHAR_TYPE , class CHAR_TRAITS , class ALLOCATOR >
template<class CHAR_TYPE , class CHAR_TRAITS , class ALLOCATOR >
template<class CHAR_TYPE , class CHAR_TRAITS , class ALLOCATOR >
template<class CHAR_TYPE , class CHAR_TRAITS , class ALLOCATOR >
template<class CHAR_TYPE , class CHAR_TRAITS , class ALLOCATOR >
template<class CHAR_TYPE , class CHAR_TRAITS , class ALLOCATOR >
template<class CHAR_TYPE , class CHAR_TRAITS , class ALLOCATOR >
template<class STRING_ITER >
template<class CHAR_TYPE , class CHAR_TRAITS , class ALLOCATOR >
Member Function Documentation
template<class CHAR_TYPE , class CHAR_TRAITS , class ALLOCATOR >
template<class CHAR_TYPE , class CHAR_TRAITS , class ALLOCATOR >
Reimplemented in bsl::basic_istringstream< CHAR_TYPE, CHAR_TRAITS, ALLOCATOR >, bsl::basic_ostringstream< CHAR_TYPE, CHAR_TRAITS, ALLOCATOR >, and bsl::basic_stringstream< CHAR_TYPE, CHAR_TRAITS, ALLOCATOR >.
Referenced by bsl::basic_stringstream< CHAR_TYPE, CHAR_TRAITS, ALLOCATOR >::rdbuf(), bsl::basic_ostringstream< CHAR_TYPE, CHAR_TRAITS, ALLOCATOR >::rdbuf(), and bsl::basic_istringstream< CHAR_TYPE, CHAR_TRAITS, ALLOCATOR >::rdbuf().
The documentation for this class was generated from the following file: