Shaka Player Embedded
|
#include <dynamic_buffer.h>
Public Member Functions | |
DynamicBuffer () | |
~DynamicBuffer () | |
DynamicBuffer (const DynamicBuffer &)=delete | |
DynamicBuffer (DynamicBuffer &&) | |
DynamicBuffer & | operator= (const DynamicBuffer &)=delete |
DynamicBuffer & | operator= (DynamicBuffer &&) |
size_t | Size () const |
void | Clear () |
void | AppendCopy (const void *buffer, size_t size) |
std::string | CreateString () const |
void | CopyDataTo (uint8_t *dest, size_t size) const |
Friends | |
class | DynamicBufferTest |
Represents a buffer of bytes that can be appended to without unnecessary copies. This does so by storing an array of the sub-buffers it stores. This means that you cannot get a singular data pointer. There are helper methods that can copy this to a contiguous buffer (e.g. std::string).
Definition at line 31 of file dynamic_buffer.h.
shaka::util::DynamicBuffer::DynamicBuffer | ( | ) |
Definition at line 27 of file dynamic_buffer.cc.
shaka::util::DynamicBuffer::~DynamicBuffer | ( | ) |
Definition at line 28 of file dynamic_buffer.cc.
|
delete |
|
default |
void shaka::util::DynamicBuffer::AppendCopy | ( | const void * | buffer, |
size_t | size | ||
) |
Appends to the buffer by copying the given data.
Definition at line 40 of file dynamic_buffer.cc.
|
inline |
Clears the contents of the buffer.
Definition at line 45 of file dynamic_buffer.h.
void shaka::util::DynamicBuffer::CopyDataTo | ( | uint8_t * | dest, |
size_t | size | ||
) | const |
Copies the contents of this buffer to the given buffer.
Definition at line 64 of file dynamic_buffer.cc.
std::string shaka::util::DynamicBuffer::CreateString | ( | ) | const |
Definition at line 58 of file dynamic_buffer.cc.
|
delete |
|
default |
size_t shaka::util::DynamicBuffer::Size | ( | ) | const |
Definition at line 33 of file dynamic_buffer.cc.
|
friend |
Definition at line 60 of file dynamic_buffer.h.