...one of the most highly
regarded and expertly designed C++ library projects in the
world.
— Herb Sutter and Andrei
Alexandrescu, C++
Coding Standards
Returns a prefix of a buffer sequence.
Defined in header <boost/beast/core/buffers_prefix.hpp>
template< class BufferSequence> buffers_prefix_view< BufferSequence > buffers_prefix( std::size_t size, BufferSequence const& buffers);
This function returns a new buffer sequence which when iterated, presents a shorter subset of the original list of buffers starting with the first byte of the original sequence.
Name |
Description |
---|---|
|
The maximum number of bytes in the wrapped sequence. If this is larger than the size of passed, buffers, the resulting sequence will represent the entire input sequence. |
|
An instance of ConstBufferSequence or MutableBufferSequence to adapt. A copy of the sequence will be made, but ownership of the underlying memory is not transferred. |
Convenience header <boost/beast/core.hpp>