...one of the most highly
regarded and expertly designed C++ library projects in the
world.
— Herb Sutter and Andrei
Alexandrescu, C++
Coding Standards
Adapts a MutableBufferSequence into a DynamicBuffer.
Defined in header <boost/beast/core/buffers_adapter.hpp>
template< class MutableBufferSequence> class buffers_adapter
Name |
Description |
---|---|
The type used to represent the input sequence as a list of buffers. |
|
The type used to represent the output sequence as a list of buffers. |
|
The type of the underlying mutable buffer sequence. |
Name |
Description |
---|---|
Move constructor. Copy constructor. Construct a buffers adapter. Constructor. |
|
Returns the maximum sum of the sizes of the input sequence and output sequence the buffer can hold without requiring reallocation. |
|
Move bytes from the output sequence to the input sequence. |
|
Remove bytes from the input sequence. |
|
Get a list of buffers that represents the input sequence. |
|
Returns the largest size output sequence possible. |
|
Move assignment. Copy assignment. |
|
Get a list of buffers that represents the output sequence, with the given size. |
|
Get the size of the input sequence. |
|
Returns the original mutable buffer sequence. |
This class wraps a MutableBufferSequence to meet the requirements of DynamicBuffer. Upon construction the input and output sequences are empty. A copy of the mutable buffer sequence object is stored; however, ownership of the underlying memory is not transferred. The caller is responsible for making sure that referenced memory remains valid for the duration of any operations.
The size of the mutable buffer sequence determines the maximum number of bytes which may be prepared and committed.
Type |
Description |
---|---|
|
The type of mutable buffer sequence to wrap. |
Convenience header <boost/beast/core.hpp>