Boost C++ Libraries Home Libraries People FAQ More

PrevUpHomeNext
to_asio_buffers (trivial and container types)

Any trivial type T or STL container.

Description

Trivial types turn into a buffer of &v sized sizeof(T). Container types have their value type deduced and to_asio_buffers() called on that value_type. Additional specialisations are provided for string, vector and array to collapse the scatter gather buffers into a single one for contiguous storage.

Synopsis
template<class T>
std::vector< asio::mutable_buffer > to_asio_buffers(T & v)
Parameters

Type

Concept

Name

Description

class T

Any trivial type T or STL container

-

Must be specified

T &

v

Returns

A vector of ASIO buffers

Header

#include <boost/afio/v2/afio.hpp>


PrevUpHomeNext