basic_stringbuf stringbuf wstringbuf Buffer class for file streams | iostream library |
cplusplus.com |
|
|
stringbuf members: (constructor) Construct object str Get/set string content members inherited from streambuf: pubimbue Imbue locale getloc Get current locale pubsetbuf Set buffer array pubseekoff Set relative position of internal position pointer pubseekpos Set absolute position of internal position pointer pubsync Synchronize stream in_avail Get number of characters available in input buffer snextc Increase get pointer and return next character sbumpc Get current character and increase get pointer sgetc Get current character sgetn Get some characters sputbackc Put character back sungetc Decrease get pointer sputc Store character at current put position and increase put pointer sputn Write some characters
stringbuf members: overflow Put character at current put position [virtual] pbackfail Put character back [virtual] seekoff Set relative position of internal position pointer [virtual] seekpos Set absolute position of internal position pointer [virtual] underflow Get current character [virtual] members inherited from streambuf: eback Get pointer to beginning of input sequence egptr Get pointer to end of input seuqence epptr Get pointer to end of output sequence gbump Increase get pointer gptr Return get pointer pbase Get pointer to beginning of output sequence pbump Increase put pointer pptr Return put pointer setg Set input buffer pointers setp Set output buffer pointers imbue Imbue locale [virtual] setbuf Set buffer [virtual] showmanyc Get number of characters availbale in input sequence [virtual] sync Synchronize file buffer [virtual] uflow Get current character [virtual] xsgetn Get some characters [virtual] xsputn Write some characters [virtual]
Description
The objects of this class associate an input and an output sequence with a
sequence of characters,
allowing the input and output functionality of streams to be performed on strings.
Every object of this class controls both an input and an output sequence, although some
sequence may be restricted depending on the openmode used as
constructor parameter.
The content of the internal sequence of characters may be obtained/replaced by calling
member str.
This class overrides some virtual members inherited from streambuf
to provide a specific functionality for strings. Plese refer to parent class
streambuf for more information on streambuf-derived objects.