#include <gls_glo_file.h>
|
| WriteBuffer (const unsigned int initialSize) |
|
void | Resize (const unsigned int minimumSize) |
|
void | Enlarge (const unsigned int incrementalSize) |
|
unsigned char * | Buffer () |
|
unsigned int | Size () |
|
void | WriteData (const void *data, const unsigned int size) |
|
void | WriteData (const void *data, const unsigned int size, const unsigned int offset) |
|
void | Rewind () |
| Rewind to beginning of buffer.
|
|
|
unsigned int | _current |
| Total size of the params for the current object.
|
|
unsigned int | _bufSize |
| Size of the param buffer.
|
|
unsigned char * | _buf |
| Buffer containing the params for the current object.
|
|
The WriteBuffer class. A resizable binary stream.
◆ WriteBuffer()
Constructor
- Parameters
-
initialSize | The initial size of the buffer in bytes. |
◆ Buffer()
unsigned char * Buffer |
( |
| ) |
|
- Returns
- The buffer pointer.
◆ Enlarge()
void Enlarge |
( |
const unsigned int |
incrementalSize | ) |
|
Enlarge buffer by at least incrementalSize
- Parameters
-
incrementalSize | Increase by this size in bytes. |
◆ Resize()
void Resize |
( |
const unsigned int |
minimumSize | ) |
|
Ensure the buffer is at least the specified size.
- Parameters
-
minimumSize | The minimum size in bytes. |
◆ Size()
- Returns
- The current buffer size.
◆ WriteData() [1/2]
void WriteData |
( |
const void * |
data, |
|
|
const unsigned int |
size |
|
) |
| |
Write data to the buffer at the current offset, moving the current write position.
- Parameters
-
data | Pointer to the data to write. |
size | The number of bytes to write. |
◆ WriteData() [2/2]
void WriteData |
( |
const void * |
data, |
|
|
const unsigned int |
size, |
|
|
const unsigned int |
offset |
|
) |
| |
Write data to the buffer at a specific offset, not moving the current write position.
- Parameters
-
data | Pointer to the data to write. |
size | The number of bytes to write. |
offset | The position in the buffer to write to. |
The documentation for this class was generated from the following file: