BloombergLP::bdlsb::FixedMemOutStreamBuf::setbuf

Reinitialize this stream buffer with a new character buffer.

Synopsis

Declared in <bdlsb_fixedmemoutstreambuf.h>

virtual
FixedMemOutStreamBuf*
setbuf(
    char_type* buffer,
    std::streamsize length) override;

Description

Reinitialize this stream buffer to use the specified character buffer having the specified length. Return the address of this modifiable stream buffer. The behavior is undefined unless length == 0 or length > 0 && buffer != 0. Upon re-initialization for use of the new buffer, the length and next output location are reset to zero. Note that buffer is held but not owned.

Return Value

address of this modifiable stream buffer

Parameters

NameDescription
buffercharacter buffer to use for output; held but not owned
lengthsize of buffer in characters