38 class DataBuffer_Impl;
57 template<
typename Type>
60 template<
typename Type>
85 std::shared_ptr<DataBuffer_Impl> impl;
General purpose data buffer.
Definition databuffer.h:42
DataBuffer()
Constructs a data buffer of 0 size.
DataBuffer & operator=(const DataBuffer ©)
DataBuffer(const void *data, size_t size)
const char & operator[](size_t i) const
Type * get_data()
Definition databuffer.h:58
bool is_null() const
Returns true if the buffer is 0 in size.
char & operator[](size_t i)
Returns a char in the buffer.
void set_capacity(size_t capacity)
Preallocate enough memory.
size_t get_capacity() const
Returns the capacity of the data buffer object.
char * get_data()
Returns a pointer to the data.
void set_size(size_t size)
Resize the buffer.
const char * get_data() const
size_t get_size() const
Returns the size of the data.
DataBuffer(const DataBuffer &data, size_t pos, size_t size)
const Type * get_data() const
Definition databuffer.h:61
DataBuffer(const DataBuffer ©)