CppCMS
|
This is a base class that represents a buffer - a set of contiguous chunks of memory that can be transfered over network. More...
#include <booster/booster/aio/buffer.h>
Classes | |
struct | entry |
Public Types | |
typedef std::pair< entry const *, size_t > | buffer_data_type |
A pair that defined the chunk. | |
Public Member Functions | |
buffer_impl () | |
std::pair< entry const *, size_t > | get () const |
void | add (Pointer p, size_t s) |
bool | empty () const |
size_t | size () const |
size_t | bytes_count () const |
This is a base class that represents a buffer - a set of contiguous chunks of memory that can be transfered over network.
The Pointer parameter should be either char const *
or char *
|
inline |
Create an empty buffer
|
inline |
Append a chunk to the buffer
Referenced by booster::aio::buffer(), and booster::aio::const_buffer::const_buffer().
|
inline |
Get total amount of bytes in the buffer
|
inline |
Check if the buffer is empty
|
inline |
Get a first chunk
Referenced by booster::aio::buffer(), and booster::aio::const_buffer::const_buffer().
|
inline |
Get size of buffer in number of chunks,i.e.