7 #ifndef _QI_BUFFER_HPP_
8 # define _QI_BUFFER_HPP_
12 # include <boost/shared_ptr.hpp>
17 # pragma warning( push )
18 # pragma warning( disable: 4251 )
104 bool write(
const void *data,
size_t size);
113 size_t addSubBuffer(
const Buffer& buffer);
119 bool hasSubBuffer(
size_t offset)
const;
126 const Buffer& subBuffer(
size_t offset)
const;
141 size_t totalSize()
const;
148 const std::vector<std::pair<size_t, Buffer> >& subBuffers()
const;
156 void* reserve(
size_t size);
172 const void* data()
const;
183 const void* read(
size_t offset = 0,
size_t length = 0)
const;
195 size_t read(
void* buffer,
size_t offset = 0,
size_t length = 0)
const;
200 boost::shared_ptr<BufferPrivate> _p;
227 size_t read(
void *data,
size_t length);
235 void *read(
size_t offset);
241 bool seek(
size_t offset);
249 void *peek(
size_t offset)
const;
256 bool hasSubBuffer()
const;
262 const Buffer& subBuffer();
267 size_t position()
const;
282 # pragma warning( pop )
285 #endif // _QI_BUFFER_HPP_
void printBuffer(std::ostream &stream, const Buffer &buffer)
dll import/export and compiler message
Class to read const buffer. <includename>qi/buffer.hpp</includename> This class is intendeed to rea...
Class to store buffer. <includename>qi/buffer.hpp</includename> .