Vanetza
 
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Pages
Loading...
Searching...
No Matches
io_vector.hpp
1#ifndef IO_VECTOR_HPP_A3ANMI8B
2#define IO_VECTOR_HPP_A3ANMI8B
3
4#include <vector>
5#include <sys/socket.h>
6#include <sys/types.h>
7
8namespace vanetza
9{
10
11// forward declaration
12class BufferPacket;
13
14/**
15 * IoVector eaeses population of struct msghdr.
16 * struct msghdr is required for sendmsg() calls.
17 */
19{
20public:
21 void append(const void* base, std::size_t length);
22 void append(const BufferPacket&);
23 void clear();
24 std::size_t length() const;
25 const iovec* base() const;
26
27private:
28 std::vector<iovec> m_vector;
29};
30
31} // namespace vanetza
32
33#endif /* IO_VECTOR_HPP_A3ANMI8B */
34